mirror of
https://github.com/BBaoVanC/bobatheme.git
synced 2024-12-22 12:13:19 -06:00
Add a duplicate series-box to the bottom of the page
This commit is contained in:
parent
8cadf8e735
commit
ac9ca6f97e
@ -7,25 +7,7 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
{{ partial "post-metadata/full.html" . }}
|
{{ partial "post-metadata/full.html" . }}
|
||||||
|
{{ partial "series-box.html" . }}
|
||||||
{{ with (.GetTerms "series") }}
|
|
||||||
{{ $series := slice }}
|
|
||||||
{{ range . }}
|
|
||||||
{{ $series = $series | append (printf `<a href="%s">%s</a>` .Permalink .LinkTitle) }}
|
|
||||||
{{ end }}
|
|
||||||
|
|
||||||
<div class="series-box">
|
|
||||||
{{ partial "icon.html" "info" }}
|
|
||||||
{{ if gt (len $series) 1 }}
|
|
||||||
This post is part of multiple series:
|
|
||||||
{{ else }}
|
|
||||||
This post is part of a series:
|
|
||||||
{{ end }}
|
|
||||||
|
|
||||||
{{ delimit $series ", " }}
|
|
||||||
</div>
|
|
||||||
{{ end }}
|
|
||||||
|
|
||||||
|
|
||||||
{{ if .Params.Toc }}
|
{{ if .Params.Toc }}
|
||||||
<div class="table-of-contents" aria-label="{{ i18n "aria_table_of_contents" }}">
|
<div class="table-of-contents" aria-label="{{ i18n "aria_table_of_contents" }}">
|
||||||
@ -80,6 +62,8 @@
|
|||||||
</div>
|
</div>
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
|
||||||
|
{{ partial "series-box.html" . }}
|
||||||
|
|
||||||
{{ $related := .Site.RegularPages.Related . | first 10 }}
|
{{ $related := .Site.RegularPages.Related . | first 10 }}
|
||||||
{{ with $related }}
|
{{ with $related }}
|
||||||
<div class="related">
|
<div class="related">
|
||||||
|
17
layouts/partials/series-box.html
Normal file
17
layouts/partials/series-box.html
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
{{ with (.GetTerms "series") }}
|
||||||
|
{{ $series := slice }}
|
||||||
|
{{ range . }}
|
||||||
|
{{ $series = $series | append (printf `<a href="%s">%s</a>` .Permalink .LinkTitle) }}
|
||||||
|
{{ end }}
|
||||||
|
|
||||||
|
<div class="series-box">
|
||||||
|
{{ partial "icon.html" "info" }}
|
||||||
|
{{ if gt (len $series) 1 }}
|
||||||
|
This post is part of multiple series:
|
||||||
|
{{ else }}
|
||||||
|
This post is part of a series:
|
||||||
|
{{ end }}
|
||||||
|
|
||||||
|
{{ delimit $series ", " }}
|
||||||
|
</div>
|
||||||
|
{{ end }}
|
Loading…
Reference in New Issue
Block a user