Sync branch magefile with main #104308

Merged
Sybren A. Stüvel merged 85 commits from abelli/flamenco:magefile into magefile 2024-05-13 16:26:32 +02:00
2 changed files with 15 additions and 2 deletions
Showing only changes of commit 5c60561ddb - Show all commits

View File

@ -71,11 +71,11 @@
{{- printf " is-active" }}
{{- end }}"
>
{{ partial "utils/title" . }}
{{ partial "utils/title-toc" . }}
</a>
</span>
{{ else }}
<span class="flex">{{ partial "utils/title" . }}</span>
<span class="flex">{{ partial "utils/title-toc" . }}</span>
{{ end }}
{{ if $doCollapse }}
<svg class="gdoc-icon toggle gdoc_keyboard_arrow_left">

View File

@ -0,0 +1,13 @@
{{ $title := "" }}
{{ if .Page.Params.TitleTOC }}
{{ $title = .Page.Params.TitleTOC }}
{{ else if .Title }}
{{ $title = .Title }}
{{ else if and .IsSection .File }}
{{ $title = path.Base .File.Dir | humanize | title }}
{{ else if and .IsPage .File }}
{{ $title = .File.BaseFileName | humanize | title }}
{{ end }}
{{ return $title }}