Skip to content

A11y | Expose MathML beside KaTeX - #69

Merged
BrianGenisio merged 2 commits into
mainfrom
fix/a11y-katex-mathml
Sep 2, 2026
Merged

A11y | Expose MathML beside KaTeX#69
BrianGenisio merged 2 commits into
mainfrom
fix/a11y-katex-mathml

Conversation

@BrianGenisio

@BrianGenisio BrianGenisio commented Sep 2, 2026

Copy link
Copy Markdown
Contributor

Summary

Closes #56. The KaTeX wrapper now asks auto-render for HTML plus MathML, then keeps the painted layer aria-hidden so AT can read the MathML sibling.

The docs commit records A14 as closed (PR #68) on the issue map. That number is not on the A19 row.

Changes

katex-render.js forces output: 'htmlAndMathml' and walks each .katex root: .katex-html stays aria-hidden="true", .katex-mathml is not hidden, and the outer .katex is not aria-hidden. No new visible copy.

A19 characterization locks that path.

Test plan

  • npm test — A19 characterization
  • /play fib-latex.md: 19 <math> nodes, none under aria-hidden; all 19 .katex-html are aria-hidden
  • /play matching-latex.md: 11 <math> nodes, same contract; formulas still look like KaTeX
  • PORT=3010 A11Y_BASE_URL=http://127.0.0.1:3010 SIM_PORT=8081 SIM_ORIGIN=http://127.0.0.1:8081 npm run a11y:ci — baseline stays color-contrast 1
  • VoiceOver / NVDA (needs-manual-verify)

Brian Genisio and others added 2 commits September 2, 2026 15:53
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
@coderabbitai

coderabbitai Bot commented Sep 2, 2026

Copy link
Copy Markdown

Warning

Review limit reached

Next included review available in 12 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used all 5 included reviews currently available. Your 24 included PR review attempts over the past 7 days set your current allowance at 5 reviews per hour.

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

Learn how review limits work.

Review configuration:

⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Essentials

Run ID: 879ea799-04a4-4e86-be90-82ceff717a60

📥 Commits

Reviewing files that changed from the base of the PR and between be7f812 and 10375d8.

📒 Files selected for processing (3)
  • a11y-audits/8-13-26/wave-4-plan.md
  • public/utils/katex-render.js
  • test/a11y-characterization.test.js

Comment @coderabbitai help to get the list of available commands.

@BrianGenisio
BrianGenisio merged commit 6297a81 into main Sep 2, 2026
3 checks passed
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.

[a11y][A19] KaTeX math has no accessible alternative

1 participant