From ee77892ea9591ed6ff7ec33173bfc4b1ea4f6895 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=B6ren=20Weber?= Date: Thu, 23 Nov 2023 23:21:57 +0100 Subject: [PATCH] docs: remove limitation on guessSyntax seems to be fixed in Hugo 0.93.0? --- exampleSite/config/_default/config.toml | 5 ----- exampleSite/content/basics/migration/_index.en.md | 2 +- exampleSite/content/shortcodes/highlight.en.md | 5 ----- exampleSite/content/shortcodes/math.en.md | 15 --------------- exampleSite/content/shortcodes/mermaid.en.md | 15 --------------- 5 files changed, 1 insertion(+), 41 deletions(-) diff --git a/exampleSite/config/_default/config.toml b/exampleSite/config/_default/config.toml index 9feb43d6e59..999201ef1fd 100644 --- a/exampleSite/config/_default/config.toml +++ b/exampleSite/config/_default/config.toml @@ -51,11 +51,6 @@ title = "Hugo Relearn Theme" # not use it; visually both layouts have the same look and behavior lineNumbersInTable = false - # if `guessSyntax = true`, there will be no unstyled code even if no language - # was given BUT Mermaid and Math codefences will not work anymore! So this is a - # mandatory setting for your site if you want to use Mermaid or Math codefences - guessSyntax = false - # the shipped variants come with their own modified chroma syntax highlightning # style which is imported in theme-relearn-light.css, theme-relearn-dark.css, etc.; # if you want to use a predefined style instead: diff --git a/exampleSite/content/basics/migration/_index.en.md b/exampleSite/content/basics/migration/_index.en.md index 7607986ee31..dbc6cc8da6e 100644 --- a/exampleSite/content/basics/migration/_index.en.md +++ b/exampleSite/content/basics/migration/_index.en.md @@ -679,7 +679,7 @@ This document shows you what's new in the latest release and flags it with one o ## 2.5.0 (2021-10-08) {#250} -- {{% badge style="note" title=" " %}}Change{{% /badge %}} New colors `--CODE-BLOCK-color` and `--CODE-BLOCK-BG-color` were added to provide a fallback for Hugos syntax highlighting in case `guessSyntax=true` is set. Ideally the colors are set to the same values as the ones from your chosen chroma style. +- {{% badge style="note" title=" " %}}Change{{% /badge %}} New colors `--CODE-BLOCK-color` and `--CODE-BLOCK-BG-color` were added to provide a fallback for Hugos syntax highlighting in case no language was given or the language is unsupported. Ideally the colors are set to the same values as the ones from your chosen chroma style. --- diff --git a/exampleSite/content/shortcodes/highlight.en.md b/exampleSite/content/shortcodes/highlight.en.md index c1930b215d5..15f61c5f9f0 100644 --- a/exampleSite/content/shortcodes/highlight.en.md +++ b/exampleSite/content/shortcodes/highlight.en.md @@ -103,11 +103,6 @@ Default values for extension options can be set via params settings in your `con # use inline; besides that visually both layouts have the same look and behavior lineNumbersInTable = false - # if `guessSyntax = true`, there will be no unstyled code even if no language - # was given BUT Mermaid and Math codefences will not work anymore! So this is a - # mandatory setting for your site if you want to use Mermaid or Math codefences - guessSyntax = false - # the shipped variants come with their own modified chroma syntax highlightning # style which is imported in theme-relearn-light.css, theme-relearn-dark.css, etc.; # if you want to use a predefined style instead: diff --git a/exampleSite/content/shortcodes/math.en.md b/exampleSite/content/shortcodes/math.en.md index 04afd028538..0fcd4262e0d 100644 --- a/exampleSite/content/shortcodes/math.en.md +++ b/exampleSite/content/shortcodes/math.en.md @@ -19,10 +19,6 @@ While the examples are using shortcodes with named parameter it is recommended t You are free to also call this shortcode from your own partials. -{{% notice note %}} -To use codefence syntax you have to turn off `guessSyntax` for the `markup.highlight` setting ([see the configuration section](#configuration)). -{{% /notice %}} - {{< tabs groupid="shortcode-parameter">}} {{% tab title="codefence" %}} @@ -71,22 +67,11 @@ The JSON object of your `config.toml` / frontmatter is forwarded into MathJax's See [MathJax documentation](https://docs.mathjax.org/en/latest/options/index.html) for all allowed settings. -{{% notice note %}} -To use codefence syntax you have to turn off `guessSyntax` for the `markup.highlight` setting. -{{% /notice %}} - ### Global Configuration File ````toml [params] mathJaxInitialize = "{ \"chtml\": { \"displayAlign\": \"left\" } }" - -[markup] - [markup.highlight] - # if `guessSyntax = true`, there will be no unstyled code even if no language - # was given BUT Mermaid and Math codefences will not work anymore! So this is a - # mandatory setting for your site if you want to use Math codefences - guessSyntax = false ```` ### Page's Frontmatter diff --git a/exampleSite/content/shortcodes/mermaid.en.md b/exampleSite/content/shortcodes/mermaid.en.md index 4de08abc74d..a3efc5aa55f 100644 --- a/exampleSite/content/shortcodes/mermaid.en.md +++ b/exampleSite/content/shortcodes/mermaid.en.md @@ -21,10 +21,6 @@ While the examples are using shortcodes with named parameter it is recommended t You are free to also call this shortcode from your own partials. -{{% notice note %}} -To use codefence syntax you have to turn off `guessSyntax` for the `markup.highlight` setting ([see the configuration section](#configuration)). -{{% /notice %}} - {{< tabs groupid="shortcode-parameter">}} {{% tab title="codefence" %}} @@ -83,23 +79,12 @@ See [Mermaid documentation](https://mermaid-js.github.io/mermaid/#/Setup?id=merm The `theme` setting can also be set by your used color variant. This will be the sitewide default and can - again - be overridden by your settings in `config.toml`, frontmatter or diagram directives. -{{% notice note %}} -To use codefence syntax you have to turn off `guessSyntax` for the `markup.highlight` setting. -{{% /notice %}} - ### Global Configuration File ````toml [params] mermaidInitialize = "{ \"theme\": \"dark\" }" mermaidZoom = true - -[markup] - [markup.highlight] - # if `guessSyntax = true`, there will be no unstyled code even if no language - # was given BUT Mermaid and Math codefences will not work anymore! So this is a - # mandatory setting for your site if you want to use Mermaid codefences - guessSyntax = false ```` ### Page's Frontmatter