Reset the tex labels and ids when A11y changes force rerendering. (mathjax/MathJax#2597) #570
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR forces TeX to reset the tags when an A11Y menu item causes the page to re-render.
It may be good to abstract this so that the MathDocument has a
reset
method that can just be called, and that would call resets on the input jax (and output jax?), which would be empty for ones with no reset, but would do the TeX reset for the TeX input.It may also be appropriate to save the expression labels and ids for each expression so that if it is re-rendered, it clear those labels and ids, and start auto-numbering at the right place. That would allow proper rerendering without making assumptions about where the numbering starts on the page, or what labels need to be cleared.
Resolves issue mathjax/MathJax#2597