Merge remote-tracking branch 'origin/main' into style/herman
This commit is contained in:
commit
488fcc401f
4 changed files with 19 additions and 2 deletions
6
layouts/_default/_markup/render-codeblock.html
Normal file
6
layouts/_default/_markup/render-codeblock.html
Normal file
|
@ -0,0 +1,6 @@
|
|||
<!-- https://github.com/jmooring/hugo-testing/blob/hugo-forum-topic-40998/layouts/_default/_markup/render-codeblock-katex.html -->
|
||||
{{ .Page.Store.Set "hasCodeBlock" true }}
|
||||
|
||||
<!-- https://www.veriphor.com/articles/code-block-render-hooks/ -->
|
||||
{{ $result := transform.HighlightCodeBlock . }}
|
||||
{{ $result.Wrapped }}
|
|
@ -14,8 +14,10 @@
|
|||
{{ $style := resources.Get "herman.css" | minify }}
|
||||
<link href="{{ $style.RelPermalink }}" rel="stylesheet">
|
||||
|
||||
{{ $syntax := resources.Get "syntax.css" | minify }}
|
||||
<link href="{{ $syntax.RelPermalink }}" rel="stylesheet">
|
||||
{{ if (.Page.Store.Get "hasCodeBlock") }}
|
||||
{{ $syntax := resources.Get "syntax.css" | minify }}
|
||||
<link href="{{ $syntax.RelPermalink }}" rel="stylesheet">
|
||||
{{ end }}
|
||||
|
||||
{{ with .Params.style }}
|
||||
{{ $extra := resources.Get . | minify }}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue