Skip to content

Record your screen, ship a demo. Free and open-source, GPU-accelerated, no watermarks, no subscriptions. Windows, macOS, Linux. Actively maintained.

i18n: Fixed language sorting and added italian to config and test

Luca Fontanot7319ec2db65d
diff --git a/src/i18n/__tests__/tutorialHelpTranslations.test.ts b/src/i18n/__tests__/tutorialHelpTranslations.test.ts
index b02957072..5d06b7902 100644
--- a/src/i18n/__tests__/tutorialHelpTranslations.test.ts
+++ b/src/i18n/__tests__/tutorialHelpTranslations.test.ts
@@ -4,6 +4,7 @@ import arDialogs from "@/i18n/locales/ar/dialogs.json";
import enDialogs from "@/i18n/locales/en/dialogs.json";
import esDialogs from "@/i18n/locales/es/dialogs.json";
import frDialogs from "@/i18n/locales/fr/dialogs.json";
+import itDialogs from "@/i18n/locales/it/dialogs.json";
import jaJPDialogs from "@/i18n/locales/ja-JP/dialogs.json";
import koKRDialogs from "@/i18n/locales/ko-KR/dialogs.json";
import ruDialogs from "@/i18n/locales/ru/dialogs.json";
@@ -39,16 +40,17 @@ const keysThatMayBeEmpty = new Set<(typeof tutorialHelpKeys)[number]>(["step1Des
const dialogsByLocale = {
en: enDialogs,
- "zh-CN": zhCNDialogs,
- "zh-TW": zhTWDialogs,
+ ar: arDialogs,
es: esDialogs,
fr: frDialogs,
- tr: trDialogs,
+ it: itDialogs,
+ "ja-JP": jaJPDialogs,
"ko-KR": koKRDialogs,
ru: ruDialogs,
- "ja-JP": jaJPDialogs,
- ar: arDialogs,
+ tr: trDialogs,
vi: viDialogs,
+ "zh-CN": zhCNDialogs,
+ "zh-TW": zhTWDialogs,
} satisfies Record<Locale, { tutorial: Record<string, unknown> }>;
describe("TutorialHelp translations", () => {
diff --git a/src/i18n/config.ts b/src/i18n/config.ts
index 70dd67776..fb885eb40 100644
--- a/src/i18n/config.ts
+++ b/src/i18n/config.ts
@@ -1,16 +1,17 @@
export const DEFAULT_LOCALE = "en" as const;
export const SUPPORTED_LOCALES = [
"en",
- "zh-CN",
- "zh-TW",
+ "ar",
"es",
"fr",
- "tr",
- "ko-KR",
+ "it",
"ja-JP",
- "ar",
+ "ko-KR",
"ru",
+ "tr",
"vi",
+ "zh-CN",
+ "zh-TW",
] as const;
export const I18N_NAMESPACES = [
"common",