Files
KaTeX/contrib/auto-render
Marco Esters 4d3fdd8647 fix(auto-render): concatenate content of successive text nodes (#3422)
* fix(auto-render): concatenate text nodes

Concatenate successive text nodes to prevent auto-render from skipping
math input when browsers split text nodes with long textContent.

* Remove siblings only when math found

Only remove siblings when math expressions were found to prevent removal
of nodes that do not contain math.

* Skip siblings if they do not contain math

* Fixed typo in comments

* Added first tests for large test nodes

* Expanded testing to compare renderMathInElement with renderMathInText

* Simplified text node test

* Change description of test

* Update contrib/auto-render/auto-render.js

Co-authored-by: marcoesters <marco.esters@duke.edu>
Co-authored-by: ylemkimon <y@ylem.kim>
2022-08-30 06:50:14 +09:00
..
2018-08-31 04:08:02 -04:00

Auto-render extension

This is an extension to automatically render all of the math inside of text. It searches all of the text nodes in a given element for the given delimiters, and renders the math in place.

See Auto-render extension documentation for more information.