refactor: use .Site.Home.RelPermalink for home page links in the sidebar (#1248)

refactor: use `.Site.Home.RelPermalink` for home page links in the sidebar.
This commit is contained in:
Jimmy
2026-01-26 23:59:40 +01:00
committed by GitHub
parent 7d4bfa9fc0
commit 33b7de9457
+2 -2
View File
@@ -9,7 +9,7 @@
{{ with .Site.Params.sidebar.avatar }}
{{- $avatar := partial "helper/image" (dict "Image" . "Resources" resources) -}}
<figure class="site-avatar">
<a href="{{ $.Site.BaseURL | relLangURL }}">
<a href="{{ .Site.Home.RelPermalink }}">
<img src="{{ $avatar.Permalink }}"
width="{{ $avatar.Width }}"
height="{{ $avatar.Height }}"
@@ -24,7 +24,7 @@
{{ end }}
<div class="site-meta">
<h1 class="site-name"><a href="{{ .Site.BaseURL | relLangURL }}">{{ .Site.Title }}</a></h1>
<h1 class="site-name"><a href="{{ .Site.Home.RelPermalink }}">{{ .Site.Title }}</a></h1>
<h2 class="site-description">{{ .Site.Params.sidebar.subtitle }}</h2>
</div>
</header>