Repository navigation
Description
Problem
GitHub alert blockquotes (> [!NOTE], > [!TIP], > [!WARNING], …) lose their alert semantics on save in the id web editor: the marker is backslash-escaped, so every CommonMark/GitHub renderer afterwards shows a plain blockquote containing the literal text [!NOTE] instead of a rendered alert.
Evidence (verified this run on main 0cbb91b1)
Probe: verbatim copy of pkgs/id/src/web/markdown.rs in a standalone crate (comrak 0.56.0), markdown_to_prosemirror → prosemirror_to_markdown. Logs: fleet bookkeeping probe-2026-10-27-creator-a/out.log, out3.log, out4.log (raw-output capture).
Input:
> [!NOTE]
> Remember this.The parse direction has no alert concept — the marker becomes ordinary paragraph text !NOTE bracketed as [!NOTE] — and the save direction escapes it (raw bytes verified, not debug-escaped):
> \[!NOTE\] Remember this.Same result for [!WARNING] and [!TIP], single- and multi-line, and with following paragraphs (all in the probe logs). The visible text a reader sees after one save is the same words, but GitHub's alert rendering keys on the unescaped [!NOTE] marker at the start of the blockquote's first line — after the escape is written, the alert is gone for every future reader, and the literal backslashes are what a raw-markdown reader sees.
Root cause: commonmark_options (pkgs/id/src/web/markdown.rs:81-91) enables strikethrough/tasklist/table/footnotes but not comrak's alerts extension, and the codec has no blockquote-variant representation, so the marker is plain text and the CommonMark renderer escapes the ![ sequence exactly as it would for literal bracket text (compare the wikilink case in the same probe: [[Other Page]] is likewise escaped — correct for literal text, wrong for a construct the parser should have claimed).
Why it matters
Alerts are the standard callout syntax in GitHub READMEs and docs — exactly the files a markdown editor like id is used on. The damage is quiet: the words survive, so nobody notices the callout silently demoted to a plain quote (with stray backslashes in raw form) until the doc is viewed on GitHub. Preservation is the floor; rendering alerts distinctly in the editor is the stretch goal, not a requirement here.
Acceptance criteria
-
> [!NOTE]/[!TIP]/[!IMPORTANT]/[!WARNING]/[!CAUTION]blockquotes round-trip with the marker unescaped at the start of the first quoted line, and the saved form is a fixpoint. - The alert body (including multi-paragraph alerts) is preserved; a blockquote that merely starts with bracketed text that is not one of the five alert markers (e.g.
> [!NOTE] extra words on the marker lineper GitHub's rules, or> [see appendix]) round-trips as a plain blockquote without gaining or losing escapes beyond today's plain-text behaviour. - The representation decision (codec-level marker preservation vs a dedicated PM node + editor rendering) is noted in the PR; if a new PM node is introduced,
pkgs/id/web/src/editor.tsgains the matching schema entry so the doc stays valid in the editor. - Regression tests in
pkgs/id/src/web/markdown.rscover at least NOTE/WARNING round-trips and the non-alert bracket control.
Activity
developing-today commentedon Oct 27, 2026
CODE-471
dezren39 commentedon Oct 27, 2026
🤖 Agent note · filed
dezren39 commentedon Oct 31, 2026
🤖 Agent note · picked up
54 remaining items
dezren39 commentedon Nov 4, 2026
🤖 Agent note · handed off
opencode; handed off to the laptop opencode claimant, which launches the bound session that drives task 7925 to its terminal state.dezren39 commentedon Nov 4, 2026
🤖 Agent note · handed off
dezren39 commentedon Nov 4, 2026
🤖 Agent note · handed off
dezren39 commentedon Nov 4, 2026
🤖 Agent note · handed off
ses_e5e590d85e0ffeckZPUubs1Suudezren39 commentedon Nov 4, 2026
🤖 Agent note · done