tubestats-presentation/dist/plugin/math.js

2 lines
1.1 KiB
JavaScript
Raw Normal View History

!function(e){"function"==typeof define&&define.amd?define(e):e()}((function(){"use strict";var e=function(){var e=Reveal.getConfig().math||{},t=(e.mathjax||"https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.0/MathJax.js")+"?config="+(e.config||"TeX-AMS_HTML-full"),a={messageStyle:"none",tex2jax:{inlineMath:[["$","$"],["\\(","\\)"]],skipTags:["script","noscript","style","textarea","pre"]},skipStartupTypeset:!0};function n(e,t){for(var a in t)e.hasOwnProperty(a)||(e[a]=t[a])}return{id:"math",init:function(i){n(e,a),n(e.tex2jax,a.tex2jax),e.mathjax=e.config=null,function(e,t){var a=document.querySelector("head"),n=document.createElement("script");n.type="text/javascript",n.src=e;var i=function(){"function"==typeof t&&(t.call(),t=null)};n.onload=i,n.onreadystatechange=function(){"loaded"===this.readyState&&i()},a.appendChild(n)}(t,(function(){MathJax.Hub.Config(e),MathJax.Hub.Queue(["Typeset",MathJax.Hub]),MathJax.Hub.Queue(i.layout),i.on("slidechanged",(function(e){MathJax.Hub.Queue(["Typeset",MathJax.Hub,e.currentSlide])}))}))}}}();Reveal.registerPlugin(e)}));