Render LaTeX equations with KaTeX in Content#2131
Conversation
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
|
Here's a visual recap of what changed: Open the full interactive recap |
There was a problem hiding this comment.
Builder reviewed your changes and found 3 potential issues 🟡
Review Details
Incremental Code Review Summary
The latest commit fixes both previously open findings: escaped delimiter parity is now handled, and indented display equations are retained inside list items. I resolved those two stale review threads before this review. The broader approach remains sound: KaTeX is shared across editor and export paths, SSR markup is emitted during render, and malformed expressions remain visible rather than being discarded.
New Findings
- 🟡 MEDIUM — Same-type nested bullet lists are still flattened because the collector treats any indented matching marker as a sibling.
- 🟡 MEDIUM — Inline code spans ending in a backslash no longer close correctly because code-fence detection applies Markdown escape parity inside code content.
- 🟡 MEDIUM — A malformed inline math opener can skip a backslash-adjacent closing delimiter and then consume a later code span, corrupting the remainder of the paragraph.
The change remains standard risk, centered on shared export parsing and user-facing document structure. The dev server is healthy. Full browser verification was attempted, but executor sessions still lacked browser navigation/DOM/screenshot tools; static/unit checks covered the main rendering paths but could not validate these live export edge cases.
🧪 Browser testing: Could not verify — browser automation tools were unavailable in the executor environment; all planned cases were environment-blocked.

Summary
Why
Content already parses inline$...$ and block $$ delimiters into structured NFM atoms, but those atoms were displayed as plain labels. This completes the presentation and export layers without changing the canonical source format or adding a second math grammar.
Validation
Notes
The local-file page actions menu does not expose HTML/PDF export, so export output is covered by focused integration tests rather than manual download QA.