TUI::Markdown::Parser
Hand-rolled line-oriented block parser: walks the source a line at a time with a cursor, dispatching on each line's leading shape into a flat Array(Block). No external Markdown shard is used (shard.yml has zero runtime dependencies) — this recognizes the subset of CommonMark/GFM documented as in-scope on MarkdownView.
Constants
ATX_HEADING = /^ {0,3}(\#{1,6})\s+(.*?)\s*\#*\s*$/
BLOCKQUOTE = /^ {0,3}(>+)\s?(.*)$/
FENCE_OPEN = /^ {0,3}(```|~~~)\s*(\S*)\s*$/
HRULE = /^ {0,3}([-*_])( *\1){2,} *$/
ORDERED_ITEM = /^( *)(\d+)[.)]\s+(.*)$/
TABLE_DELIM_CELL = /^:?-+:?$/
TABLE_ROW = /\|/
TASK_PREFIX = /^\[([ xX])\]\s+(.*)$/
UNORDERED_ITEM = /^( *)([-*+])\s+(.*)$/