Add RTL document direction detection#1320
Conversation
|
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment Tip You can disable the changed files summary in the walkthrough.Disable the |
Summary
document.documentElement.dirtortlat app startupTesting
Note
Add RTL document direction detection based on browser locale
In main.tsx, sets
document.documentElement.dirto"rtl"or"ltr"at startup based on the user's browser language. The detected locale is derived fromnavigator.languages(first non-empty entry) with a fallback tonavigator.language, and is matched against a regex covering ar, dv, fa, he, ku, ps, sd, ug, ur, and yi.Macroscope summarized 4c042dc.