update theme to allow easier ending of sections via short code

This commit is contained in:
KemoNine 2023-03-19 14:37:38 -04:00
parent 32b05f862f
commit dfee4bc1fe
3 changed files with 4 additions and 2 deletions

View file

@ -27,13 +27,13 @@
{{ if $.Scratch.Get "has_related" }} {{ if $.Scratch.Get "has_related" }}
<h2>See Also</h2> <h2>See Also</h2>
<a href="#top">Back to top</a>
<ul> <ul>
{{ $num_to_show := .Site.Params.related_content_limit | default 15 }} {{ $num_to_show := .Site.Params.related_content_limit | default 15 }}
{{ range first $num_to_show (where (where .Site.Pages ".Params.tags" "intersect" .Params.tags) "Permalink" "!=" .Permalink) }} {{ range first $num_to_show (where (where .Site.Pages ".Params.tags" "intersect" .Params.tags) "Permalink" "!=" .Permalink) }}
<li><a href="{{ .RelPermalink }}">{{ .Title }}</a></li> <li><a href="{{ .RelPermalink }}">{{ .Title }}</a></li>
{{ end }} {{ end }}
</ul> </ul>
<a class="back_to_top" href="#top">Back to top</a>
{{ end }} {{ end }}
{{ partial "footer.html" . }} {{ partial "footer.html" . }}

View file

@ -2,7 +2,7 @@
{{ partial "foot_custom.html" . }} {{ partial "foot_custom.html" . }}
{{ with .Site.Params.footer }} {{ with .Site.Params.footer }}
<hr/> <hr/>
<a href="#top">Back to top</a> <a class="back_to_top" href="#top">Back to top</a>
<br />{{ replace . "{Year}" now.Year | markdownify}} <br />{{ replace . "{Year}" now.Year | markdownify}}
{{ end }} {{ end }}
{{ if .GitInfo}} {{ if .GitInfo}}

View file

@ -0,0 +1,2 @@
<a class="back_to_top" href="#top">Back to top</a>
<hr />