summaryrefslogtreecommitdiff
path: root/layouts/_partials/single
diff options
context:
space:
mode:
authorArne Rief <riearn@proton.me>2026-01-09 12:24:05 +0100
committerArne Rief <riearn@proton.me>2026-01-09 12:24:05 +0100
commitf8541ef965ca22e746b523eb418e47cb4f78f2d8 (patch)
tree49e1540ed42595a44196817eadf97337587a2aea /layouts/_partials/single
parent038054b8206a9c25e84adeb0f0f355abd22d6143 (diff)
Upgrade to new template system from Hugo v0.146.0
Diffstat (limited to 'layouts/_partials/single')
-rw-r--r--layouts/_partials/single/next-prev.html44
-rw-r--r--layouts/_partials/single/tags.html17
2 files changed, 61 insertions, 0 deletions
diff --git a/layouts/_partials/single/next-prev.html b/layouts/_partials/single/next-prev.html
new file mode 100644
index 0000000..932fcac
--- /dev/null
+++ b/layouts/_partials/single/next-prev.html
@@ -0,0 +1,44 @@
+{{- /* Navigation for next & previous post and back to top */ -}}
+{{- if ne .Params.excludeFromLists true }}
+<nav class="post__navigation" aria-label="{{ lang.Translate "posts_navigation" | default "Post navigation" }}">
+ <hr />
+ <ul class="post__navigation-list">
+ {{- with .PrevInSection }}
+ <li class="post__navigation-prev">
+ <a href="{{ .RelPermalink }}" class="post__navigation-link" rel="prev">
+ <span class="post__navigation-label">
+ &larr; {{ lang.Translate "posts_previous" | default "Previous post:" }}
+ </span>
+ <span class="post__navigation-title">
+ {{ .Title }}
+ </span>
+ </a>
+ </li>
+ {{- end }}
+
+ {{- with .NextInSection }}
+ <li class="post__navigation-next">
+ <a href="{{ .RelPermalink }}" class="post__navigation-link" rel="next">
+ <span class="post__navigation-label">
+ &rarr; {{ lang.Translate "posts_next" | default "Next post:" }}
+ </span>
+ <span class="post__navigation-title">
+ {{ .Title }}
+ </span>
+ </a>
+ </li>
+ {{- end }}
+ </ul>
+</nav>
+
+<a
+ href="#"
+ class="post__scroll-top"
+ aria-label="{{ lang.Translate "back_top" | default "Back to top" }}"
+ title="{{ lang.Translate "back_top" | default "Back to top" }}"
+>
+ <svg viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg" aria-hidden="true">
+ <path d="M17 15L12 10L7 15" stroke="#000000" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>
+ </svg>
+</a>
+{{- end }}
diff --git a/layouts/_partials/single/tags.html b/layouts/_partials/single/tags.html
new file mode 100644
index 0000000..0c10d20
--- /dev/null
+++ b/layouts/_partials/single/tags.html
@@ -0,0 +1,17 @@
+{{- with .GetTerms "tags" }}
+<section class="post__tags" aria-labelledby="tags-heading">
+ <p id="tags-heading" class="post__tags-heading">
+ {{ lang.Translate "tags" | default "Tags" }}
+ </p>
+
+ <ul class="post__tags-list">
+ {{- range . }}
+ <li class="post__tags-item">
+ <a href="{{ .RelPermalink }}" class="post__tags-link" rel="tag">
+ #{{ .Title }}
+ </a>
+ </li>
+ {{- end }}
+ </ul>
+</section>
+{{- end }}