Skip to content

feat: Upgrade to comrak 0.54 with math_latex + alert_style options, and changed header_ids#472

Merged
gjtorikian merged 2 commits into
mainfrom
comrak-54
Jul 13, 2026
Merged

feat: Upgrade to comrak 0.54 with math_latex + alert_style options, and changed header_ids#472
gjtorikian merged 2 commits into
mainfrom
comrak-54

Conversation

@gjtorikian

@gjtorikian gjtorikian commented Jul 12, 2026

Copy link
Copy Markdown
Owner

Summary

  • Bumps comrak from 0.53 to 0.54, picking up upstream fixes for CommonMark roundtripping with whitespace entities and a crash with ordered lists nested in blockquotes.
  • Exposes the new math_latex extension option: \(...\) and \[...\] delimiters render as inline/display math spans.
  • Exposes the new alert_style render option: "semantic" outputs <aside class="admonition"> (matching docutils) instead of the default markdown-alert divs.
  • ⚠️ Heading anchor markup changed upstream: the id now lives on the heading element and the anchor moved to the end with aria-label + data-heading-content, replacing the leading aria-hidden link. CSS/JS targeting the old markup will be affected — this warrants a minor version bump (2.9.0) and a prominent changelog entry.

Comrak 0.54 changes heading anchor markup: the id now lives on
the heading element and the anchor moves to the end with an
aria-label instead of a leading aria-hidden link. That output
change is user-visible, so the affected tests are updated to
match. Also picks up upstream fixes for CommonMark roundtripping
and a crash with ordered lists nested in blockquotes.
Comrak 0.54 adds LaTeX-style math delimiters and semantic
alert rendering (<aside class="admonition">, matching
docutils). Exposing them keeps the gem's option surface
in step with upstream.
@gjtorikian gjtorikian changed the title feat: Upgrade to comrak 0.54 with math_latex and alert_style options feat: Upgrade to comrak 0.54 with math_latex + alert_style options, and changed header_ids Jul 12, 2026
@kivikakk

Copy link
Copy Markdown
Collaborator

All LGTM!

@gjtorikian
gjtorikian merged commit 027aa7a into main Jul 13, 2026
6 of 9 checks passed
@gjtorikian
gjtorikian deleted the comrak-54 branch July 13, 2026 19:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants