From 4a48ce55d154a52e0ba9adc4c97f8fc527e18dbb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kalle=20Kytt=C3=A4l=C3=A4?= Date: Wed, 9 Oct 2024 08:42:16 +0300 Subject: [PATCH] fix term family translation --- terminology-ui/public/locales/en/common.json | 2 +- terminology-ui/public/locales/fi/common.json | 2 +- terminology-ui/public/locales/sv/common.json | 2 +- terminology-ui/src/common/utils/translation-helpers.ts | 4 ++-- .../edit-concept/concept-terms-block/new-term-modal.tsx | 4 ++-- .../modules/edit-concept/concept-terms-block/term-form.tsx | 4 ++-- .../src/modules/edit-concept/generate-concept.test.tsx | 4 ++-- .../edit-concept/generate-form-data-test-variables.tsx | 4 ++-- 8 files changed, 13 insertions(+), 13 deletions(-) diff --git a/terminology-ui/public/locales/en/common.json b/terminology-ui/public/locales/en/common.json index 0482b816f..d2f16e449 100644 --- a/terminology-ui/public/locales/en/common.json +++ b/terminology-ui/public/locales/en/common.json @@ -163,7 +163,7 @@ "term-family": { "feminine": "feminine", "masculine": "masculine", - "neutral": "neutral" + "neuter": "neuter" }, "term-style": { "spoken-form": "spoken form" diff --git a/terminology-ui/public/locales/fi/common.json b/terminology-ui/public/locales/fi/common.json index f8fb6823c..76d4fe35b 100644 --- a/terminology-ui/public/locales/fi/common.json +++ b/terminology-ui/public/locales/fi/common.json @@ -163,7 +163,7 @@ "term-family": { "feminine": "feminiini", "masculine": "maskuliini", - "neutral": "neutri" + "neuter": "neutri" }, "term-style": { "spoken-form": "puhekieli" diff --git a/terminology-ui/public/locales/sv/common.json b/terminology-ui/public/locales/sv/common.json index 2cb5c4872..bc8d94754 100644 --- a/terminology-ui/public/locales/sv/common.json +++ b/terminology-ui/public/locales/sv/common.json @@ -163,7 +163,7 @@ "term-family": { "feminine": "femininum", "masculine": "maskulinum", - "neutral": "neutrum" + "neuter": "neutrum" }, "term-style": { "spoken-form": "talspråk" diff --git a/terminology-ui/src/common/utils/translation-helpers.ts b/terminology-ui/src/common/utils/translation-helpers.ts index be3fc0113..5b31e5def 100644 --- a/terminology-ui/src/common/utils/translation-helpers.ts +++ b/terminology-ui/src/common/utils/translation-helpers.ts @@ -85,8 +85,8 @@ export function translateTermFamily(termFamily: string, t: TFunction) { switch (termFamily) { case 'MASCULINE': return t('term-family.masculine', { ns: 'common' }); - case 'NEUTRAL': - return t('term-family.neutral', { ns: 'common' }); + case 'NEUTER': + return t('term-family.neuter', { ns: 'common' }); case 'FEMININE': return t('term-family.feminine', { ns: 'common' }); default: diff --git a/terminology-ui/src/modules/edit-concept/concept-terms-block/new-term-modal.tsx b/terminology-ui/src/modules/edit-concept/concept-terms-block/new-term-modal.tsx index ae1394708..61970413e 100644 --- a/terminology-ui/src/modules/edit-concept/concept-terms-block/new-term-modal.tsx +++ b/terminology-ui/src/modules/edit-concept/concept-terms-block/new-term-modal.tsx @@ -374,8 +374,8 @@ export default function NewTermModal({ uniqueItemId: 'masculine', }, { - labelText: t('term-family.neutral', { ns: 'common' }), - uniqueItemId: 'neutral', + labelText: t('term-family.neuter', { ns: 'common' }), + uniqueItemId: 'neuter', }, { labelText: t('term-family.feminine', { ns: 'common' }), diff --git a/terminology-ui/src/modules/edit-concept/concept-terms-block/term-form.tsx b/terminology-ui/src/modules/edit-concept/concept-terms-block/term-form.tsx index 1f9c226b3..c3416e28a 100644 --- a/terminology-ui/src/modules/edit-concept/concept-terms-block/term-form.tsx +++ b/terminology-ui/src/modules/edit-concept/concept-terms-block/term-form.tsx @@ -73,8 +73,8 @@ export default function TermForm({ uniqueItemId: 'MASCULINE', }, { - labelText: t('term-family.neutral', { ns: 'common' }), - uniqueItemId: 'NEUTRAL', + labelText: t('term-family.neuter', { ns: 'common' }), + uniqueItemId: 'NEUTER', }, { labelText: t('term-family.feminine', { ns: 'common' }), diff --git a/terminology-ui/src/modules/edit-concept/generate-concept.test.tsx b/terminology-ui/src/modules/edit-concept/generate-concept.test.tsx index ba91287ed..e13b1af3c 100644 --- a/terminology-ui/src/modules/edit-concept/generate-concept.test.tsx +++ b/terminology-ui/src/modules/edit-concept/generate-concept.test.tsx @@ -34,7 +34,7 @@ const input = { status: 'DRAFT', termConjugation: 'SINGULAR', termEquivalency: 'BROADER', - termFamily: 'NEUTRAL', + termFamily: 'NEUTER', termHomographNumber: '2', termInfo: 'info', termStyle: 'term style', @@ -147,7 +147,7 @@ const expected = { historyNote: 'term history', changeNote: 'term change', termStyle: 'term style', - termFamily: 'NEUTRAL', + termFamily: 'NEUTER', termConjugation: 'SINGULAR', termEquivalency: 'BROADER', wordClass: 'ADJECTIVE', diff --git a/terminology-ui/src/modules/edit-concept/generate-form-data-test-variables.tsx b/terminology-ui/src/modules/edit-concept/generate-form-data-test-variables.tsx index c26821c43..48c3ff2a3 100644 --- a/terminology-ui/src/modules/edit-concept/generate-form-data-test-variables.tsx +++ b/terminology-ui/src/modules/edit-concept/generate-form-data-test-variables.tsx @@ -101,7 +101,7 @@ export const initialDataReturned = generateFormData( status: 'DRAFT', termConjugation: 'SINGULAR', termEquivalency: 'BROADER', - termFamily: 'NEUTRAL', + termFamily: 'NEUTER', homographNumber: 2, termInfo: 'info', termStyle: 'style', @@ -156,7 +156,7 @@ export const initialDataExpected = { status: 'DRAFT', termConjugation: 'SINGULAR', termEquivalency: 'BROADER', - termFamily: 'NEUTRAL', + termFamily: 'NEUTER', termHomographNumber: '2', termInfo: 'info', termStyle: 'style',