diff --git a/config/_default/params.toml b/config/_default/params.toml index c571bf4..9601055 100644 --- a/config/_default/params.toml +++ b/config/_default/params.toml @@ -72,4 +72,3 @@ editPage = false highLight = true kaTex = false collapsibleSidebar = false - mermaid = true diff --git a/content/docs/prologue/quick-start.md b/content/docs/prologue/quick-start.md index 70de019..c95f282 100644 --- a/content/docs/prologue/quick-start.md +++ b/content/docs/prologue/quick-start.md @@ -11,14 +11,9 @@ menu: parent: "prologue" weight: 110 toc: true +mermaid: true --- -```js -function myFunction(p1, p2) { - return p1 * p2; // The function returns the product of p1 and p2 -} -``` - ## Flowchart ### Shortcode diff --git a/layouts/partials/footer/script-footer.html b/layouts/partials/footer/script-footer.html index c868c79..64ccf13 100644 --- a/layouts/partials/footer/script-footer.html +++ b/layouts/partials/footer/script-footer.html @@ -65,7 +65,7 @@ {{ end -}} - {{ if .Site.Params.options.mermaid -}} + {{ with .Params.mermaid -}} {{ end -}} {{ if .Site.Params.options.flexSearch -}} @@ -90,7 +90,7 @@ {{ end -}} - {{ if .Site.Params.options.mermaid -}} + {{ with .Params.mermaid -}} {{ end -}} {{ if .Site.Params.options.flexSearch -}} diff --git a/layouts/shortcodes/mermaid.html b/layouts/shortcodes/mermaid.html index ae18745..aeecad5 100644 --- a/layouts/shortcodes/mermaid.html +++ b/layouts/shortcodes/mermaid.html @@ -1,8 +1,8 @@ -{{ if .Site.Params.options.mermaid -}} +{{ if .Page.Params.mermaid -}}