aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--exampleSite/content/docs/shortcodes.md12
-rw-r--r--layouts/shortcodes/katex.html2
2 files changed, 8 insertions, 6 deletions
diff --git a/exampleSite/content/docs/shortcodes.md b/exampleSite/content/docs/shortcodes.md
index 0994210..2844acb 100644
--- a/exampleSite/content/docs/shortcodes.md
+++ b/exampleSite/content/docs/shortcodes.md
@@ -172,20 +172,22 @@ sequenceDiagram
{{< columns >}}
-```
-$$ x = \begin{cases}
+```latex
+{{</* katex */>}}
+x = \begin{cases}
a &\text{if } b \\
c &\text{if } d
-\end{cases} $$
+\end{cases}
+{{</* /katex */>}}
```
<--->
{{< katex >}}
-$$ x = \begin{cases}
+x = \begin{cases}
a &\text{if } b \\
c &\text{if } d
-\end{cases} $$
+\end{cases}
{{< /katex >}}
{{< /columns >}}
diff --git a/layouts/shortcodes/katex.html b/layouts/shortcodes/katex.html
index 5807c50..8f440ad 100644
--- a/layouts/shortcodes/katex.html
+++ b/layouts/shortcodes/katex.html
@@ -7,6 +7,6 @@
{{ end }}
<p class="katex{{ with .Get "class" }} {{ . }}{{ end }}">
- {{ .Inner }}
+ $$ {{ .Inner }} $$
</p>