Skip to content

[toc2] Remove MathJax preview in headers and links#877

Merged
jfbercher merged 1 commit intoipython-contrib:masterfrom
jfbercher:toc2
Feb 13, 2017
Merged

[toc2] Remove MathJax preview in headers and links#877
jfbercher merged 1 commit intoipython-contrib:masterfrom
jfbercher:toc2

Conversation

@jfbercher
Copy link
Copy Markdown
Member

@jfbercher jfbercher commented Feb 8, 2017

This PR addresses a somewhat involved issue for toc2 and latex_envs together; see latex_envs#14.

toc2 copies the headers into links in order to populate the toc2 widow/sidebar, the table of contents (if enabled) in the notebook, and finally the navigate menu. When latex_envs is enabled, it has the capability to keep all equations and environments correctly numbered: each markdown rendering entails the reset of all equations numbers and the recomputation of all math renderings. Maths are stored as a preview in html, with styling, classes, ids, and embedded scripts. When copying the headers into links, these previews are copied as well. The duplication of ids then seems to cause a mess to the whole webpage rendering: maths in the toc window/sidebar is sometimes duplicated, maths can disappear in the toc and/or in the navigation menu.

The PR remove MathJax previews in headings links and restore the latex versions, which in turn, is interpreted by Mathjax when needed.

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.

1 participant