Thank you @nthmost for your useful feedback and follow-up. I appreciate it. I will give it a try.
I managed to get something similar working, but I noticed that the text direction gets distorted if there are 2 new lines (\n) in the text. Not sure why though. I will try your tip and see.
As you said, Arabic and its bidirectionality is not easy, and without HTML support, it will be extermely difficult. I am happy to see that it’s now on Steamlit’s road map. So, I hope it will be available soon.
RTL native support doesn’t only include text direction. For example, the whole layout should be a mirrored version of English. So, for example, the left side panel should be on the right. Checkboxes, SelectBoxes, bullets, etc. should also be on the right side, not on the left side.
A native RTL support in Streamlit would be great indeed to support languages such as Arabic, Farsi, Urdu, and Hebrew.