alternative word translations implementation idea

just for demonstration!
This commit is contained in:
pswid
2022-10-18 13:47:10 +02:00
parent 49414adfd2
commit bb98f13b19
3 changed files with 4 additions and 4 deletions

View File

@@ -124,7 +124,7 @@ const SystemStatusForm: FC = () => {
const renderVersionDialog = () => {
return (
<Dialog open={showingVersion} onClose={() => setShowingVersion(false)}>
<DialogTitle>{LL.VERSION_CHECK()}</DialogTitle>
<DialogTitle>{LL.VERSION_CHECK(1)}</DialogTitle>
<DialogContent dividers>
<MessageBox my={0} level="info" message={LL.SYSTEM_VERSION_RUNNING() + ' ' + data?.emsesp_version} />
{latestVersion && (
@@ -232,7 +232,7 @@ const SystemStatusForm: FC = () => {
<ListItemText primary="EMS-ESP Version" secondary={'v' + data.emsesp_version} />
{latestVersion && (
<Button color="primary" onClick={() => setShowingVersion(true)}>
{LL.VERSION_CHECK()}
{LL.VERSION_CHECK(0)}
</Button>
)}
</ListItem>

View File

@@ -1729,7 +1729,7 @@ export type TranslationFunctions = {
/**
* Version Check
*/
VERSION_CHECK: () => LocalizedString
VERSION_CHECK: (arg0: string | number | boolean) => LocalizedString
/**
* The latest
*/

View File

@@ -173,7 +173,7 @@ const pl: BaseTranslation = {
FACTORY_RESET: 'Ustawienia fabryczne',
SYSTEM_FACTORY_TEXT: 'Interfejs EMS-ESP został przywrócony do ustawień fabrycznych i zostanie teraz ponownie uruchomiony.',
SYSTEM_FACTORY_TEXT_DIALOG: 'Czy jesteś pewien, że chcesz przywrócić ustawienia fabryczne interfejsu EMS-ESP? ',
VERSION_CHECK: 'Wersje firmware\'u',
VERSION_CHECK: '{{Sprawdź wersję (main translation idx=0)|Sprawdzanie wersji (alt translation idx=1)|not used (translation idx=other)}}',
THE_LATEST: 'Najnowsza',
OFFICIAL: 'oficjalna',
DEVELOPMENT: 'testowa',