1
0
Fork 0
mirror of https://git.sr.ht/~seirdy/seirdy.one synced 2024-09-19 20:02:10 +00:00

Fix next/prev links to be same-section

next/prev links for posts shouldn't navigate to non-post pages like
"about" and "resume".
This commit is contained in:
Rohan Kumar 2022-01-05 16:00:09 -08:00
parent 82036d0df9
commit db0d16e5b5
No known key found for this signature in database
GPG key ID: 1E892DB2A5F84479

View file

@ -24,9 +24,9 @@
</div> </div>
<hr> <hr>
<p> <p>
{{- if .Prev -}}<a href="{{ .Prev.Permalink }}">Previous</a>{{- end -}} {{- if .PrevInSection -}}<a href="{{ .PrevInSection.Permalink }}">Previous</a>{{- end -}}
{{- if and (.Prev) (.Next) }} · {{ end -}} {{- if and (.PrevInSection) (.NextInSection) }} · {{ end -}}
{{- if .Next -}}<a href="{{ .Next.Permalink }}">Next</a>{{- end -}} {{- if .NextInSection -}}<a href="{{ .NextInSection.Permalink }}">Next</a>{{- end -}}
</p> </p>
<hr> <hr>
<footer class="comment"> <footer class="comment">