diff --git a/src/Wallets.tsx b/src/Wallets.tsx index 5d4cfc6..135ff26 100644 --- a/src/Wallets.tsx +++ b/src/Wallets.tsx @@ -49,7 +49,7 @@ export const Wallets = ({ setExtState, setRawWallet, rawWallet }) => { const [isOpenSeedModal, setIsOpenSeedModal] = useState(false); const [isLoadingEncryptSeed, setIsLoadingEncryptSeed] = useState(false); const theme = useTheme(); - const { t } = useTranslation(['core', 'auth']); + const { t } = useTranslation(['auth', 'core', 'group']); const { isShow, onCancel, onOk, show } = useModal(); const { getRootProps, getInputProps } = useDropzone({ @@ -453,7 +453,7 @@ const WalletItem = ({ wallet, updateWalletItem, idx, setSelectedWallet }) => { const [note, setNote] = useState(''); const [isEdit, setIsEdit] = useState(false); const theme = useTheme(); - const { t } = useTranslation(['core', 'auth']); + const { t } = useTranslation(['auth', 'core', 'group']); useEffect(() => { if (wallet?.name) { diff --git a/src/components/Apps/AppInfo.tsx b/src/components/Apps/AppInfo.tsx index 6e8e274..93d807d 100644 --- a/src/components/Apps/AppInfo.tsx +++ b/src/components/Apps/AppInfo.tsx @@ -37,7 +37,7 @@ export const AppInfo = ({ app, myName }) => { ); const theme = useTheme(); - const { t } = useTranslation(['core', 'auth', 'group']); + const { t } = useTranslation(['auth', 'core', 'group']); const isSelectedAppPinned = !!sortablePinnedApps?.find( (item) => item?.name === app?.name && item?.service === app?.service diff --git a/src/components/Apps/AppInfoSnippet.tsx b/src/components/Apps/AppInfoSnippet.tsx index 1629b5e..ea949d0 100644 --- a/src/components/Apps/AppInfoSnippet.tsx +++ b/src/components/Apps/AppInfoSnippet.tsx @@ -42,7 +42,7 @@ export const AppInfoSnippet = ({ ); const theme = useTheme(); - const { t } = useTranslation(['core', 'auth', 'group']); + const { t } = useTranslation(['auth', 'core', 'group']); return ( { const [file, setFile] = useState(null); const { show } = useContext(MyContext); const theme = useTheme(); - const { t } = useTranslation(['core', 'auth', 'group']); + const { t } = useTranslation(['auth', 'core', 'group']); const [tag1, setTag1] = useState(''); const [tag2, setTag2] = useState(''); const [tag3, setTag3] = useState(''); diff --git a/src/components/Apps/AppRating.tsx b/src/components/Apps/AppRating.tsx index 860dfc4..7889a36 100644 --- a/src/components/Apps/AppRating.tsx +++ b/src/components/Apps/AppRating.tsx @@ -20,7 +20,7 @@ export const AppRating = ({ app, myName, ratingCountPosition = 'right' }) => { const [openSnack, setOpenSnack] = useState(false); const [infoSnack, setInfoSnack] = useState(null); const hasCalledRef = useRef(false); - const { t } = useTranslation(['core', 'group']); + const { t } = useTranslation(['auth', 'core', 'group']); const getRating = useCallback(async (name, service) => { try { diff --git a/src/components/Apps/AppsDesktop.tsx b/src/components/Apps/AppsDesktop.tsx index a976534..9a66da3 100644 --- a/src/components/Apps/AppsDesktop.tsx +++ b/src/components/Apps/AppsDesktop.tsx @@ -50,7 +50,7 @@ export const AppsDesktop = ({ const [isEnabledDevMode, setIsEnabledDevMode] = useAtom(enabledDevModeAtom); const { showTutorial } = useContext(MyContext); const theme = useTheme(); - const { t } = useTranslation(['core', 'group']); + const { t } = useTranslation(['auth', 'core', 'group']); const myApp = useMemo(() => { return availableQapps.find( @@ -381,7 +381,12 @@ export const AppsDesktop = ({ setDesktopViewMode('apps'); }} > - + @@ -399,7 +404,9 @@ export const AppsDesktop = ({ ? theme.palette.text.primary : theme.palette.text.secondary } - label="Chat" + label={t('core:chat', { + postProcess: 'capitalizeFirst', + })} disableWidth > { setTimeout(() => { @@ -108,7 +110,6 @@ export const AppsDevMode = ({ setTabs((prev) => [...prev, newTab]); setSelectedTab(newTab); setMode('viewer'); - setIsNewTabWindow(false); }; @@ -215,25 +216,25 @@ export const AppsDevMode = ({ @@ -241,8 +242,8 @@ export const AppsDevMode = ({ { goToHome(); @@ -267,7 +268,9 @@ export const AppsDevMode = ({ color={ isApps ? theme.palette.text.primary : theme.palette.text.secondary } - label="Apps" + label={t('core:app_other', { + postProcess: 'capitalizeFirst', + })} disableWidth > + {mode !== 'home' && } @@ -382,10 +390,10 @@ export const AppsDevMode = ({ diff --git a/src/components/Apps/AppsDevModeHome.tsx b/src/components/Apps/AppsDevModeHome.tsx index a02136e..a95e329 100644 --- a/src/components/Apps/AppsDevModeHome.tsx +++ b/src/components/Apps/AppsDevModeHome.tsx @@ -41,7 +41,7 @@ export const AppsDevModeHome = ({ const [domain, setDomain] = useState('127.0.0.1'); const [port, setPort] = useState(''); const [selectedPreviewFile, setSelectedPreviewFile] = useState(null); - const { t } = useTranslation(['core', 'group']); + const { t } = useTranslation(['auth', 'core', 'group']); const { isShow, onCancel, onOk, show, message } = useModal(); const { openSnackGlobal, diff --git a/src/components/Apps/AppsHomeDesktop.tsx b/src/components/Apps/AppsHomeDesktop.tsx index b2c67cf..42afb74 100644 --- a/src/components/Apps/AppsHomeDesktop.tsx +++ b/src/components/Apps/AppsHomeDesktop.tsx @@ -27,7 +27,7 @@ export const AppsHomeDesktop = ({ }) => { const [qortalUrl, setQortalUrl] = useState(''); const theme = useTheme(); - const { t } = useTranslation(['core', 'group']); + const { t } = useTranslation(['auth', 'core', 'group']); const openQortalUrl = () => { try { diff --git a/src/components/Apps/AppsLibraryDesktop.tsx b/src/components/Apps/AppsLibraryDesktop.tsx index ebe0ddd..53ef843 100644 --- a/src/components/Apps/AppsLibraryDesktop.tsx +++ b/src/components/Apps/AppsLibraryDesktop.tsx @@ -105,7 +105,7 @@ export const AppsLibraryDesktop = ({ const [searchValue, setSearchValue] = useState(''); const virtuosoRef = useRef(null); const theme = useTheme(); - const { t } = useTranslation(['core', 'group']); + const { t } = useTranslation(['auth', 'core', 'group']); const officialApps = useMemo(() => { return availableQapps.filter( diff --git a/src/components/Apps/AppsNavBarDesktop.tsx b/src/components/Apps/AppsNavBarDesktop.tsx index f294834..80f8f03 100644 --- a/src/components/Apps/AppsNavBarDesktop.tsx +++ b/src/components/Apps/AppsNavBarDesktop.tsx @@ -76,7 +76,7 @@ export const AppsNavBarDesktop = ({ disableBack }) => { ); const theme = useTheme(); - const { t } = useTranslation(['core', 'group']); + const { t } = useTranslation(['auth', 'core', 'group']); const [isNewTabWindow, setIsNewTabWindow] = useState(false); const tabsRef = useRef(null); const [anchorEl, setAnchorEl] = useState(null); diff --git a/src/components/Apps/AppsPrivate.tsx b/src/components/Apps/AppsPrivate.tsx index de2c744..dae28a8 100644 --- a/src/components/Apps/AppsPrivate.tsx +++ b/src/components/Apps/AppsPrivate.tsx @@ -63,7 +63,7 @@ export const AppsPrivate = ({ myName }) => { const [memberGroups] = useAtom(memberGroupsAtom); const theme = useTheme(); - const { t } = useTranslation(['core', 'group']); + const { t } = useTranslation(['auth', 'core', 'group']); const myGroupsPrivate = useMemo(() => { return memberGroups?.filter( @@ -321,7 +321,9 @@ export const AppsPrivate = ({ myName }) => { }} > { }} /> { labelId="demo-simple-select-label" id="demo-simple-select" value={privateAppValues?.groupId} - label="Groups" + label={t('group:group.group_other', { + postProcess: 'capitalizeFirst', + })} onChange={(e) => { setPrivateAppValues((prev) => { return { @@ -552,7 +558,9 @@ export const AppsPrivate = ({ myName }) => { labelId="demo-simple-select-label" id="demo-simple-select" value={selectedGroup} - label="Groups where you are an admin" + label={t('group:group.groups_admin', { + postProcess: 'capitalizeFirst', + })} onChange={(e) => setSelectedGroup(e.target.value)} > @@ -560,6 +568,7 @@ export const AppsPrivate = ({ myName }) => { postProcess: 'capitalizeFirst', })} + {myGroupsWhereIAmAdmin ?.filter((item) => !item?.isOpen) .map((group) => { diff --git a/src/components/Chat/AdminSpace.tsx b/src/components/Chat/AdminSpace.tsx index ca080d8..b9d4a81 100644 --- a/src/components/Chat/AdminSpace.tsx +++ b/src/components/Chat/AdminSpace.tsx @@ -19,7 +19,7 @@ export const AdminSpace = ({ isOwner, }) => { const [isMoved, setIsMoved] = useState(false); - const { t } = useTranslation(['core', 'group']); + const { t } = useTranslation(['auth', 'core', 'group']); useEffect(() => { if (hide) { diff --git a/src/components/CoreSyncStatus.tsx b/src/components/CoreSyncStatus.tsx index 3e782c4..768a4b6 100644 --- a/src/components/CoreSyncStatus.tsx +++ b/src/components/CoreSyncStatus.tsx @@ -13,7 +13,7 @@ export const CoreSyncStatus = () => { const [coreInfos, setCoreInfos] = useState({}); const [isUsingGateway, setIsUsingGateway] = useState(false); - const { t } = useTranslation(['auth', 'core']); + const { t } = useTranslation(['auth', 'core', 'group']); const theme = useTheme(); useEffect(() => { diff --git a/src/components/DesktopSideBar.tsx b/src/components/DesktopSideBar.tsx index e2774a7..800c528 100644 --- a/src/components/DesktopSideBar.tsx +++ b/src/components/DesktopSideBar.tsx @@ -9,6 +9,7 @@ import { CoreSyncStatus } from './CoreSyncStatus'; import LanguageSelector from './Language/LanguageSelector'; import { MessagingIconFilled } from '../assets/Icons/MessagingIconFilled'; import { useAtom } from 'jotai'; +import { useTranslation } from 'react-i18next'; export const DesktopSideBar = ({ goToHome, @@ -27,6 +28,7 @@ export const DesktopSideBar = ({ const [isEnabledDevMode, setIsEnabledDevMode] = useAtom(enabledDevModeAtom); const theme = useTheme(); + const { t } = useTranslation(['auth', 'core', 'group']); return ( @@ -105,7 +107,7 @@ export const DesktopSideBar = ({ ? theme.palette.text.primary : theme.palette.text.secondary } - label="Chat" + label={t('core:chat', { postProcess: 'capitalizeFirst' })} disableWidth > diff --git a/src/components/GeneralNotifications.tsx b/src/components/GeneralNotifications.tsx index b88000e..3e23637 100644 --- a/src/components/GeneralNotifications.tsx +++ b/src/components/GeneralNotifications.tsx @@ -32,7 +32,7 @@ export const GeneralNotifications = ({ address }) => { setAnchorEl(event.currentTarget); }; - const { t } = useTranslation(['core']); + const { t } = useTranslation(['auth', 'core', 'group']); const theme = useTheme(); return ( diff --git a/src/components/GlobalActions/JoinGroup.tsx b/src/components/GlobalActions/JoinGroup.tsx index 6b63257..dd83b06 100644 --- a/src/components/GlobalActions/JoinGroup.tsx +++ b/src/components/GlobalActions/JoinGroup.tsx @@ -29,7 +29,7 @@ export const JoinGroup = () => { const [isLoadingInfo, setIsLoadingInfo] = useState(false); const [isOpen, setIsOpen] = useState(false); const theme = useTheme(); - const { t } = useTranslation(['core', 'group']); + const { t } = useTranslation(['auth', 'core', 'group']); const [isLoadingJoinGroup, setIsLoadingJoinGroup] = useState(false); const handleJoinGroup = async (e) => { diff --git a/src/components/Group/AddGroup.tsx b/src/components/Group/AddGroup.tsx index dc12ed3..97cede9 100644 --- a/src/components/Group/AddGroup.tsx +++ b/src/components/Group/AddGroup.tsx @@ -97,7 +97,7 @@ export const AddGroup = ({ address, open, setOpen }) => { setMaxBlock(event.target.value as string); }; - const { t } = useTranslation(['core', 'group']); + const { t } = useTranslation(['auth', 'core', 'group']); const theme = useTheme(); const handleCreateGroup = async () => { diff --git a/src/components/Group/AddGroupList.tsx b/src/components/Group/AddGroupList.tsx index daf509c..fb4d87c 100644 --- a/src/components/Group/AddGroupList.tsx +++ b/src/components/Group/AddGroupList.tsx @@ -44,7 +44,7 @@ export const AddGroupList = ({ setInfoSnack, setOpenSnack }) => { const setTxList = useSetAtom(txListAtom); - const { t } = useTranslation(['core', 'group']); + const { t } = useTranslation(['auth', 'core', 'group']); const [groups, setGroups] = useState([]); const [popoverAnchor, setPopoverAnchor] = useState(null); // Track which list item the popover is anchored to const [openPopoverIndex, setOpenPopoverIndex] = useState(null); // Track which list item has the popover open diff --git a/src/components/Group/Forum/GroupMail.tsx b/src/components/Group/Forum/GroupMail.tsx index c1718a5..ecaca52 100644 --- a/src/components/Group/Forum/GroupMail.tsx +++ b/src/components/Group/Forum/GroupMail.tsx @@ -73,7 +73,7 @@ export const GroupMail = ({ const anchorElInstanceFilter = useRef(null); const [tempPublishedList, setTempPublishedList] = useState([]); const dataPublishes = useRef({}); - const { t } = useTranslation(['core']); + const { t } = useTranslation(['auth', 'core', 'group']); const theme = useTheme(); const [isLoading, setIsLoading] = useState(false); const groupIdRef = useRef(null); diff --git a/src/components/Group/Forum/NewThread.tsx b/src/components/Group/Forum/NewThread.tsx index d37eedd..9da431e 100644 --- a/src/components/Group/Forum/NewThread.tsx +++ b/src/components/Group/Forum/NewThread.tsx @@ -141,7 +141,7 @@ export const NewThread = ({ setPostReply, isPrivate, }: NewMessageProps) => { - const { t } = useTranslation(['core', 'group']); + const { t } = useTranslation(['auth', 'core', 'group']); const { show } = useContext(MyContext); const [isOpen, setIsOpen] = useState(false); const [value, setValue] = useState(''); diff --git a/src/components/Group/Forum/Thread.tsx b/src/components/Group/Forum/Thread.tsx index 3ab2862..82ed71f 100644 --- a/src/components/Group/Forum/Thread.tsx +++ b/src/components/Group/Forum/Thread.tsx @@ -115,7 +115,7 @@ export const Thread = ({ const [isLoading, setIsLoading] = useState(true); const [postReply, setPostReply] = useState(null); const [hasLastPage, setHasLastPage] = useState(false); - const { t } = useTranslation(['core']); + const { t } = useTranslation(['auth', 'core', 'group']); const theme = useTheme(); // Update: Use a new ref for the scrollable container const threadContainerRef = useRef(null); diff --git a/src/components/Group/Group.tsx b/src/components/Group/Group.tsx index 9c6e2aa..be36d56 100644 --- a/src/components/Group/Group.tsx +++ b/src/components/Group/Group.tsx @@ -444,7 +444,7 @@ export const Group = ({ const [isForceShowCreationKeyPopup, setIsForceShowCreationKeyPopup] = useState(false); const groupsOwnerNamesRef = useRef({}); - const { t } = useTranslation(['core', 'group']); + const { t } = useTranslation(['auth', 'core', 'group']); const [groupsProperties, setGroupsProperties] = useAtom(groupsPropertiesAtom); const setGroupsOwnerNames = useSetAtom(groupsOwnerNamesAtom); diff --git a/src/components/Group/GroupInvites.tsx b/src/components/Group/GroupInvites.tsx index f3da8a0..d896786 100644 --- a/src/components/Group/GroupInvites.tsx +++ b/src/components/Group/GroupInvites.tsx @@ -37,7 +37,7 @@ export const GroupInvites = ({ myAddress, setOpenAddGroup }) => { } }; - const { t } = useTranslation(['core', 'group']); + const { t } = useTranslation(['auth', 'core', 'group']); const theme = useTheme(); useEffect(() => { diff --git a/src/components/Group/GroupJoinRequests.tsx b/src/components/Group/GroupJoinRequests.tsx index 0991edb..bceff37 100644 --- a/src/components/Group/GroupJoinRequests.tsx +++ b/src/components/Group/GroupJoinRequests.tsx @@ -28,7 +28,7 @@ export const GroupJoinRequests = ({ setDesktopViewMode, }) => { const [isExpanded, setIsExpanded] = React.useState(false); - const { t } = useTranslation(['core', 'group']); + const { t } = useTranslation(['auth', 'core', 'group']); const [groupsWithJoinRequests, setGroupsWithJoinRequests] = React.useState( [] ); diff --git a/src/components/Group/HomeDesktop.tsx b/src/components/Group/HomeDesktop.tsx index c270df0..cd3e273 100644 --- a/src/components/Group/HomeDesktop.tsx +++ b/src/components/Group/HomeDesktop.tsx @@ -31,7 +31,7 @@ export const HomeDesktop = ({ const [checked1, setChecked1] = React.useState(false); const [checked2, setChecked2] = React.useState(false); - const { t } = useTranslation(['core']); + const { t } = useTranslation(['auth', 'core', 'group']); const theme = useTheme(); React.useEffect(() => { diff --git a/src/components/Group/InviteMember.tsx b/src/components/Group/InviteMember.tsx index ad027e4..82fc6e5 100644 --- a/src/components/Group/InviteMember.tsx +++ b/src/components/Group/InviteMember.tsx @@ -10,7 +10,7 @@ export const InviteMember = ({ groupId, setInfoSnack, setOpenSnack, show }) => { const [value, setValue] = useState(''); const [expiryTime, setExpiryTime] = useState('259200'); const [isLoadingInvite, setIsLoadingInvite] = useState(false); - const { t } = useTranslation(['core', 'group']); + const { t } = useTranslation(['auth', 'core', 'group']); const inviteMember = async () => { try { diff --git a/src/components/Group/ListOfBans.tsx b/src/components/Group/ListOfBans.tsx index dda3760..5ffa37b 100644 --- a/src/components/Group/ListOfBans.tsx +++ b/src/components/Group/ListOfBans.tsx @@ -56,7 +56,7 @@ export const ListOfBans = ({ groupId, setInfoSnack, setOpenSnack, show }) => { const [openPopoverIndex, setOpenPopoverIndex] = useState(null); // Track which list item has the popover open const listRef = useRef(null); const [isLoadingUnban, setIsLoadingUnban] = useState(false); - const { t } = useTranslation(['core', 'group']); + const { t } = useTranslation(['auth', 'core', 'group']); const getInvites = async (groupId) => { try { diff --git a/src/components/Group/ListOfGroupPromotions.tsx b/src/components/Group/ListOfGroupPromotions.tsx index 8ca13d4..428372b 100644 --- a/src/components/Group/ListOfGroupPromotions.tsx +++ b/src/components/Group/ListOfGroupPromotions.tsx @@ -97,7 +97,7 @@ export const ListOfGroupPromotions = () => { const { show } = useContext(MyContext); const setTxList = useSetAtom(txListAtom); const theme = useTheme(); - const { t } = useTranslation(['core', 'group']); + const { t } = useTranslation(['auth', 'core', 'group']); const listRef = useRef(null); const rowVirtualizer = useVirtualizer({ count: promotions.length, diff --git a/src/components/Group/ListOfInvites.tsx b/src/components/Group/ListOfInvites.tsx index 574a9d1..f2368d4 100644 --- a/src/components/Group/ListOfInvites.tsx +++ b/src/components/Group/ListOfInvites.tsx @@ -60,7 +60,7 @@ export const ListOfInvites = ({ const [popoverAnchor, setPopoverAnchor] = useState(null); // Track which list item the popover is anchored to const [openPopoverIndex, setOpenPopoverIndex] = useState(null); // Track which list item has the popover open const [isLoadingCancelInvite, setIsLoadingCancelInvite] = useState(false); - const { t } = useTranslation(['core', 'group']); + const { t } = useTranslation(['auth', 'core', 'group']); const listRef = useRef(null); const getInvites = async (groupId) => { diff --git a/src/components/Group/ListOfJoinRequests.tsx b/src/components/Group/ListOfJoinRequests.tsx index 3b2f740..4b0d7e8 100644 --- a/src/components/Group/ListOfJoinRequests.tsx +++ b/src/components/Group/ListOfJoinRequests.tsx @@ -64,7 +64,7 @@ export const ListOfJoinRequests = ({ const [openPopoverIndex, setOpenPopoverIndex] = useState(null); // Track which list item has the popover open const listRef = useRef(null); const [isLoadingAccept, setIsLoadingAccept] = useState(false); - const { t } = useTranslation(['core', 'group']); + const { t } = useTranslation(['auth', 'core', 'group']); const getInvites = async (groupId) => { try { diff --git a/src/components/Group/ListOfMembers.tsx b/src/components/Group/ListOfMembers.tsx index 783c18c..5b71a25 100644 --- a/src/components/Group/ListOfMembers.tsx +++ b/src/components/Group/ListOfMembers.tsx @@ -42,7 +42,7 @@ const ListOfMembers = ({ const [isLoadingMakeAdmin, setIsLoadingMakeAdmin] = useState(false); const [isLoadingRemoveAdmin, setIsLoadingRemoveAdmin] = useState(false); const theme = useTheme(); - const { t } = useTranslation(['core', 'group']); + const { t } = useTranslation(['auth', 'core', 'group']); const listRef = useRef(null); const handlePopoverOpen = (event, index) => { diff --git a/src/components/Group/ListOfThreadPostsWatched.tsx b/src/components/Group/ListOfThreadPostsWatched.tsx index af9e1f0..bd3e885 100644 --- a/src/components/Group/ListOfThreadPostsWatched.tsx +++ b/src/components/Group/ListOfThreadPostsWatched.tsx @@ -14,7 +14,7 @@ import { useTranslation } from 'react-i18next'; export const ListOfThreadPostsWatched = () => { const [posts, setPosts] = useState([]); const [loading, setLoading] = useState(true); - const { t } = useTranslation(['core', 'group']); + const { t } = useTranslation(['auth', 'core', 'group']); const getPosts = async () => { try { diff --git a/src/components/Group/ManageMembers.tsx b/src/components/Group/ManageMembers.tsx index 30a2ef2..195aa34 100644 --- a/src/components/Group/ManageMembers.tsx +++ b/src/components/Group/ManageMembers.tsx @@ -71,7 +71,7 @@ export const ManageMembers = ({ setValue(newValue); }; const theme = useTheme(); - const { t } = useTranslation(['core', 'group']); + const { t } = useTranslation(['auth', 'core', 'group']); const { show } = useContext(MyContext); const setTxList = useSetAtom(txListAtom); diff --git a/src/components/Group/QMailMessages.tsx b/src/components/Group/QMailMessages.tsx index e2e4ce5..5765f09 100644 --- a/src/components/Group/QMailMessages.tsx +++ b/src/components/Group/QMailMessages.tsx @@ -54,7 +54,7 @@ export const QMailMessages = ({ userName, userAddress }) => { const [loading, setLoading] = useState(true); const theme = useTheme(); - const { t } = useTranslation(['core', 'group']); + const { t } = useTranslation(['auth', 'core', 'group']); const getMails = useCallback(async () => { try { diff --git a/src/components/Group/Settings.tsx b/src/components/Group/Settings.tsx index 6ba7e84..cea8e45 100644 --- a/src/components/Group/Settings.tsx +++ b/src/components/Group/Settings.tsx @@ -87,7 +87,7 @@ export const Settings = ({ open, setOpen, rawWallet }) => { const [checked, setChecked] = useState(false); const [isEnabledDevMode, setIsEnabledDevMode] = useAtom(enabledDevModeAtom); const theme = useTheme(); - const { t } = useTranslation(['core', 'group']); + const { t } = useTranslation(['auth', 'core', 'group']); const handleChange = (event: ChangeEvent) => { setChecked(event.target.checked); @@ -231,7 +231,7 @@ const ExportPrivateKey = ({ rawWallet }) => { const [privateKey, setPrivateKey] = useState(''); const [isOpen, setIsOpen] = useState(false); const { setOpenSnackGlobal, setInfoSnackCustom } = useContext(MyContext); - const { t } = useTranslation(['core', 'group']); + const { t } = useTranslation(['auth', 'core', 'group']); const exportPrivateKeyFunc = async () => { try { diff --git a/src/components/Group/UserListOfInvites.tsx b/src/components/Group/UserListOfInvites.tsx index 1e348d2..4850256 100644 --- a/src/components/Group/UserListOfInvites.tsx +++ b/src/components/Group/UserListOfInvites.tsx @@ -61,7 +61,7 @@ export const UserListOfInvites = ({ const [invites, setInvites] = useState([]); const [isLoading, setIsLoading] = useState(false); const theme = useTheme(); - const { t } = useTranslation(['core', 'group']); + const { t } = useTranslation(['auth', 'core', 'group']); const [popoverAnchor, setPopoverAnchor] = useState(null); // Track which list item the popover is anchored to const [openPopoverIndex, setOpenPopoverIndex] = useState(null); // Track which list item has the popover open const listRef = useRef(null); diff --git a/src/components/Home/NewUsersCTA.tsx b/src/components/Home/NewUsersCTA.tsx index b5d330b..ee80ff2 100644 --- a/src/components/Home/NewUsersCTA.tsx +++ b/src/components/Home/NewUsersCTA.tsx @@ -3,7 +3,7 @@ import { Spacer } from '../../common/Spacer'; import { useTranslation } from 'react-i18next'; export const NewUsersCTA = ({ balance }) => { - const { t } = useTranslation(['core']); + const { t } = useTranslation(['auth', 'core', 'group']); if (balance === undefined || +balance > 0) return null; diff --git a/src/components/Minting/Minting.tsx b/src/components/Minting/Minting.tsx index 5869f34..6004e69 100644 --- a/src/components/Minting/Minting.tsx +++ b/src/components/Minting/Minting.tsx @@ -45,7 +45,7 @@ export const Minting = ({ setIsOpenMinting, myAddress, show }) => { const { show: showKey, message } = useModal(); const { isShow: isShowNext, onOk, show: showNext } = useModal(); const theme = useTheme(); - const { t } = useTranslation(['core', 'auth', 'group']); + const { t } = useTranslation(['auth', 'core', 'group']); const [info, setInfo] = useState(null); const [names, setNames] = useState({}); const [accountInfos, setAccountInfos] = useState({}); diff --git a/src/components/QMailStatus.tsx b/src/components/QMailStatus.tsx index 62e7311..0bad117 100644 --- a/src/components/QMailStatus.tsx +++ b/src/components/QMailStatus.tsx @@ -8,7 +8,7 @@ import { useTranslation } from 'react-i18next'; import { useAtom } from 'jotai'; export const QMailStatus = () => { - const { t } = useTranslation(['core']); + const { t } = useTranslation(['auth', 'core', 'group']); const theme = useTheme(); const [lastEnteredTimestamp, setLastEnteredTimestamp] = useAtom( diff --git a/src/components/RegisterName.tsx b/src/components/RegisterName.tsx index e9a4116..5c367a3 100644 --- a/src/components/RegisterName.tsx +++ b/src/components/RegisterName.tsx @@ -51,7 +51,7 @@ export const RegisterName = ({ ); const [nameFee, setNameFee] = useState(null); const theme = useTheme(); - const { t } = useTranslation(['core', 'auth', 'group']); + const { t } = useTranslation(['auth', 'core', 'group']); const checkIfNameExisits = async (name) => { if (!name?.trim()) { setIsNameAvailable(Availability.NULL); diff --git a/src/components/Save/Save.tsx b/src/components/Save/Save.tsx index 38e328b..354b531 100644 --- a/src/components/Save/Save.tsx +++ b/src/components/Save/Save.tsx @@ -84,7 +84,7 @@ export const Save = ({ isDesktop, disableWidth, myName }) => { const [anchorEl, setAnchorEl] = useState(null); const { show } = useContext(MyContext); const theme = useTheme(); - const { t } = useTranslation(['core']); + const { t } = useTranslation(['auth', 'core', 'group']); const hasChanged = useMemo(() => { const newChanges = { diff --git a/src/components/Theme/ThemeSelector.tsx b/src/components/Theme/ThemeSelector.tsx index 305b4ab..9ed7d84 100644 --- a/src/components/Theme/ThemeSelector.tsx +++ b/src/components/Theme/ThemeSelector.tsx @@ -5,7 +5,7 @@ import DarkModeIcon from '@mui/icons-material/DarkMode'; import { useTranslation } from 'react-i18next'; const ThemeSelector = () => { - const { t } = useTranslation(['core']); + const { t } = useTranslation(['auth', 'core', 'group']); const { themeMode, toggleTheme } = useThemeContext(); diff --git a/src/i18n/locales/en/core.json b/src/i18n/locales/en/core.json index 18cffb2..3b0db29 100644 --- a/src/i18n/locales/en/core.json +++ b/src/i18n/locales/en/core.json @@ -5,6 +5,7 @@ "add_reaction": "add reaction", "accept": "accept", "access": "access", + "access_app": "access app", "backup_account": "backup account", "backup_wallet": "backup wallet", "cancel": "cancel", @@ -44,7 +45,7 @@ "login": "login", "logout": "logout", "new": { - "chat": "chat", + "chat": "new chat", "post": "new post", "thread": "new thread" }, @@ -83,6 +84,7 @@ "all": "all", "api": "API", "app": "app", + "app_other": "apps", "app_name": "app name", "app_service_type": "app service type", "apps_dashboard": "apps Dashboard", @@ -90,12 +92,14 @@ "attachment": "attachment", "category": "category", "category_other": "categories", + "chat": "chat", "core": { "block_height": "block height", "information": "core information", "peers": "connected peers", "version": "core version" }, + "dev": "dev", "domain": "domain", "ui": { "version": "UI version" diff --git a/src/i18n/locales/en/group.json b/src/i18n/locales/en/group.json index 45be215..c4042bf 100644 --- a/src/i18n/locales/en/group.json +++ b/src/i18n/locales/en/group.json @@ -44,6 +44,7 @@ "invites": "group invites", "group": "group", "group_other": "groups", + "groups_admin": "groups where you are an admin", "management": "group management", "member_number": "number of members", "messaging": "messaging", diff --git a/src/i18n/locales/it/core.json b/src/i18n/locales/it/core.json index 8bf930d..ee4e4fc 100644 --- a/src/i18n/locales/it/core.json +++ b/src/i18n/locales/it/core.json @@ -60,7 +60,7 @@ "remove": "remove", "remove_reaction": "remove reaction", "return_apps_dashboard": "return to Apps Dashboard", - "save": "save", + "save": "salva", "search": "search", "search_apps": "search for apps", "select_app_type": "select App Type", @@ -80,18 +80,21 @@ "all": "all", "api": "API", "app": "app", + "app_other": "apps", "app_name": "app name", "app_service_type": "app service type", "apps_dashboard": "apps Dashboard", "apps_official": "official Apps", "category": "category", "category_other": "categories", + "chat": "chat", "core": { "block_height": "altezza blocco", "information": "informazioni core", "peers": "peer connessi", "version": "versione core" }, + "dev": "dev", "domain": "domain", "ui": { "version": "versione UI"