How can we make this component to be compatible with RTL websites?
Few CSS customization can make this RTL compatible. I will work on it.
The component is not compatible with rtl websites. What should we do?
I tried it before. But it demanded more changes than I expected. It’s not in my current roadmap. pr-welcome.
I can submit a PR however I just don’t know how can I get the direction of discourse as a variable in theme component.
In RTL layout <html>
tag will include the CSS class rtl
. You can do the customization based on it. If needed you can also check it in JS code by calling const isRTL = $("html").hasClass("rtl");
.
Sorry I didn’t understand you correctly. I just need to add a variable in common.scss
file that indicates discourse global direction. I didn’t find such variable here:
If I have that variable in common.scss
the customization would be pretty straightforward. Otherwise I don’t know how to do it.
Yes, we don’t have a global CSS variable I guess. You should check rtl.scss file to understand howto customize.
I submitted a pr
It’s merged. Thanks for the PR .