From 8eb1bfa622f0ec8f046f38204f00b8923669f74e Mon Sep 17 00:00:00 2001 From: Jonas Smedegaard Date: Thu, 3 Apr 2025 11:50:29 +0200 Subject: fix track enclosure positions only within same inline --- _extensions/ruc-play/semantic-markdown/semantic-markdown.lua | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to '_extensions') diff --git a/_extensions/ruc-play/semantic-markdown/semantic-markdown.lua b/_extensions/ruc-play/semantic-markdown/semantic-markdown.lua index b54cf5b..7c76670 100644 --- a/_extensions/ruc-play/semantic-markdown/semantic-markdown.lua +++ b/_extensions/ruc-play/semantic-markdown/semantic-markdown.lua @@ -147,9 +147,6 @@ end --- @see function Statements (blocks) - -- positions of enclosure markers - local pos_bracket_begin, pos_brace_begin, pos_brace_end - -- positions of beginning of enclosed content -- usable as flags, since it is always preceded by a marker local pos_bracketed, pos_braced @@ -161,6 +158,9 @@ function Statements (blocks) for i, el in ipairs(blocks.content) do + -- enclosure marker positions within same inline + local pos_bracket_begin, pos_brace_begin, pos_brace_end + -- unenclosed, entering bracketed enclosure -- TODO: support nested bracket enclosure if el.t == 'Str' and not (pos_bracketed or pos_braced) then -- cgit v1.2.3