summaryrefslogtreecommitdiffstats
path: root/docs
diff options
context:
space:
mode:
authorBjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>2023-03-01 11:56:07 +0100
committerBjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>2023-03-01 11:56:07 +0100
commit97b010f521e592b5fc29daace225476b64543643 (patch)
treeddccebf102a88fb3f8c936dd9178f2ae02d3693e /docs
parent4d36b99a4e119594cb658a8796b18fc13b0672bc (diff)
parent336622d5e7afd9334cd2de7150d4f16bdf7c24f9 (diff)
Diffstat (limited to 'docs')
-rw-r--r--docs/content/en/about/security-model/index.md2
-rw-r--r--docs/content/en/getting-started/quick-start.md8
-rw-r--r--docs/layouts/_default/_markup/render-codeblock-mermaid.html4
-rw-r--r--docs/layouts/partials/hooks/before-body-end.html5
4 files changed, 13 insertions, 6 deletions
diff --git a/docs/content/en/about/security-model/index.md b/docs/content/en/about/security-model/index.md
index 66cb15463..d4dacd9bf 100644
--- a/docs/content/en/about/security-model/index.md
+++ b/docs/content/en/about/security-model/index.md
@@ -57,7 +57,7 @@ For HTML output, this is the core security model:
In short:
-Templates authors (you) are trusted, but the data you send in is not.
+Template and configuration authors (you) are trusted, but the data you send in is not.
This is why you sometimes need to use the _safe_ functions, such as `safeHTML`, to avoid escaping of data you know is safe.
There is one exception to the above, as noted in the documentation: If you enable inline shortcodes, you also say that the shortcodes and data handling in content files are trusted, as those macros are treated as pure text.
It may be worth adding that Hugo is a static site generator with no concept of dynamic user input.
diff --git a/docs/content/en/getting-started/quick-start.md b/docs/content/en/getting-started/quick-start.md
index 824d6030a..d49997570 100644
--- a/docs/content/en/getting-started/quick-start.md
+++ b/docs/content/en/getting-started/quick-start.md
@@ -34,7 +34,13 @@ You must also be comfortable working from the command line.
### Commands
{{% note %}}
-If you are a Windows user, you must run these commands with [PowerShell]. You cannot use Windows Powershell, which is a different application, or the Command Prompt. You may also use a Linux shell if available.
+**If you are a Windows user:**
+
+- Do not use the Command Prompt
+- Do not use Windows PowerShell
+- Run these commands from [PowerShell] or a Linux terminal such as WSL or Git Bash
+
+PowerShell and Windows PowerShell are different applications.
[PowerShell]: https://learn.microsoft.com/en-us/powershell/scripting/install/installing-powershell-on-windows
{{% /note %}}
diff --git a/docs/layouts/_default/_markup/render-codeblock-mermaid.html b/docs/layouts/_default/_markup/render-codeblock-mermaid.html
index 59641551c..94ea0cad0 100644
--- a/docs/layouts/_default/_markup/render-codeblock-mermaid.html
+++ b/docs/layouts/_default/_markup/render-codeblock-mermaid.html
@@ -1,4 +1,4 @@
-<div class="mermaid">
+<pre class="mermaid">
{{- .Inner | safeHTML }}
-</div>
+</pre>
{{ .Page.Store.Set "hasMermaid" true }}
diff --git a/docs/layouts/partials/hooks/before-body-end.html b/docs/layouts/partials/hooks/before-body-end.html
index fb7ae20ba..dab653508 100644
--- a/docs/layouts/partials/hooks/before-body-end.html
+++ b/docs/layouts/partials/hooks/before-body-end.html
@@ -1,6 +1,7 @@
{{ if .Page.Store.Get "hasMermaid" }}
- <script src="https://cdn.jsdelivr.net/npm/mermaid/dist/mermaid.min.js"></script>
- <script>
+ <script type="module" async>
+ import mermaid from 'https://cdn.jsdelivr.net/npm/mermaid@9/+esm';
+
mermaid.initialize({ startOnLoad: true });
</script>
{{ end }}