fix: enforce LTR layout across the application regardless of language
CI/CD / test-and-build (push) Waiting to run
CI/CD / deploy (push) Blocked by required conditions

This commit is contained in:
Najjar\NajjarV02
2026-05-22 09:39:44 +04:00
parent 4c415cd5ea
commit e8f3bf8686
3 changed files with 10 additions and 9 deletions
+3 -3
View File
@@ -9,9 +9,9 @@ export function LanguageSwitcher() {
const toggleLanguage = useCallback(() => {
const newLang = i18n.language === 'en' ? 'ar' : 'en';
i18n.changeLanguage(newLang);
// Update document direction for RTL support
document.documentElement.dir = newLang === 'ar' ? 'rtl' : 'ltr';
// Force LTR layout regardless of language
document.documentElement.dir = 'ltr';
document.documentElement.lang = newLang;
}, [i18n]);