From e2f374c016487a0b0736c85c353e068278362fab Mon Sep 17 00:00:00 2001 From: Anton Akhmerov <anton.akhmerov@gmail.com> Date: Fri, 27 Jul 2018 13:41:29 +0200 Subject: [PATCH] testing mathjax --- mkdocs.yml | 2 +- src/scripts/mathjaxhelper.js | 25 ++++++++++++++++++++----- 2 files changed, 21 insertions(+), 6 deletions(-) diff --git a/mkdocs.yml b/mkdocs.yml index a237422e..b0a8d172 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -32,7 +32,7 @@ markdown_extensions: - pymdownx.details extra_javascript: - - 'scripts/mathjaxhelper.js' - 'https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.3/MathJax.js?config=TeX-AMS_HTML' - 'https://cdn.plot.ly/plotly-latest.min.js' + - 'scripts/mathjaxhelper.js' copyright: "Copyright © 2017-2018 Delft University of Technology, CC-BY-SA-NC 4.0." diff --git a/src/scripts/mathjaxhelper.js b/src/scripts/mathjaxhelper.js index bec7b177..03d02b30 100644 --- a/src/scripts/mathjaxhelper.js +++ b/src/scripts/mathjaxhelper.js @@ -1,5 +1,20 @@ -MathJax.Hub.Config({ - config: ["MMLorHTML.js"], - jax: ["input/TeX", "output/HTML-CSS", "output/NativeMML"], - extensions: ["MathMenu.js", "MathZoom.js"] -}); +window.MathJax = { + tex2jax: { + inlineMath: [ ["\\(","\\)"] ], + displayMath: [ ["\\[","\\]"] ] + }, + TeX: { + TagSide: "right", + TagIndent: ".8em", + MultLineWidth: "85%", + equationNumbers: { + autoNumber: "AMS", + }, + unicode: { + fonts: "STIXGeneral,'Arial Unicode MS'" + } + }, + displayAlign: "left", + showProcessingMessages: false, + messageStyle: "none" +}; -- GitLab