DisableLanguageSwitch affects logo link

This commit is contained in:
Reorx 2022-05-05 00:48:51 +08:00
parent 7d6d7d5a3f
commit 8c344920f1
1 changed files with 4 additions and 0 deletions

View File

@ -44,7 +44,11 @@
<div class="logo"> <div class="logo">
{{- $label_text := (site.Params.label.text | default site.Title) }} {{- $label_text := (site.Params.label.text | default site.Title) }}
{{- if site.Title }} {{- if site.Title }}
{{- if site.Params.DisableLanguageSwitch }}
<a href="/" accesskey="h" title="{{ $label_text }} (Alt + H)">
{{- else }}
<a href="{{ "" | absLangURL }}" accesskey="h" title="{{ $label_text }} (Alt + H)"> <a href="{{ "" | absLangURL }}" accesskey="h" title="{{ $label_text }} (Alt + H)">
{{- end }}
{{- if site.Params.label.icon }} {{- if site.Params.label.icon }}
{{- $img := resources.Get site.Params.label.icon }} {{- $img := resources.Get site.Params.label.icon }}
{{- if $img }} {{- if $img }}