edited post

This commit is contained in:
Morgan 2023-10-29 15:27:41 +09:00
parent 6f09cb1174
commit 039d7763ef
2 changed files with 20 additions and 5 deletions

View File

@ -36,9 +36,11 @@
<li><a href="{{ .Permalink }}">{{ .LinkTitle }}</a></li> <li><a href="{{ .Permalink }}">{{ .LinkTitle }}</a></li>
{{- end }} {{- end }}
</ul> </ul>
{{- if (.Param "ShowPostNavLinks") }} <nav class="paginav">
{{- partial "post_nav_links.html" . }} <a href="/" onclick="window.history()">
{{- end }} Go Back
</a>
</nav>
<br/> <br/>
{{- if (and (and site.Params.ShowShareButtons (ne .Params.disableShare true)) false) }} {{- if (and (and site.Params.ShowShareButtons (ne .Params.disableShare true)) false) }}
{{- partial "share_icons.html" . -}} {{- partial "share_icons.html" . -}}

View File

@ -1,6 +1,19 @@
{{- $pages := where site.RegularPages "Type" "in" site.Params.mainSections }} {{- $pages := where site.RegularPages "Type" "in" site.Params.mainSections }}
{{- if and (gt (len $pages) 1) (in $pages . ) }}
<nav class="paginav"> <nav class="paginav">
<a href="/" onclick="window.history()"> {{- with $pages.Next . }}
Go Back <a class="prev" href="{{ .Permalink }}">
<span class="title">« {{ i18n "prev_page" }}</span>
<br>
<span>{{- .Name -}}</span>
</a> </a>
{{- end }}
{{- with $pages.Prev . }}
<a class="next" href="{{ .Permalink }}">
<span class="title">{{ i18n "next_page" }} »</span>
<br>
<span>{{- .Name -}}</span>
</a>
{{- end }}
</nav> </nav>
{{- end }}