From 44f8ee0b7d882549d825ba135d5450f414b92520 Mon Sep 17 00:00:00 2001 From: Hanwen Guo Date: Sat, 27 Aug 2022 21:39:46 +0800 Subject: [PATCH] improve tex (mathjax) support --- content/posts/test-tex.md | 11 +++++++++++ layouts/shortcodes/texd.html | 3 +++ layouts/shortcodes/texi.html | 3 +++ 3 files changed, 17 insertions(+) create mode 100644 content/posts/test-tex.md create mode 100644 layouts/shortcodes/texd.html create mode 100644 layouts/shortcodes/texi.html diff --git a/content/posts/test-tex.md b/content/posts/test-tex.md new file mode 100644 index 0000000..df17f83 --- /dev/null +++ b/content/posts/test-tex.md @@ -0,0 +1,11 @@ +--- +title: "Test Tex" +date: 2022-08-26T22:28:10+08:00 +mathjax: true +draft: true +--- +{{< texi `\varphi` >}} +{{< texd `\begin{aligned} +\varphi &\Rightarrow \psi \\ +\varnothing &\rightarrow A +\end{aligned}` >}} diff --git a/layouts/shortcodes/texd.html b/layouts/shortcodes/texd.html new file mode 100644 index 0000000..dc2eaf9 --- /dev/null +++ b/layouts/shortcodes/texd.html @@ -0,0 +1,3 @@ + +$${{ .Get 0 }}$$ + diff --git a/layouts/shortcodes/texi.html b/layouts/shortcodes/texi.html new file mode 100644 index 0000000..96523d9 --- /dev/null +++ b/layouts/shortcodes/texi.html @@ -0,0 +1,3 @@ + +\({{ .Get 0 }}\) +