summaryrefslogtreecommitdiffhomepage
path: root/layouts
diff options
context:
space:
mode:
Diffstat (limited to 'layouts')
-rw-r--r--layouts/partials/scripts.html7
1 files changed, 7 insertions, 0 deletions
diff --git a/layouts/partials/scripts.html b/layouts/partials/scripts.html
index b6f9696d3..52c7c327f 100644
--- a/layouts/partials/scripts.html
+++ b/layouts/partials/scripts.html
@@ -10,3 +10,10 @@
<script src="{{ $js.RelPermalink }}" integrity="{{ $js.Data.Integrity }}"></script>
{{ end }}
{{ partial "hooks/body-end.html" . }}
+
+<script type="text/javascript">
+ $("body.td-page,body.td-section").find("main h2,h3,h4").each(function() {
+ var fragment = $(this).attr('id');
+ $(this).append('&nbsp;<a href="#'+fragment+'" class="header-link"><i class="fas fa-link"></i></a>');
+ });
+</script>