From e6e04c03c473175961e1d5f9c815c3671f237c8e Mon Sep 17 00:00:00 2001
From: Jacky Zhao <j.zhao2k19@gmail.com>
Date: Sun, 03 Apr 2022 03:34:55 +0000
Subject: [PATCH] fix latex misrendering
---
content/notes/CJK + Latex Support (测试).md | 2 +-
Makefile | 2 +-
assets/js/popover.js | 1 -
layouts/partials/katex.html | 2 --
4 files changed, 2 insertions(+), 5 deletions(-)
diff --git a/Makefile b/Makefile
index 038d69e..9b04d70 100644
--- a/Makefile
+++ b/Makefile
@@ -4,4 +4,4 @@
@grep -E '^[a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-30s\033[0m %s\n", $$1, $$2}'
serve: ## serve
- hugo-obsidian -input=content -output=assets/indices -index -root=. && hugo server
+ hugo-obsidian -input=content -output=assets/indices -index -root=. && hugo server --enableGitInfo
diff --git a/assets/js/popover.js b/assets/js/popover.js
index 83cdc03..3d0d18b 100644
--- a/assets/js/popover.js
+++ b/assets/js/popover.js
@@ -11,7 +11,6 @@
fetchData.then(({ content }) => {
const links = [...document.getElementsByClassName("internal-link")]
links.forEach(li => {
- console.log(li.dataset)
const linkDest = content[li.dataset.src.replace(basePath, "")]
if (linkDest) {
const popoverElement = `<div class="popover">
diff --git "a/content/notes/CJK + Latex Support \050\346\265\213\350\257\225\051.md" "b/content/notes/CJK + Latex Support \050\346\265\213\350\257\225\051.md"
index a528198..8b4a741 100644
--- "a/content/notes/CJK + Latex Support \050\346\265\213\350\257\225\051.md"
+++ "b/content/notes/CJK + Latex Support \050\346\265\213\350\257\225\051.md"
@@ -14,7 +14,7 @@
Block math works with two dollar signs `$$...$$`
$$f(x) = \int_{-\infty}^\infty
- f\hat(\xi\),e^{2 \pi i \xi x}
+ f\hat(\xi),e^{2 \pi i \xi x}
\,d\xi$$
Inline math also works with single dollar signs `$...$`. For example, Euler's identity but inline: $e^{i\pi} = 0$
diff --git a/layouts/partials/katex.html b/layouts/partials/katex.html
index 4670c69..e11c4f1 100644
--- a/layouts/partials/katex.html
+++ b/layouts/partials/katex.html
@@ -8,8 +8,6 @@
delimiters: [
{left: '$$', right: '$$', display: true},
{left: '$', right: '$', display: false},
- {left: '\\(', right: '\\)', display: false},
- {left: '\\[', right: '\\]', display: true}
],
throwOnError : false
});
--
Gitblit v1.10.0