mirror of
https://github.com/agdamsbo/REDCapCAST.git
synced 2026-06-19 13:17:30 +02:00
Deploying to gh-pages from @ agdamsbo/REDCapCAST@c7ab477203 🚀
This commit is contained in:
parent
8034c8eef6
commit
30ae247eac
82 changed files with 12088 additions and 2619 deletions
14
katex-auto.js
Normal file
14
katex-auto.js
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
// https://github.com/jgm/pandoc/blob/29fa97ab96b8e2d62d48326e1b949a71dc41f47a/src/Text/Pandoc/Writers/HTML.hs#L332-L345
|
||||
document.addEventListener("DOMContentLoaded", function () {
|
||||
var mathElements = document.getElementsByClassName("math");
|
||||
var macros = [];
|
||||
for (var i = 0; i < mathElements.length; i++) {
|
||||
var texText = mathElements[i].firstChild;
|
||||
if (mathElements[i].tagName == "SPAN") {
|
||||
katex.render(texText.data, mathElements[i], {
|
||||
displayMode: mathElements[i].classList.contains("display"),
|
||||
throwOnError: false,
|
||||
macros: macros,
|
||||
fleqn: false
|
||||
});
|
||||
}}});
|
||||
Loading…
Add table
Add a link
Reference in a new issue