diff --git a/docs/i18n_languages.md b/docs/i18n_languages.md index 7447193..9fcf779 100644 --- a/docs/i18n_languages.md +++ b/docs/i18n_languages.md @@ -7,4 +7,4 @@ In JSON file: In GUI: -- If the first letter of the translation must be uppercase, use the postProcess, for example: `{t_auth('advanced_users', { postProcess: 'capitalize' })}` +- If the first letter of the translation must be uppercase, use the postProcess, for example: `{t_auth('advanced_users', { postProcess: 'capitalizeFirst' })}` diff --git a/src/App.tsx b/src/App.tsx index 17dea23..e5f9cc0 100644 --- a/src/App.tsx +++ b/src/App.tsx @@ -2514,7 +2514,9 @@ function App() { setExtstate('create-wallet'); }} > - {t('auth:action.create_account', { postProcess: 'capitalize' })} + {t('auth:action.create_account', { + postProcess: 'capitalizeFirst', + })} )} @@ -2611,7 +2613,9 @@ function App() { fontWeight: 600, }} > - {t('auth:action.authenticate', { postProcess: 'capitalize' })} + {t('auth:action.authenticate', { + postProcess: 'capitalizeFirst', + })} @@ -2619,7 +2623,7 @@ function App() { <> - {t('auth:wallet.password', { postProcess: 'capitalize' })} + {t('auth:wallet.password', { postProcess: 'capitalizeFirst' })} @@ -2643,7 +2647,7 @@ function App() { fontSize: '12px', }} > - {t('auth:node.using', { postProcess: 'capitalize' })}:{' '} + {t('auth:node.using', { postProcess: 'capitalizeFirst' })}:{' '} {currentNode?.url} @@ -2655,7 +2659,9 @@ function App() { fontSize: '12px', }} > - {t('auth:node.using_public', { postProcess: 'capitalize' })} + {t('auth:node.using_public', { + postProcess: 'capitalizeFirst', + })} )} @@ -2663,7 +2669,9 @@ function App() { - {t('auth:action.authenticate', { postProcess: 'capitalize' })} + {t('auth:action.authenticate', { + postProcess: 'capitalizeFirst', + })} {walletToBeDecryptedError} @@ -2932,7 +2940,7 @@ function App() { {t('auth:action.create_account', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -2978,7 +2986,7 @@ function App() { }} > {t('core:action.backup_account', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -3008,7 +3016,7 @@ function App() { }} > {t('core:message.success.transfer', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -3019,7 +3027,7 @@ function App() { }} > - {t('core:action.continue', { postProcess: 'capitalize' })} + {t('core:action.continue', { postProcess: 'capitalizeFirst' })} @@ -3036,7 +3044,7 @@ function App() { }} > {t('core:message.success.transfer', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -3045,7 +3053,7 @@ function App() { window.close(); }} > - {t('core:action.continue', { postProcess: 'capitalize' })} + {t('core:action.continue', { postProcess: 'capitalizeFirst' })} )} @@ -3061,7 +3069,7 @@ function App() { }} > {t('core:message.success.order_submitted', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -3070,7 +3078,7 @@ function App() { window.close(); }} > - {t('core:action.close', { postProcess: 'capitalize' })} + {t('core:action.close', { postProcess: 'capitalizeFirst' })} )} @@ -3119,7 +3127,7 @@ function App() { {message?.paymentFee && ( {t('core:fee.payment', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} : {message.paymentFee} @@ -3127,7 +3135,7 @@ function App() { {message?.publishFee && ( {t('core:fee.publish', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} : {message.publishFee} @@ -3151,7 +3159,7 @@ function App() { autoFocus > {t('core:action.accept', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -3193,7 +3201,7 @@ function App() { @@ -3214,7 +3222,7 @@ function App() { @@ -3502,7 +3510,7 @@ function App() { {t('core:message.success.request_read', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -3552,7 +3560,7 @@ function App() { }} > {t('core:action.accept', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} onCancelQortalRequestExtension()} > {t('core:action.decline', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} diff --git a/src/ExtStates/NotAuthenticated.tsx b/src/ExtStates/NotAuthenticated.tsx index 2a6b090..c2f6e74 100644 --- a/src/ExtStates/NotAuthenticated.tsx +++ b/src/ExtStates/NotAuthenticated.tsx @@ -351,7 +351,8 @@ export const NotAuthenticated = ({ .catch((error) => { console.error( 'Failed to set API key:', - error.message || t('core:error', { postProcess: 'capitalize' }) + error.message || + t('core:error', { postProcess: 'capitalizeFirst' }) ); }); } else { @@ -361,7 +362,7 @@ export const NotAuthenticated = ({ setInfoSnack({ type: 'error', message: t('auth:apikey.select_valid', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }), }); setOpenSnack(true); @@ -387,7 +388,7 @@ export const NotAuthenticated = ({ 'Failed to set API key:', error.message || t('core:error', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }) ); }); @@ -399,7 +400,7 @@ export const NotAuthenticated = ({ message: error?.message || t('auth:apikey.select_valid', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }), }); setOpenSnack(true); @@ -481,7 +482,7 @@ export const NotAuthenticated = ({ fontSize: '18px', }} > - {t('auth:welcome', { postProcess: 'capitalize' })} + {t('auth:welcome', { postProcess: 'capitalizeFirst' })} - {t('auth:tips.digital_id', { postProcess: 'capitalize' })} + {t('auth:tips.digital_id', { postProcess: 'capitalizeFirst' })} } > setExtstate('wallets')}> - {t('auth:account.account_many', { postProcess: 'capitalize' })} + {t('auth:account.account_many', { postProcess: 'capitalizeFirst' })} @@ -542,7 +543,7 @@ export const NotAuthenticated = ({ fontSize: '18px', }} > - {t('auth:tips.new_users', { postProcess: 'capitalize' })} + {t('auth:tips.new_users', { postProcess: 'capitalizeFirst' })} - {t('auth:tips.new_account', { postProcess: 'capitalize' })} + {t('auth:tips.new_account', { postProcess: 'capitalizeFirst' })} } @@ -572,7 +573,9 @@ export const NotAuthenticated = ({ }, }} > - {t('auth:action.create_account', { postProcess: 'capitalize' })} + {t('auth:action.create_account', { + postProcess: 'capitalizeFirst', + })} @@ -585,7 +588,7 @@ export const NotAuthenticated = ({ visibility: !useLocalNode && 'hidden', }} > - {t('auth:node.using', { postProcess: 'capitalize' })}:{' '} + {t('auth:node.using', { postProcess: 'capitalizeFirst' })}:{' '} {currentNode?.url} @@ -613,7 +616,7 @@ export const NotAuthenticated = ({ textDecoration: 'underline', }} > - {t('auth:advanced_users', { postProcess: 'capitalize' })} + {t('auth:advanced_users', { postProcess: 'capitalizeFirst' })} @@ -676,8 +683,12 @@ export const NotAuthenticated = ({ component="label" > {apiKey - ? t('auth:node.use_local', { postProcess: 'capitalize' }) - : t('auth:apikey.import', { postProcess: 'capitalize' })} + ? t('auth:node.use_local', { + postProcess: 'capitalizeFirst', + }) + : t('auth:apikey.import', { + postProcess: 'capitalizeFirst', + })} - {t('auth:apikey.key', { postProcess: 'capitalize' })}:{' '} + {t('auth:apikey.key', { postProcess: 'capitalizeFirst' })}:{' '} {importedApiKey} @@ -698,7 +709,7 @@ export const NotAuthenticated = ({ variant="contained" component="label" > - {t('auth:node.choose', { postProcess: 'capitalize' })} + {t('auth:node.choose', { postProcess: 'capitalizeFirst' })} - {t('auth:build_version', { postProcess: 'capitalize' })}: + {t('auth:build_version', { postProcess: 'capitalizeFirst' })}: {manifestData?.version} @@ -728,7 +739,7 @@ export const NotAuthenticated = ({ > {' '} - {t('auth:node.custom_many', { postProcess: 'capitalize' })}: + {t('auth:node.custom_many', { postProcess: 'capitalizeFirst' })}: - {t('core:action.choose', { postProcess: 'capitalize' })} + {t('core:action.choose', { + postProcess: 'capitalizeFirst', + })} @@ -858,7 +871,7 @@ export const NotAuthenticated = ({ variant="contained" > {t('core:action.choose', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -873,7 +886,7 @@ export const NotAuthenticated = ({ variant="contained" > {t('core:action.edit', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -887,7 +900,9 @@ export const NotAuthenticated = ({ }} variant="contained" > - {t('core:remove', { postProcess: 'capitalize' })} + {t('core:remove', { + postProcess: 'capitalizeFirst', + })} @@ -926,7 +941,7 @@ export const NotAuthenticated = ({ {mode === 'list' && ( )} @@ -939,7 +954,7 @@ export const NotAuthenticated = ({ }} autoFocus > - {t('core:action.close', { postProcess: 'capitalize' })} + {t('core:action.close', { postProcess: 'capitalizeFirst' })} )} @@ -954,7 +969,7 @@ export const NotAuthenticated = ({ }} > {t('auth:action.return_to_list', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -964,7 +979,7 @@ export const NotAuthenticated = ({ onClick={() => saveCustomNodes(customNodes)} autoFocus > - {t('core:save', { postProcess: 'capitalize' })} + {t('core:save', { postProcess: 'capitalizeFirst' })} )} @@ -979,7 +994,7 @@ export const NotAuthenticated = ({ aria-describedby="alert-dialog-description" > - {t('auth:apikey.enter', { postProcess: 'capitalize' })} + {t('auth:apikey.enter', { postProcess: 'capitalizeFirst' })} - {t('auth:apikey.alternative', { postProcess: 'capitalize' })} + {t('auth:apikey.alternative', { + postProcess: 'capitalizeFirst', + })} - {t('core:save', { postProcess: 'capitalize' })} + {t('core:save', { postProcess: 'capitalizeFirst' })} diff --git a/src/Wallets.tsx b/src/Wallets.tsx index 9fb153b..bd41369 100644 --- a/src/Wallets.tsx +++ b/src/Wallets.tsx @@ -152,7 +152,7 @@ export const Wallets = ({ setExtState, setRawWallet, rawWallet }) => { } else { setSeedError( t('auth:message.error.account_creation', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }) ); } @@ -160,7 +160,7 @@ export const Wallets = ({ setExtState, setRawWallet, rawWallet }) => { setSeedError( error?.message || t('auth:message.error.account_creation', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }) ); } finally { @@ -202,7 +202,7 @@ export const Wallets = ({ setExtState, setRawWallet, rawWallet }) => { <> {t('auth:message.generic.no_account', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -212,7 +212,7 @@ export const Wallets = ({ setExtState, setRawWallet, rawWallet }) => { <> {t('auth:message.generic.your_accounts', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -224,7 +224,7 @@ export const Wallets = ({ setExtState, setRawWallet, rawWallet }) => { {t('auth:account.selected', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} : @@ -282,7 +282,9 @@ export const Wallets = ({ setExtState, setRawWallet, rawWallet }) => { fontSize: '16px', }} > - {t('auth:tips.existing_account', { postProcess: 'capitalize' })} + {t('auth:tips.existing_account', { + postProcess: 'capitalizeFirst', + })} } @@ -294,7 +296,9 @@ export const Wallets = ({ setExtState, setRawWallet, rawWallet }) => { display: 'inline', }} > - {t('auth:action.add.seed_phrase', { postProcess: 'capitalize' })} + {t('auth:action.add.seed_phrase', { + postProcess: 'capitalizeFirst', + })} @@ -309,7 +313,7 @@ export const Wallets = ({ setExtState, setRawWallet, rawWallet }) => { }} > {t('auth:tips.additional_wallet', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -323,7 +327,7 @@ export const Wallets = ({ setExtState, setRawWallet, rawWallet }) => { > {t('auth:action.add.account', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -341,7 +345,7 @@ export const Wallets = ({ setExtState, setRawWallet, rawWallet }) => { > {t('auth:message.generic.type_seed', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -354,7 +358,7 @@ export const Wallets = ({ setExtState, setRawWallet, rawWallet }) => { > { { { }} > {t('core:action.close', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} { autoFocus > {t('core:action.add', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} { }} > {t('core:action.login', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -546,7 +550,7 @@ const WalletItem = ({ wallet, updateWalletItem, idx, setSelectedWallet }) => { > { { onClick={() => setIsEdit(false)} > {t('core:action.close', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} diff --git a/src/components/Apps/AppInfo.tsx b/src/components/Apps/AppInfo.tsx index b36799a..6e8e274 100644 --- a/src/components/Apps/AppInfo.tsx +++ b/src/components/Apps/AppInfo.tsx @@ -174,10 +174,10 @@ export const AppInfo = ({ app, myName }) => { {isSelectedAppPinned ? t('core:action.unpin_from_dashboard', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }) : t('core:action.pin_from_dashboard', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -200,10 +200,10 @@ export const AppInfo = ({ app, myName }) => { {isInstalled ? t('core:action.open', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }) : t('core:action.download', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -229,7 +229,7 @@ export const AppInfo = ({ app, myName }) => { {t('core:category', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} : @@ -239,7 +239,7 @@ export const AppInfo = ({ app, myName }) => { {app?.metadata?.categoryName || t('core:none', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -249,7 +249,7 @@ export const AppInfo = ({ app, myName }) => { {t('core:q_apps.about', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -259,7 +259,7 @@ export const AppInfo = ({ app, myName }) => { {app?.metadata?.description || t('core:message.generic.no_description', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} diff --git a/src/components/Apps/AppInfoSnippet.tsx b/src/components/Apps/AppInfoSnippet.tsx index c027bb0..1629b5e 100644 --- a/src/components/Apps/AppInfoSnippet.tsx +++ b/src/components/Apps/AppInfoSnippet.tsx @@ -173,10 +173,10 @@ export const AppInfoSnippet = ({ {isSelectedAppPinned ? t('core:action.unpin', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }) : t('core:action.pin', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -196,10 +196,10 @@ export const AppInfoSnippet = ({ {isInstalled ? t('core:action.open', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }) : t('core:action.download', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} diff --git a/src/components/Apps/AppPublish.tsx b/src/components/Apps/AppPublish.tsx index 1425ba6..6ab1525 100644 --- a/src/components/Apps/AppPublish.tsx +++ b/src/components/Apps/AppPublish.tsx @@ -96,7 +96,7 @@ export const AppPublish = ({ names, categories }) => { t('core:message.error.file_too_large', { filename: file.name, size: maxFileSize / (1024 * 1024), - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }) ); } @@ -171,7 +171,7 @@ export const AppPublish = ({ names, categories }) => { const missingFieldsString = missingFields.join(', '); const errorMsg = t('core:message.error.missing_fields', { fields: missingFieldsString, - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }); throw new Error(errorMsg); } @@ -179,13 +179,13 @@ export const AppPublish = ({ names, categories }) => { await show({ message: t('core:save_options.publish_app', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }), publishFee: fee.fee + ' QORT', }); setIsLoading( t('core:message.generic.publishing', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }) ); const fileBase64 = await fileToBase64(file); @@ -214,14 +214,16 @@ export const AppPublish = ({ names, categories }) => { .catch((error) => { rej( error.message || - t('core:message.error.generic', { postProcess: 'capitalize' }) + t('core:message.error.generic', { + postProcess: 'capitalizeFirst', + }) ); }); }); setInfoSnack({ type: 'success', message: t('core:message.success.published', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }), }); setOpenSnack(true); @@ -244,7 +246,7 @@ export const AppPublish = ({ names, categories }) => { message: error?.message || t('core:message.error.publish_app', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }), }); setOpenSnack(true); @@ -268,7 +270,7 @@ export const AppPublish = ({ names, categories }) => { > {t('core:action.create_apps', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} ! @@ -277,7 +279,7 @@ export const AppPublish = ({ names, categories }) => { {t('core:message.generic.one_app_per_name', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -285,7 +287,7 @@ export const AppPublish = ({ names, categories }) => { {t('core:name_app', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -302,7 +304,7 @@ export const AppPublish = ({ names, categories }) => { }} > {t('core:action.select_name_app', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} {/* This is the placeholder item */} @@ -316,7 +318,7 @@ export const AppPublish = ({ names, categories }) => { {t('core:app_service_type', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -333,18 +335,18 @@ export const AppPublish = ({ names, categories }) => { }} > {t('core:action.select_app_type', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} {t('core:app', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} {t('core:website', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -353,7 +355,7 @@ export const AppPublish = ({ names, categories }) => { {t('core:title', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -380,7 +382,7 @@ export const AppPublish = ({ names, categories }) => { {t('core:description', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -407,7 +409,7 @@ export const AppPublish = ({ names, categories }) => { {t('core:category', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -424,7 +426,7 @@ export const AppPublish = ({ names, categories }) => { }} > {t('core:action.select_category', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -441,7 +443,7 @@ export const AppPublish = ({ names, categories }) => { {t('core:tags', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -536,7 +538,9 @@ export const AppPublish = ({ names, categories }) => { - {t('core:message.generic.select_zip', { postProcess: 'capitalize' })} + {t('core:message.generic.select_zip', { + postProcess: 'capitalizeFirst', + })} @@ -556,7 +560,7 @@ export const AppPublish = ({ names, categories }) => { {' '} - {t('core:action.choose_file', { postProcess: 'capitalize' })} + {t('core:action.choose_file', { postProcess: 'capitalizeFirst' })} @@ -567,7 +571,7 @@ export const AppPublish = ({ names, categories }) => { }} onClick={publishApp} > - {t('core:action.publish', { postProcess: 'capitalize' })} + {t('core:action.publish', { postProcess: 'capitalizeFirst' })} diff --git a/src/components/Apps/AppRating.tsx b/src/components/Apps/AppRating.tsx index 7252c1f..34bdee0 100644 --- a/src/components/Apps/AppRating.tsx +++ b/src/components/Apps/AppRating.tsx @@ -106,7 +106,7 @@ export const AppRating = ({ app, myName, ratingCountPosition = 'right' }) => { if (!myName) throw new Error( t('core:message.generic.name_rate', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }) ); if (!app?.name) return; @@ -115,7 +115,7 @@ export const AppRating = ({ app, myName, ratingCountPosition = 'right' }) => { await show({ message: t('core:message.error.generic', { rate: newValue, - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }), publishFee: fee.fee + ' QORT', }); @@ -126,7 +126,7 @@ export const AppRating = ({ app, myName, ratingCountPosition = 'right' }) => { const pollDescription = t('core:message.error.generic', { name: app.name, service: app.service, - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }); await new Promise((res, rej) => { @@ -150,7 +150,7 @@ export const AppRating = ({ app, myName, ratingCountPosition = 'right' }) => { setInfoSnack({ type: 'success', message: t('core:message.success.rated_app', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }), }); setOpenSnack(true); @@ -169,7 +169,7 @@ export const AppRating = ({ app, myName, ratingCountPosition = 'right' }) => { if (isNaN(optionIndex) || optionIndex === -1) throw new Error( t('core:message.error.rating_option', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }) ); await new Promise((res, rej) => { @@ -191,7 +191,7 @@ export const AppRating = ({ app, myName, ratingCountPosition = 'right' }) => { setInfoSnack({ type: 'success', message: t('core:message.success.rated_app', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }), }); setOpenSnack(true); @@ -209,7 +209,7 @@ export const AppRating = ({ app, myName, ratingCountPosition = 'right' }) => { message: error?.message || t('core:message.error.unable_rate', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }), }); setOpenSnack(true); diff --git a/src/components/Apps/AppsDesktop.tsx b/src/components/Apps/AppsDesktop.tsx index d1268fb..56c4985 100644 --- a/src/components/Apps/AppsDesktop.tsx +++ b/src/components/Apps/AppsDesktop.tsx @@ -24,6 +24,7 @@ import { AppsIcon } from '../../assets/Icons/AppsIcon'; import { CoreSyncStatus } from '../CoreSyncStatus'; import { MessagingIconFilled } from '../../assets/Icons/MessagingIconFilled'; import { useAtom } from 'jotai'; +import { useTranslation } from 'react-i18next'; const uid = new ShortUniqueId({ length: 8 }); @@ -47,9 +48,9 @@ export const AppsDesktop = ({ const [categories, setCategories] = useState([]); const iframeRefs = useRef({}); const [isEnabledDevMode, setIsEnabledDevMode] = useAtom(enabledDevModeAtom); - const { showTutorial } = useContext(MyContext); const theme = useTheme(); + const { t } = useTranslation(['core', 'group']); const myApp = useMemo(() => { return availableQapps.find( @@ -104,7 +105,6 @@ export const AppsDesktop = ({ try { let apps = []; let websites = []; - // dispatch(setIsLoadingGlobal(true)) const url = `${getBaseApiReact()}/arbitrary/resources/search?service=APP&mode=ALL&limit=0&includestatus=true&includemetadata=true`; const response = await fetch(url, { @@ -113,6 +113,7 @@ export const AppsDesktop = ({ 'Content-Type': 'application/json', }, }); + if (!response?.ok) return; const responseData = await response.json(); const urlWebsites = `${getBaseApiReact()}/arbitrary/resources/search?service=WEBSITE&mode=ALL&limit=0&includestatus=true&includemetadata=true`; @@ -123,6 +124,7 @@ export const AppsDesktop = ({ 'Content-Type': 'application/json', }, }); + if (!responseWebsites?.ok) return; const responseDataWebsites = await responseWebsites.json(); diff --git a/src/components/Auth/DownloadWallet.tsx b/src/components/Auth/DownloadWallet.tsx index f96dbb6..eb85a20 100644 --- a/src/components/Auth/DownloadWallet.tsx +++ b/src/components/Auth/DownloadWallet.tsx @@ -76,14 +76,16 @@ export const DownloadWallet = ({ if (!keepCurrentPassword && !newPassword) { setWalletToBeDownloadedError( t('auth:wallet.error.missing_new_password', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }) ); return; } if (!walletToBeDownloadedPassword) { setWalletToBeDownloadedError( - t('auth:wallet.error.missing_password', { postProcess: 'capitalize' }) + t('auth:wallet.error.missing_password', { + postProcess: 'capitalizeFirst', + }) ); return; } @@ -157,7 +159,9 @@ export const DownloadWallet = ({ fontWeight: 600, }} > - {t('auth:action.download_account', { postProcess: 'capitalize' })} + {t('auth:action.download_account', { + postProcess: 'capitalizeFirst', + })} @@ -167,7 +171,7 @@ export const DownloadWallet = ({ <> {t('auth:wallet.password_confirmation', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -206,7 +210,7 @@ export const DownloadWallet = ({ {t('auth:wallet.keep_password', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -217,7 +221,7 @@ export const DownloadWallet = ({ <> {t('auth:wallet.new_password', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -233,7 +237,7 @@ export const DownloadWallet = ({ {t('auth:password_confirmation', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -248,13 +252,13 @@ export const DownloadWallet = ({ await saveFileToDiskFunc(); await showInfo({ message: t('auth:message.generic.keep_secure', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }), }); }} > {t('auth:action.download_account', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} diff --git a/src/components/Chat/GroupAnnouncements.tsx b/src/components/Chat/GroupAnnouncements.tsx index c91bfaa..af92b71 100644 --- a/src/components/Chat/GroupAnnouncements.tsx +++ b/src/components/Chat/GroupAnnouncements.tsx @@ -291,7 +291,7 @@ export const GroupAnnouncements = ({ await show({ message: t('group:question.perform_transaction', { action: 'ARBITRARY', - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }), publishFee: fee.fee + ' QORT', }); diff --git a/src/components/CoreSyncStatus.tsx b/src/components/CoreSyncStatus.tsx index 79e22d2..3e782c4 100644 --- a/src/components/CoreSyncStatus.tsx +++ b/src/components/CoreSyncStatus.tsx @@ -77,26 +77,26 @@ export const CoreSyncStatus = () => { let imagePath = syncingImg; let message = t('core:message.status.synchronizing', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }); if (isMintingPossible && !isUsingGateway) { imagePath = syncedMintingImg; - message = `${t(`core:message.status.${isSynchronizing ? 'synchronizing' : 'synchronized'}`, { postProcess: 'capitalize' })} ${t('core:message.status.minting')}`; + message = `${t(`core:message.status.${isSynchronizing ? 'synchronizing' : 'synchronized'}`, { postProcess: 'capitalizeFirst' })} ${t('core:message.status.minting')}`; } else if (isSynchronizing === true && syncPercent === 99) { imagePath = syncingImg; } else if (isSynchronizing && !isMintingPossible && syncPercent === 100) { imagePath = syncingImg; - message = `${t('core:message.status.synchronizing', { postProcess: 'capitalize' })} ${!isUsingGateway ? t('core:message.status.not_minting') : ''}`; + message = `${t('core:message.status.synchronizing', { postProcess: 'capitalizeFirst' })} ${!isUsingGateway ? t('core:message.status.not_minting') : ''}`; } else if (!isSynchronizing && !isMintingPossible && syncPercent === 100) { imagePath = syncedImg; - message = `${t('core:message.status.synchronized', { postProcess: 'capitalize' })} ${!isUsingGateway ? t('core:message.status.not_minting') : ''}`; + message = `${t('core:message.status.synchronized', { postProcess: 'capitalizeFirst' })} ${!isUsingGateway ? t('core:message.status.not_minting') : ''}`; } else if (isSynchronizing && isMintingPossible && syncPercent === 100) { imagePath = syncingImg; - message = `${t('core:message.status.synchronizing', { postProcess: 'capitalize' })} ${!isUsingGateway ? t('core:message.status.minting') : ''}`; + message = `${t('core:message.status.synchronizing', { postProcess: 'capitalizeFirst' })} ${!isUsingGateway ? t('core:message.status.minting') : ''}`; } else if (!isSynchronizing && isMintingPossible && syncPercent === 100) { imagePath = syncedMintingImg; - message = `${t('core:message.status.synchronized', { postProcess: 'capitalize' })} ${!isUsingGateway ? t('core:message.status.minting') : ''}`; + message = `${t('core:message.status.synchronized', { postProcess: 'capitalizeFirst' })} ${!isUsingGateway ? t('core:message.status.minting') : ''}`; } return ( @@ -121,36 +121,38 @@ export const CoreSyncStatus = () => { top: '10px', }} > -

{t('core:core.information', { postProcess: 'capitalize' })}

+

+ {t('core:core.information', { postProcess: 'capitalizeFirst' })} +

- {t('core:core.version', { postProcess: 'capitalize' })}:{' '} + {t('core:core.version', { postProcess: 'capitalizeFirst' })}:{' '} {buildVersion}

{message}

- {t('core:core.block_height', { postProcess: 'capitalize' })}:{' '} + {t('core:core.block_height', { postProcess: 'capitalizeFirst' })}:{' '} {height || ''}

- {t('core:core.peers', { postProcess: 'capitalize' })}:{' '} + {t('core:core.peers', { postProcess: 'capitalizeFirst' })}:{' '} {numberOfConnections || ''}

- {t('auth:node.using_public', { postProcess: 'capitalize' })}:{' '} + {t('auth:node.using_public', { postProcess: 'capitalizeFirst' })}:{' '} {isUsingGateway?.toString()}

- {t('core:ui.version', { postProcess: 'capitalize' })}:{' '} + {t('core:ui.version', { postProcess: 'capitalizeFirst' })}:{' '} {manifestData.version}

diff --git a/src/components/Explore/Explore.tsx b/src/components/Explore/Explore.tsx index 3da3cf5..33c7876 100644 --- a/src/components/Explore/Explore.tsx +++ b/src/components/Explore/Explore.tsx @@ -46,7 +46,7 @@ export const Explore = ({ setDesktopViewMode }) => { fontSize: '1rem', }} > - {t('tutorial:initial.trade_qort', { postProcess: 'capitalize' })} + {t('tutorial:initial.trade_qort', { postProcess: 'capitalizeFirst' })} @@ -73,7 +73,7 @@ export const Explore = ({ setDesktopViewMode }) => { fontSize: '1rem', }} > - {t('tutorial:initial.see_apps', { postProcess: 'capitalize' })} + {t('tutorial:initial.see_apps', { postProcess: 'capitalizeFirst' })} @@ -102,7 +102,9 @@ export const Explore = ({ setDesktopViewMode }) => { fontSize: '1rem', }} > - {t('tutorial:initial.general_chat', { postProcess: 'capitalize' })} + {t('tutorial:initial.general_chat', { + postProcess: 'capitalizeFirst', + })} @@ -129,7 +131,7 @@ export const Explore = ({ setDesktopViewMode }) => { fontSize: '1rem', }} > - {t('core:wallet.wallet_other', { postProcess: 'capitalize' })} + {t('core:wallet.wallet_other', { postProcess: 'capitalizeFirst' })} diff --git a/src/components/GlobalActions/JoinGroup.tsx b/src/components/GlobalActions/JoinGroup.tsx index a56d642..a6ec98f 100644 --- a/src/components/GlobalActions/JoinGroup.tsx +++ b/src/components/GlobalActions/JoinGroup.tsx @@ -72,7 +72,7 @@ export const JoinGroup = () => { await show({ message: t('group:question.perform_transaction', { action: 'JOIN_GROUP', - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }), publishFee: fee.fee + ' QORT', }); @@ -89,7 +89,7 @@ export const JoinGroup = () => { setInfoSnack({ type: 'success', message: t('group:message.success.group_join', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }), }); @@ -100,11 +100,11 @@ export const JoinGroup = () => { type: 'joined-group', label: t('group:message.success.group_join_label', { group_name: group?.groupName, - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }), labelDone: t('group:message.success.group_join_label', { group_name: group?.groupName, - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }), done: false, groupId, @@ -118,11 +118,11 @@ export const JoinGroup = () => { type: 'joined-group-request', label: t('group:message.success.group_join_request', { group_name: group?.groupName, - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }), labelDone: t('group:message.success.group_join_outcome', { group_name: group?.groupName, - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }), done: false, groupId, @@ -147,7 +147,9 @@ export const JoinGroup = () => { type: 'error', message: error.message || - t('core:message.error.generic', { postProcess: 'capitalize' }), + t('core:message.error.generic', { + postProcess: 'capitalizeFirst', + }), }); setOpenSnack(true); rej(error); @@ -205,7 +207,7 @@ export const JoinGroup = () => { fontWeight: 600, }} > - {t('group:group.name', { postProcess: 'capitalize' })}:{' '} + {t('group:group.name', { postProcess: 'capitalizeFirst' })}:{' '} {` ${groupInfo?.groupName}`} @@ -215,8 +217,10 @@ export const JoinGroup = () => { fontWeight: 600, }} > - {t('group:group.member_number', { postProcess: 'capitalize' })}:{' '} - {` ${groupInfo?.memberCount}`} + {t('group:group.member_number', { + postProcess: 'capitalizeFirst', + })} + : {` ${groupInfo?.memberCount}`} {groupInfo?.description && ( @@ -237,7 +241,7 @@ export const JoinGroup = () => { }} > {t('group:message.generic.already_in_group', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} )} @@ -249,7 +253,7 @@ export const JoinGroup = () => { }} > {t('group:message.generic.closed_group', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} )} @@ -276,7 +280,7 @@ export const JoinGroup = () => { }} > {t('core:action.join', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -291,7 +295,7 @@ export const JoinGroup = () => { onClick={() => setIsOpen(false)} > {t('core:action.close', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} diff --git a/src/components/Group/AddGroup.tsx b/src/components/Group/AddGroup.tsx index 8b91ebe..b1da7e5 100644 --- a/src/components/Group/AddGroup.tsx +++ b/src/components/Group/AddGroup.tsx @@ -105,13 +105,13 @@ export const AddGroup = ({ address, open, setOpen }) => { if (!name) throw new Error( t('group:message.error.name_required', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }) ); if (!description) throw new Error( t('group:message.error.description_required', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }) ); @@ -120,7 +120,7 @@ export const AddGroup = ({ address, open, setOpen }) => { await show({ message: t('group:question.perform_transaction', { action: 'CREATE_GROUP', - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }), publishFee: fee.fee + ' QORT', }); @@ -140,7 +140,7 @@ export const AddGroup = ({ address, open, setOpen }) => { setInfoSnack({ type: 'success', message: t('group:message.success.group_creation', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }), }); setOpenSnack(true); @@ -150,11 +150,11 @@ export const AddGroup = ({ address, open, setOpen }) => { type: 'created-group', label: t('group:message.success.group_creation_name', { group_name: name, - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }), labelDone: t('group:message.success.group_creation_label', { group_name: name, - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }), done: false, }, @@ -172,7 +172,9 @@ export const AddGroup = ({ address, open, setOpen }) => { rej({ message: error.message || - t('core:message.error.generic', { postProcess: 'capitalize' }), + t('core:message.error.generic', { + postProcess: 'capitalizeFirst', + }), }); }); }); @@ -225,7 +227,7 @@ export const AddGroup = ({ address, open, setOpen }) => { > - {t('group:group.management', { postProcess: 'capitalize' })} + {t('group:group.management', { postProcess: 'capitalizeFirst' })} { > { /> { /> { > setName(e.target.value)} @@ -350,13 +352,13 @@ export const AddGroup = ({ address, open, setOpen }) => { > setDescription(e.target.value)} @@ -372,7 +374,7 @@ export const AddGroup = ({ address, open, setOpen }) => { > @@ -385,12 +387,12 @@ export const AddGroup = ({ address, open, setOpen }) => { > {t('group:group.open', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} {t('group:group.closed', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -407,7 +409,7 @@ export const AddGroup = ({ address, open, setOpen }) => { > {t('group:advanced_options', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -424,7 +426,7 @@ export const AddGroup = ({ address, open, setOpen }) => { > @@ -437,12 +439,12 @@ export const AddGroup = ({ address, open, setOpen }) => { > {t('core:count.none', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} {t('core:count.one', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} 20% @@ -462,7 +464,7 @@ export const AddGroup = ({ address, open, setOpen }) => { > @@ -521,7 +523,7 @@ export const AddGroup = ({ address, open, setOpen }) => { > @@ -582,7 +584,7 @@ export const AddGroup = ({ address, open, setOpen }) => { onClick={handleCreateGroup} > {t('group:action.create_group', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} diff --git a/src/components/Group/AddGroupList.tsx b/src/components/Group/AddGroupList.tsx index 49dce3d..5c577f1 100644 --- a/src/components/Group/AddGroupList.tsx +++ b/src/components/Group/AddGroupList.tsx @@ -115,7 +115,7 @@ export const AddGroupList = ({ setInfoSnack, setOpenSnack }) => { await show({ message: t('group:question.perform_transaction', { action: 'JOIN_GROUP', - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }), publishFee: fee.fee + ' QORT', }); @@ -131,7 +131,7 @@ export const AddGroupList = ({ setInfoSnack, setOpenSnack }) => { setInfoSnack({ type: 'success', message: t('group:message.success.join_group', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }), }); @@ -142,11 +142,11 @@ export const AddGroupList = ({ setInfoSnack, setOpenSnack }) => { type: 'joined-group', label: t('group:message.success.group_join_label', { group_name: group?.groupName, - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }), labelDone: t('group:message.success.group_join_label', { group_name: group?.groupName, - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }), done: false, groupId, @@ -160,11 +160,11 @@ export const AddGroupList = ({ setInfoSnack, setOpenSnack }) => { type: 'joined-group-request', label: t('group:message.success.group_join_request', { group_name: group?.groupName, - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }), labelDone: t('group:message.success.group_join_outcome', { group_name: group?.groupName, - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }), done: false, groupId, @@ -243,7 +243,7 @@ export const AddGroupList = ({ setInfoSnack, setOpenSnack }) => { }} > - {t('core:action.join', { postProcess: 'capitalize' })}{' '} + {t('core:action.join', { postProcess: 'capitalizeFirst' })}{' '} {group?.groupName} @@ -257,7 +257,7 @@ export const AddGroupList = ({ setInfoSnack, setOpenSnack }) => { onClick={() => handleJoinGroup(group, group?.isOpen)} > {t('group:action.join_group', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} diff --git a/src/components/Group/Forum/GroupMail.tsx b/src/components/Group/Forum/GroupMail.tsx index 41f75ef..c1718a5 100644 --- a/src/components/Group/Forum/GroupMail.tsx +++ b/src/components/Group/Forum/GroupMail.tsx @@ -170,7 +170,9 @@ export const GroupMail = ({ .catch((error) => { rej( error.message || - t('core:message.error.generic', { postProcess: 'capitalize' }) + t('core:message.error.generic', { + postProcess: 'capitalizeFirst', + }) ); }); }); @@ -754,7 +756,7 @@ export const GroupMail = ({ {t('group:last_message', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} :{' '} @@ -791,7 +793,7 @@ export const GroupMail = ({ }} > {t('core:page.last', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} diff --git a/src/components/Group/Forum/NewThread.tsx b/src/components/Group/Forum/NewThread.tsx index 0212702..4a561f5 100644 --- a/src/components/Group/Forum/NewThread.tsx +++ b/src/components/Group/Forum/NewThread.tsx @@ -183,19 +183,19 @@ export const NewThread = ({ if (!isMessage && !threadTitle) { errorMsg = t('group:question.provide_thread', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }); } if (!name) { errorMsg = t('group:message.error.access_name', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }); } if (!groupInfo) { errorMsg = t('group:message.error.group_info', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }); } @@ -204,7 +204,7 @@ export const NewThread = ({ const missingFieldsString = missingFields.join(', '); const errMsg = t('core:message.error.missing_fields', { field: missingFieldsString, - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }); errorMsg = errMsg; } @@ -217,7 +217,7 @@ export const NewThread = ({ if (!htmlContent?.trim() || htmlContent?.trim() === '

') { const errMsg = t('group:message.generic.provide_message', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }); throw new Error(errMsg); } @@ -231,7 +231,7 @@ export const NewThread = ({ await show({ message: t('group:question.perform_transaction', { action: 'ARBITRARY', - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }), publishFee: feeToShow + ' QORT', }); @@ -257,7 +257,7 @@ export const NewThread = ({ isPrivate === false ? null : await getSecretKey(false, true); if (!secretKey && isPrivate) { const errMsg = t('group:message.error.group_secret_key', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }); throw new Error(errMsg); } @@ -320,7 +320,7 @@ export const NewThread = ({ setInfoSnack({ type: 'success', message: t('group:message.success.thread_creation', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }), }); setOpenSnack(true); @@ -332,7 +332,7 @@ export const NewThread = ({ } else { if (!currentThread) { const errMsg = t('group:message.error.thread_id', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }); throw new Error(errMsg); } @@ -360,7 +360,7 @@ export const NewThread = ({ setInfoSnack({ type: 'success', message: t('group:message.success.post_creation', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }), }); setOpenSnack(true); @@ -404,10 +404,10 @@ export const NewThread = ({ {currentThread ? t('core:action.new.post', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }) : t('core:action.new.thread', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -437,10 +437,10 @@ export const NewThread = ({ {isMessage ? t('core:action.post_message', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }) : t('core:action.new.thread', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -562,10 +562,10 @@ export const NewThread = ({ {isMessage ? t('core:action.post', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }) : t('core:action.create_thread', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} diff --git a/src/components/Group/Forum/Thread.tsx b/src/components/Group/Forum/Thread.tsx index a6c2d0f..447200e 100644 --- a/src/components/Group/Forum/Thread.tsx +++ b/src/components/Group/Forum/Thread.tsx @@ -609,7 +609,7 @@ export const Thread = ({ {t('group:action.return_to_thread', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -688,7 +688,7 @@ export const Thread = ({ disabled={!hasFirstPage} variant="contained" > - {t('core:page.first', { postProcess: 'capitalize' })} + {t('core:page.first', { postProcess: 'capitalizeFirst' })} @@ -929,7 +929,9 @@ export const Thread = ({ fontSize: '18px', }} > - {t('core:downloading_qdn', { postProcess: 'capitalize' })} + {t('core:downloading_qdn', { + postProcess: 'capitalizeFirst', + })} @@ -961,7 +963,7 @@ export const Thread = ({ }} > {t('group:action.refetch_page', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -1000,7 +1002,7 @@ export const Thread = ({ disabled={!hasFirstPage} variant="contained" > - {t('core:page.first', { postProcess: 'capitalize' })} + {t('core:page.first', { postProcess: 'capitalizeFirst' })} @@ -1071,7 +1073,7 @@ export const Thread = ({ diff --git a/src/components/Group/Group.tsx b/src/components/Group/Group.tsx index a7e330d..b524697 100644 --- a/src/components/Group/Group.tsx +++ b/src/components/Group/Group.tsx @@ -514,7 +514,9 @@ export const Group = ({ .catch((error) => { rej( error.message || - t('core:message.error.generic', { postProcess: 'capitalize' }) + t('core:message.error.generic', { + postProcess: 'capitalizeFirst', + }) ); }); }); @@ -543,7 +545,9 @@ export const Group = ({ .catch((error) => { rej( error.message || - t('core:message.error.generic', { postProcess: 'capitalize' }) + t('core:message.error.generic', { + postProcess: 'capitalizeFirst', + }) ); }); }); @@ -575,7 +579,9 @@ export const Group = ({ .catch((error) => { rej( error.message || - t('core:message.error.generic', { postProcess: 'capitalize' }) + t('core:message.error.generic', { + postProcess: 'capitalizeFirst', + }) ); }); }); @@ -1098,7 +1104,9 @@ export const Group = ({ .catch((error) => { rej( error.message || - t('core:message.error.generic', { postProcess: 'capitalize' }) + t('core:message.error.generic', { + postProcess: 'capitalizeFirst', + }) ); }); }); @@ -1995,7 +2003,7 @@ export const Group = ({ }} > {t('group:message.generic.no_selection', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -2094,7 +2102,7 @@ export const Group = ({ {' '} {t('group:message.generic.encryption_key', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -2120,21 +2128,21 @@ export const Group = ({ {' '} {t('group:message.generic.not_part_group', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} {t('group:message.generic.only_encrypted', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} {t('group:message.generic.notify_admins', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -2156,7 +2164,7 @@ export const Group = ({ onClick={() => notifyAdmin(admin)} > {t('core:action.notify', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -2381,7 +2389,7 @@ export const Group = ({ message: isLoadingGroupMessage || t('group:message.generic.setting_group', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }), }} /> @@ -2390,7 +2398,7 @@ export const Group = ({ open={isLoadingGroups} info={{ message: t('group:message.generic.setting_group', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }), }} /> diff --git a/src/components/Group/GroupInvites.tsx b/src/components/Group/GroupInvites.tsx index ca3f32c..f3da8a0 100644 --- a/src/components/Group/GroupInvites.tsx +++ b/src/components/Group/GroupInvites.tsx @@ -71,7 +71,7 @@ export const GroupInvites = ({ myAddress, setOpenAddGroup }) => { fontSize: '1rem', }} > - {t('group:group.invites', { postProcess: 'capitalize' })}{' '} + {t('group:group.invites', { postProcess: 'capitalizeFirst' })}{' '} {groupsWithJoinRequests?.length > 0 && ` (${groupsWithJoinRequests?.length})`} @@ -131,7 +131,7 @@ export const GroupInvites = ({ myAddress, setOpenAddGroup }) => { }} > {t('group:message.generic.no_display', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} @@ -181,7 +181,7 @@ export const GroupInvites = ({ myAddress, setOpenAddGroup }) => { }} primary={t('group:message.generic.group_invited_you', { group: group?.groupName, - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} /> diff --git a/src/components/Group/GroupJoinRequests.tsx b/src/components/Group/GroupJoinRequests.tsx index 15304f5..0991edb 100644 --- a/src/components/Group/GroupJoinRequests.tsx +++ b/src/components/Group/GroupJoinRequests.tsx @@ -144,7 +144,7 @@ export const GroupJoinRequests = ({ fontSize: '1rem', }} > - {t('group:join_requests', { postProcess: 'capitalize' })}{' '} + {t('group:join_requests', { postProcess: 'capitalizeFirst' })}{' '} {filteredJoinRequests?.filter((group) => group?.data?.length > 0) ?.length > 0 && ` (${filteredJoinRequests?.filter((group) => group?.data?.length > 0)?.length})`} @@ -207,7 +207,7 @@ export const GroupJoinRequests = ({ }} > {t('group:message.generic.no_display', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', })} diff --git a/src/components/Group/HomeDesktop.tsx b/src/components/Group/HomeDesktop.tsx index 83f8828..c270df0 100644 --- a/src/components/Group/HomeDesktop.tsx +++ b/src/components/Group/HomeDesktop.tsx @@ -85,7 +85,7 @@ export const HomeDesktop = ({ padding: '10px', }} > - {t('core:welcome', { postProcess: 'capitalize' })} + {t('core:welcome', { postProcess: 'capitalizeFirst' })} {userInfo?.name ? ( - {t('tutorial:initial.explore', { postProcess: 'capitalize' })} + {t('tutorial:initial.explore', { + postProcess: 'capitalizeFirst', + })} {' '} diff --git a/src/components/Group/InviteMember.tsx b/src/components/Group/InviteMember.tsx index 24ff960..94414ba 100644 --- a/src/components/Group/InviteMember.tsx +++ b/src/components/Group/InviteMember.tsx @@ -19,7 +19,7 @@ export const InviteMember = ({ groupId, setInfoSnack, setOpenSnack, show }) => { await show({ message: t('group:question.perform_transaction', { action: 'GROUP_INVITE', - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }), publishFee: fee.fee + ' QORT', }); @@ -40,7 +40,7 @@ export const InviteMember = ({ groupId, setInfoSnack, setOpenSnack, show }) => { type: 'success', message: t('group:message.success.group_invite', { value: value, - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }), }); setOpenSnack(true); @@ -61,7 +61,7 @@ export const InviteMember = ({ groupId, setInfoSnack, setOpenSnack, show }) => { message: error?.message || t('core:message.error.generic', { - postProcess: 'capitalize', + postProcess: 'capitalizeFirst', }), }); setOpenSnack(true); @@ -86,7 +86,7 @@ export const InviteMember = ({ groupId, setInfoSnack, setOpenSnack, show }) => { flexDirection: 'column', }} > - {t('group:action.invite_member', { postProcess: 'capitalize' })} + {t('group:action.invite_member', { postProcess: 'capitalizeFirst' })} @@ -99,14 +99,14 @@ export const InviteMember = ({ groupId, setInfoSnack, setOpenSnack, show }) => {