You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Code blocks switch to RTL inside callouts (Engilsh, Arabic) and Arabic notes (unexpected bidi behavior) #94
Code blocks unexpectedly switch their text direction to RTL (right-to-left) in certain contexts, even when the code itself is entirely written in English. This causes incorrect rendering and reduces readability.
Steps to reproduce
Create a new note.
Set Obsidian UI language to English.
Add the following content:
>[!example] Basic Structure>```javascript>constmyPromise=newPromise((resolve, reject) => {>// Asynchronous operation>// If successful, call resolve with the result>// If there's an error, call reject with an error object>});>```
Switch to Reading View or Live Preview.
Alternative reproduction
Write the note content in Arabic.
Insert an English-only code block.
Observe the code direction.
Expected behavior
Code blocks should always render with:
Left-to-right (LTR) direction
Left-aligned text
in both Arabic or En in edetore or read mod
This should be independent of:
Callout usage
Note language
UI language
Actual behavior
Code blocks inherit RTL direction when placed inside callouts.
Code blocks also become RTL when the surrounding note content is Arabic in reading mode
Screenshots
callouts bug
reading mode bug
in editing
in readig mod
Note: this happned in both Arabic English without callouts
Environment
OS: Windows
App version: (fill in)
Installer: (exe / portable / store)
UI language: English
Editor: Live Preview (CM6)
Theme: Default (or specify)
CSS snippets enabled: Yes
Attempted workaround
[x] I tried forcing LTR direction via CSS snippet, withesuccess:
This issue appears to be related to direction inheritance and missing bidi isolation.
Code blocks should not inherit RTL layout from parent containers such as callouts or RTL paragraphs.
bolck of code and code alwyes should ltr without addetional config
Activity