Hi,
I’m the developer of the Obsidian RTL plugin, and been struggling for a while with an exception that seems to be thrown by the Obsidian code, but somehow (I don’t understand why) my plugin clearly causes.
The issue is described in details here. TLDR: in a Markdown table that includes very long cells (that spawn more than the viewport), the editor extension of the RTL plugin, which add a fine-grained dir
attribute to every editor line, causes other tables in the document to be non-functional (putting the cursor on them throws an exception).
A note about the RTL plugin: unlike the Obsidian native RTL support, the RTL plugin can set direction on a by-note basis to either LTR, RTL or auto (which is now the Obsidian default). In Live Preview it does so using an editor extension that adds dir
attributes to elements.
As part of the attempts to solve the issue, I tried changing how the decorations are added in the extension, from being lined to ranged, and with various ways to cut through the viewport. Nothing helped.
Due to the nature of the problem, a minimal reproducible example is longer than this forum allows in a message, so I attached it as a file. With a note that contains the text, and the RTL plugin enabled, it’s easy to cause an exception thrown simply by moving the cursor to the second (empty) table in the document.
Any help or tip in how to tackle the issue would be greatly appreciated!
202407301824 - RTL Bug Test.md (50.4 KB)