this post was submitted on 03 Sep 2021
0 points (NaN% liked)
Asklemmy
43851 readers
1362 users here now
A loosely moderated place to ask open-ended questions
Search asklemmy π
If your post meets the following criteria, it's welcome here!
- Open-ended question
- Not offensive: at this point, we do not have the bandwidth to moderate overtly political discussions. Assume best intent and be excellent to each other.
- Not regarding using or support for Lemmy: context, see the list of support communities and tools for finding communities below
- Not ad nauseam inducing: please make sure it is a question that would be new to most members
- An actual topic of discussion
Looking for support?
Looking for a community?
- Lemmyverse: community search
- sub.rehab: maps old subreddits to fediverse options, marks official as such
- !lemmy411@lemmy.ca: a community for finding communities
~Icon~ ~by~ ~@Double_A@discuss.tchncs.de~
founded 5 years ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
view the rest of the comments
I do not speak an RTL language either, but from what I know of I can give you an idea of what it takes to support it properly.
The start would be to add
dir="rtl"
to thehtml
element and see what needs fixing: thankfully because you use flexbox in most places the layout naturally switches. The rest would be to use logical properties:text-align:start;
instead oftext-align:left
,padding-inline-start
instead ofpadding-left
β¦ Most of the CSS spatial properties have their logical sibling, even border-radius. If needed, you can also overwrite rules withhtml[dir="rtl"] {β¦}
Then, for user inputed text, each top level node (p, ul, ol, blockquote, h1β¦) should have the
dir="auto"
attribute, so it's possible to have text in two directions, depending on the first word of the element. Simply doing<textarea dir="auto">
isn't possible because then the first word decides of the text direction for the whole content. Supporting RTL fully also means supporting mixed directional text.If you wanted to take a look at lemmy-ui and add this, I'd be happy to help where I can.
Will do! I will start with switching
main.css
to logical properties, and then have a look at the themesβ¦Any update on the RTL?
see https://github.com/LemmyNet/lemmy-ui/issues/347