📝 Issue Description
I don't speak Arabic, but while reviewing #12769 I noticed we might have a layout issue because we are mixing English and Arabic and the text doesn't seem to wrap correctly.
📋 On which page(s) it occurs
https://docs.astro.build/ar/guides/deploy/
🤔 Expected Behavior
I assumed this may be due to the use of lang="en" dir="ltr" on main, as this is a fallback page... So, I added dir="rtl" to CardsNav (in the browser, using the PR Preview):

Now, the layout seems correct for an RTL reader, but I don't know if this fixes everything. I would expect "SSR" to be at the end but I don't speak Arabic so maybe this is how it works.
I tried to update a CodePen example from RTL Styling 101 using the same string and "SSR" is at the same position. So, this is probably fine!
👀 Current Behavior
Here's a table comparing our Deploy guides overview in Arabic between the live website and the PR preview, using different window sizes:
|
Desktop width |
Resized |
| Live |
 |
 |
| PR Preview |
 |
 |
As reference, the "On demand" tag is translated with SSR التصيير على الخادم in Arabic. The words order seems wrong in the screenshots when the text wraps.
🖥️ Browser
Firefox v145.0.1, Chromium v142.0.7444.175
📄 Additional Information
A solution could be to conditionally add dir="rtl" to CardsNav by checking if this is a fallback page (isFallback()) and if Astro.currentLocale is an RTL language?
I think this issue only occurs in the Deploy Guides overview but maybe a similar issue exists elsewhere? If so, it might be worth checking every components that uses translated UI strings.
I didn't sent a fix because a confirmation from someone speaking Arabic (or at least familiar with RTL styling) could be useful, and this could be a good first issue.
📝 Issue Description
I don't speak Arabic, but while reviewing #12769 I noticed we might have a layout issue because we are mixing English and Arabic and the text doesn't seem to wrap correctly.
📋 On which page(s) it occurs
https://docs.astro.build/ar/guides/deploy/
🤔 Expected Behavior
I assumed this may be due to the use of
lang="en" dir="ltr"onmain, as this is a fallback page... So, I addeddir="rtl"toCardsNav(in the browser, using the PR Preview):Now, the layout seems correct for an RTL reader, but I don't know if this fixes everything. I would expect "SSR" to be at the end but I don't speak Arabic so maybe this is how it works.
I tried to update a CodePen example from RTL Styling 101 using the same string and "SSR" is at the same position. So, this is probably fine!
👀 Current Behavior
Here's a table comparing our Deploy guides overview in Arabic between the live website and the PR preview, using different window sizes:
As reference, the "On demand" tag is translated with
SSR التصيير على الخادمin Arabic. The words order seems wrong in the screenshots when the text wraps.🖥️ Browser
Firefox v145.0.1, Chromium v142.0.7444.175
📄 Additional Information
A solution could be to conditionally add
dir="rtl"toCardsNavby checking if this is a fallback page (isFallback()) and ifAstro.currentLocaleis an RTL language?I think this issue only occurs in the Deploy Guides overview but maybe a similar issue exists elsewhere? If so, it might be worth checking every components that uses translated UI strings.
I didn't sent a fix because a confirmation from someone speaking Arabic (or at least familiar with RTL styling) could be useful, and this could be a good first issue.