diff --git a/frontend/src/i18n/index.ts b/frontend/src/i18n/index.ts index 703a9940f..d7dae0060 100644 --- a/frontend/src/i18n/index.ts +++ b/frontend/src/i18n/index.ts @@ -30,6 +30,7 @@ export const SUPPORTED_LOCALES = { 'ja-JP': '日本語', 'hu-HU': 'Magyar', 'ar-SA': 'اَلْعَرَبِيَّةُ', + 'fa-IR': 'فارسی', 'sl-SI': 'Slovenščina', 'pt-BR': 'Português Brasileiro', 'hr-HR': 'Hrvatski', @@ -52,7 +53,7 @@ export const DEFAULT_LANGUAGE: SupportedLocale= 'en' export type ISOLanguage = string -const RTL_LANGUAGES = ['ar-SA', 'he-IL'] as const +const RTL_LANGUAGES = ['ar-SA', 'he-IL', 'fa-IR'] as const export function isRTLLanguage(locale: SupportedLocale): boolean { return RTL_LANGUAGES.includes(locale as typeof RTL_LANGUAGES[number]) diff --git a/frontend/src/i18n/useDayjsLanguageSync.ts b/frontend/src/i18n/useDayjsLanguageSync.ts index 21e3fd7d6..792a284cd 100644 --- a/frontend/src/i18n/useDayjsLanguageSync.ts +++ b/frontend/src/i18n/useDayjsLanguageSync.ts @@ -22,6 +22,7 @@ export const DAYJS_LOCALE_MAPPING = { 'ja-jp': 'ja', 'hu-hu': 'hu', 'ar-sa': 'ar-sa', + 'fa-ir': 'fa', 'sl-si': 'sl', 'pt-br': 'pt', 'hr-hr': 'hr', @@ -55,6 +56,7 @@ export const DAYJS_LANGUAGE_IMPORTS = { 'ja-jp': () => import('dayjs/locale/ja'), 'hu-hu': () => import('dayjs/locale/hu'), 'ar-sa': () => import('dayjs/locale/ar-sa'), + 'fa-ir': () => import('dayjs/locale/fa'), 'sl-si': () => import('dayjs/locale/sl'), 'pt-br': () => import('dayjs/locale/pt-br'), 'hr-hr': () => import('dayjs/locale/hr'),