Merge remote-tracking branch 'upstream/main' into upstream

This commit is contained in:
phil 2023-07-14 07:54:27 +02:00
commit 95632a5aff
44 changed files with 2699 additions and 1489 deletions

View file

@ -6,6 +6,6 @@
</label>
<input id="{{ $id }}-{{ .Ordinal }}" type="checkbox" class="gdoc-expand__control hidden" />
<div class="gdoc-markdown--nested gdoc-expand__content">
{{ .Inner | $.Page.RenderString | htmlUnescape | safeHTML }}
{{ .Inner | $.Page.RenderString }}
</div>
</div>

View file

@ -1,7 +1,7 @@
{{- $source := ($.Page.Resources.ByType "image").GetMatch (printf "%s" (.Get "name")) }}
{{- $customAlt := .Get "alt" }}
{{- $customSize := .Get "size" | lower }}
{{- $lazyLoad := default (default true $.Site.Params.GeekdocImageLazyLoading) (.Get "lazy") }}
{{- $lazyLoad := default (default true $.Site.Params.geekdocImageLazyLoading) (.Get "lazy") }}
{{- $data := newScratch }}
{{- with $source }}

View file

@ -1,4 +1,4 @@
{{- $tocLevels := default (default 6 .Site.Params.GeekdocToC) .Page.Params.GeekdocToC }}
{{- $tocLevels := default (default 6 .Site.Params.geekdocToC) .Page.Params.geekdocToC }}
{{- if $tocLevels }}
<div class="gdoc-toc gdoc-toc__level--{{ $tocLevels }}">
@ -12,23 +12,25 @@
<ul>
{{- range .sect.GroupBy "Weight" }}
{{- range .ByTitle }}
{{- if or (not .Params.GeekdocHidden) (not (default true .Params.GeekdocHiddenTocTree)) }}
{{- if or (not .Params.geekdocHidden) (not (default true .Params.geekdocHiddenTocTree)) }}
<li>
{{- if or .Content .Params.GeekdocFlatSection }}
{{- if or .Content .Params.geekdocFlatSection }}
<span>
<a href="{{ .RelPermalink }}" class="gdoc-toc__entry">
{{- partial "utils/title" . }}{{ with .Params.GeekdocDescription }}:{{ end }}
{{- partial "utils/title" . }}{{ with .Params.geekdocDescription }}:{{ end }}
</a>
{{- with .Params.GeekdocDescription }}{{ . }}{{ end }}
{{- with .Params.geekdocDescription }}{{ . }}{{ end }}
</span>
{{- else -}}
<span>
{{- partial "utils/title" . }}{{ with .Params.GeekdocDescription }}: {{ . }}{{ end }}
{{- partial "utils/title" . }}{{ with .Params.geekdocDescription }}
: {{ . }}
{{ end }}
</span>
{{- end -}}
{{- $numberOfPages := (add (len .Pages) (len .Sections)) }}
{{- if and (ne $numberOfPages 0) (not .Params.GeekdocFlatSection) }}
{{- if and (ne $numberOfPages 0) (not .Params.geekdocFlatSection) }}
{{- template "toc-tree" dict "sect" .Pages }}
{{- end }}
</li>

View file

@ -1,5 +1,5 @@
{{- $format := default "html" (.Get "format") }}
{{- $tocLevels := default (default 6 .Site.Params.GeekdocToC) .Page.Params.GeekdocToC }}
{{- $tocLevels := default (default 6 .Site.Params.geekdocToC) .Page.Params.geekdocToC }}
{{- if and $tocLevels .Page.TableOfContents -}}
{{- if not (eq ($format | lower) "raw") -}}