topbar: streamline button configuration #978

This commit is contained in:
Sören Weber 2024-12-31 14:12:39 +01:00
parent 2cd8baa02f
commit 7807445527
No known key found for this signature in database
GPG key ID: BEC6D55545451B6D
4 changed files with 7 additions and 8 deletions

View file

@ -2,8 +2,8 @@
{{- $onwidthm := cond (isset . "onwidthm") .onwidthm "show" }}
{{- $onwidthl := cond (isset . "onwidthl") .onwidthl "show" }}
{{- with .page }}
{{- $showPrevNext := (and (not .Params.disableNextPrev) (not .Site.Params.disableNextPrev)) }}
{{- if $showPrevNext }}
{{- $show := not (.Param "disableNextPrev") }}
{{- if $show }}
{{- $endarrow := "🡒" }}
{{- if eq (.Language.LanguageDirection | default (T "Reading-direction") | default "ltr") "rtl" }}
{{- $endarrow = "🡐" }}

View file

@ -2,8 +2,8 @@
{{- $onwidthm := cond (isset . "onwidthm") .onwidthm "show" }}
{{- $onwidthl := cond (isset . "onwidthl") .onwidthl "show" }}
{{- with .page }}
{{- $showPrevNext := (and (not .Params.disableNextPrev) (not .Site.Params.disableNextPrev)) }}
{{- if $showPrevNext }}
{{- $show := not (.Param "disableNextPrev") }}
{{- if $show }}
{{- $startarrow := "🡐" }}
{{- if eq (.Language.LanguageDirection | default (T "Reading-direction") | default "ltr") "rtl" }}
{{- $startarrow = "🡒" }}

View file

@ -3,9 +3,8 @@
{{- $onwidthm := cond (isset . "onwidthm") .onwidthm "show" }}
{{- $onwidthl := cond (isset . "onwidthl") .onwidthl "show" }}
{{- with .page }}
{{- $defaultDisableToc := .Site.Params.disableToc | default false }}
{{- $currentDisableToc := .Params.disableToc | default $defaultDisableToc }}
{{- if not $currentDisableToc }}
{{- $show := not (.Param "disableToc") }}
{{- if $show }}
{{- $content := partial "toc-class.html" . }}
{{- $hascontent := not (eq 0 (int (len (trim ($content | plainify) "\n\r\t ")))) }}
{{- if not $hascontent }}

View file

@ -1 +1 @@
7.2.1+d9152f9abaf57fec38d9a8ede67ebbf94303b9e3
7.2.1+2cd8baa02f811124d580c519d95b3f977a1972f6