diff --git a/.gitignore b/.gitignore index 2042e76..f36f822 100644 --- a/.gitignore +++ b/.gitignore @@ -9,6 +9,7 @@ /exampleSite/public/ /exampleSite/config/development/ CHANGELOG.md +VERSION # translation envs exampleSite/content/de diff --git a/README.md b/README.md index 3b67dda..45691ef 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ # Geekdoc [![Build Status](https://img.shields.io/drone/build/thegeeklab/hugo-geekdoc?logo=drone&server=https%3A%2F%2Fdrone.thegeeklab.de)](https://drone.thegeeklab.de/thegeeklab/hugo-geekdoc) -[![Hugo Version](https://img.shields.io/badge/hugo-0.83-blue.svg)](https://gohugo.io) +[![Hugo Version](https://img.shields.io/badge/hugo-0.93-blue.svg)](https://gohugo.io) [![GitHub release](https://img.shields.io/github/v/release/thegeeklab/hugo-geekdoc)](https://github.com/thegeeklab/hugo-geekdoc/releases/latest) [![GitHub contributors](https://img.shields.io/github/contributors/thegeeklab/hugo-geekdoc)](https://github.com/thegeeklab/hugo-geekdoc/graphs/contributors) [![License: MIT](https://img.shields.io/github/license/thegeeklab/hugo-geekdoc)](https://github.com/thegeeklab/hugo-geekdoc/blob/main/LICENSE) diff --git a/exampleSite/content/en/_index.md b/exampleSite/content/en/_index.md index f07ec42..36934df 100644 --- a/exampleSite/content/en/_index.md +++ b/exampleSite/content/en/_index.md @@ -9,7 +9,7 @@ geekdocAnchor: false [![Build Status](https://img.shields.io/drone/build/thegeeklab/hugo-geekdoc?logo=drone&server=https%3A%2F%2Fdrone.thegeeklab.de)](https://drone.thegeeklab.de/thegeeklab/hugo-geekdoc) -[![Hugo Version](https://img.shields.io/badge/hugo-0.83-blue.svg)](https://gohugo.io) +[![Hugo Version](https://img.shields.io/badge/hugo-0.93-blue.svg)](https://gohugo.io) [![GitHub release](https://img.shields.io/github/v/release/thegeeklab/hugo-geekdoc)](https://github.com/thegeeklab/hugo-geekdoc/releases/latest) [![GitHub contributors](https://img.shields.io/github/contributors/thegeeklab/hugo-geekdoc)](https://github.com/thegeeklab/hugo-geekdoc/graphs/contributors) [![License: MIT](https://img.shields.io/github/license/thegeeklab/hugo-geekdoc)](https://github.com/thegeeklab/hugo-geekdoc/blob/main/LICENSE) diff --git a/exampleSite/content/en/shortcodes/mermaid.md b/exampleSite/content/en/shortcodes/mermaid.md index 5ef14b9..ac98087 100644 --- a/exampleSite/content/en/shortcodes/mermaid.md +++ b/exampleSite/content/en/shortcodes/mermaid.md @@ -44,3 +44,36 @@ sequenceDiagram {{< /columns >}} + +As an alternative to shortcodes, code blocks can be used for markdown as well. + +{{< columns >}} + + +````tpl +```mermaid +flowchart LR + +A[Hard] -->|Text| B(Round) +B --> C{Decision} +C -->|One| D[Result 1] +C -->|Two| E[Result 2] +``` +```` + +<---> + + + +```mermaid +flowchart LR + +A[Hard] -->|Text| B(Round) +B --> C{Decision} +C -->|One| D[Result 1] +C -->|Two| E[Result 2] +``` + + + +{{< /columns >}} diff --git a/layouts/_default/_markup/render-codeblock-mermaid.html b/layouts/_default/_markup/render-codeblock-mermaid.html new file mode 100644 index 0000000..d3545db --- /dev/null +++ b/layouts/_default/_markup/render-codeblock-mermaid.html @@ -0,0 +1,11 @@ + +{{ if not (.Page.Scratch.Get "mermaid") }} + + + {{ .Page.Scratch.Set "mermaid" true }} +{{ end }} + + +
+  {{- .Inner -}}
+
diff --git a/theme.toml b/theme.toml index 3e5fe36..16a935e 100644 --- a/theme.toml +++ b/theme.toml @@ -5,7 +5,7 @@ description = "Hugo theme made for documentation" homepage = "https://geekdocs.de/" demosite = "https://geekdocs.de/" tags = ["docs", "documentation", "responsive", "simple"] -min_version = "0.83.0" +min_version = "0.93.0" [author] name = "Robert Kaussow"