From 8384e09033f0fdd00af3c872c6ad097bd63914fa Mon Sep 17 00:00:00 2001
From: Codruț Constantin Gușoi <codrut.gusoi+git-commit@gmail.com>
Date: Mon, 25 Jan 2021 20:13:58 +0000
Subject: [PATCH] Adds anchors to all headings (#439)

---
 layouts/partials/posts/series.html |    7 ++++++-
 1 files changed, 6 insertions(+), 1 deletions(-)

diff --git a/layouts/partials/posts/series.html b/layouts/partials/posts/series.html
index 589d600..d08a83d 100644
--- a/layouts/partials/posts/series.html
+++ b/layouts/partials/posts/series.html
@@ -5,7 +5,12 @@
     {{ $name := . | urlize }}
     {{ $series := index $.Site.Taxonomies.series $name }}
     {{ if gt (len $series.Pages) 1 }}
-      <h3>{{ i18n "see_also" | default "See also in" }} {{ . }}</h3>
+      <h3 id="{{ i18n "see_also" | default "See also in" | anchorize }}-{{ anchorize . | safeURL }}">
+        {{ i18n "see_also" | default "See also in" }} {{ . }}
+        <a class="heading-link" href="#{{ i18n "see_also" | default "See also in" | anchorize }}-{{ anchorize . | safeURL }}">
+          <i class="fa fa-link" aria-hidden="true"></i>
+        </a>
+      </h3>
       <nav>
         <ul>
         {{ $maxItems := $.Site.Params.maxSeeAlsoItems | default 5 }}

--
Gitblit v1.10.0