mirror of
https://github.com/vitorpamplona/amethyst.git
synced 2026-08-10 00:16:59 +00:00
Some sources (e.g. the math-academy posts) over-escape their LaTeX, so the content carries `\\ldots` / `\\cdots` instead of `\ldots` / `\cdots`. JLaTeXMath reads the `\\` as a forced TeX line break — splitting every inline equation across two lines — and renders the trailing command name as the literal letters "ldots"/"cdots", so the ellipsis symbol is lost. Collapse doubled backslashes (`\\cmd` -> `\cmd`) before rendering inline math; display math is left untouched since `\\` can be a genuine line break there. No-op when the content isn't over-escaped.