marp-core icon indicating copy to clipboard operation
marp-core copied to clipboard

Mathjax contextual menu and accessibility

Open mcmahanp opened this issue 10 months ago • 4 comments

Currently, it seems that Mathjax in marp renders math output as plain embedded SVG, disabling the contextual (right click) menu and most of the accessibility features.

Accessibility for screen readers is one of the major benefits of Mathjax. Accessibility is important for any public-facing web content, but especially so for teaching slides (which is my main use of marp).

The options in the contextual menu in Mathjax are also a huge feature of the library. Beyond adding even more accessibility, they let users zoom in on detailed equations and view the 'source' LaTeX for the equation -- both of these are huge benefits for slides distributed alongside a technical lecture.

It seems like some of these features are tied to rendering the math output as mathml versus SVG, but looking at the Mathjax documentation it seems many of the accessibility and context-menu features should also be possible with SVG.

Is it possible to enable these features (possibly as options) when using Mathjax in marp? Accessible math rendering should be the default, and having at least a configuration option to enable the contextual menu would be hugely helpful.

Apologies if I'm missing something here, I've looked pretty thoroughly through existing issues and done quite a bit of testing in both the VSCode addon and marp-cli.

Thanks! (And, while I'm here, thanks generally for the really fantastic framework. It's become an indispensable part of my workflow over the past couple of years!)

mcmahanp avatar Dec 26 '24 14:12 mcmahanp