Преглед изворни кода

Remove support for MathJax (#613)

Alphonse Mariya пре 4 година
родитељ
комит
3c13225498
1 измењених фајлова са 1 додато и 20 уклоњено
  1. 1 20
      layouts/partials/posts/math.html

+ 1 - 20
layouts/partials/posts/math.html

@@ -1,23 +1,4 @@
-{{- if or (.Params.math) (.Site.Params.math) -}}
-  <script src="https://polyfill.io/v3/polyfill.min.js?features=es6"></script>
-  {{/* The file is already minified */}}
-  <script id="MathJax-script" async src="https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-mml-chtml.js"></script>
-  <script>
-    MathJax = {
-      tex: {
-        inlineMath: [
-          ['$', '$'], ['\\(', '\\)']
-        ],
-        processEscapes: true,
-        processEnvironments: true
-      },
-      options: {
-        skipHtmlTags: ['script', 'noscript', 'style', 'textarea', 'pre']
-      }
-    };
-  </script>
-{{- end -}}
-{{- if or (.Params.katex) (.Site.Params.katex) -}}
+{{- if or (.Params.math) (.Site.Params.math) (.Params.katex) (.Site.Params.katex) -}}
   <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/katex@0.13.11/dist/katex.min.css"
     integrity="sha384-Um5gpz1odJg5Z4HAmzPtgZKdTBHZdw8S29IecapCSB31ligYPhHQZMIlWLYQGVoc" crossorigin="anonymous">
   {{/* The loading of KaTeX is deferred to speed up page rendering */}}