feat: RTL Support for RTL Languages (Hebrew, Arabic) #2832
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What type of PR is this?
(REQUIRED)
What this PR does / why we need it:
(REQUIRED)
Some languages (such as Hebrew) are read right to left. This has a bunch of formatting considerations as well (text should be right aligned, etc.). Currently, while we have translations for these languages, we don't change the formatting.
Thankfully, Vuetify supports this pretty simply with a
rtl
boolean property (which is False by default). This PR adds some metadata to our locales to include the text direction (and setsrtl
totrue
if the direction isrtl
). I've also updated the codegen to preserve this.Which issue(s) this PR fixes:
(REQUIRED)
Fixes #2452
Tentatively fixes #2469, I'll close this with a note to re-open if not fixed
Special notes for your reviewer:
(fill-in or delete this section)
@hay-kot, if possible, can you confirm the codegen works? I can't really test it without the Crowdin API Key. I'm pretty confident it works, though.
Interestingly, it reverses a lot of the layout too (which I guess makes sense for RTL readers). This breaks a few things, but nothing major. We'll want to iron some of these out at some point.
Testing
(fill-in or delete this section)
Poked around the frontend switching between LTR and RTL langs.