layouts/taxonomy: fix hardcoded /blog link

Signed-off-by: Harsh Shandilya <me@msfjarvis.dev>
This commit is contained in:
Harsh Shandilya 2020-07-22 01:30:07 +05:30
parent 11b5e9709d
commit 2033a7fa9e
1 changed files with 26 additions and 0 deletions

26
layouts/taxonomy/tag.html Normal file
View File

@ -0,0 +1,26 @@
{{ define "styles" }}
{{ $.Scratch.Set "style_opts" (dict "src" "scss/pages/tags.scss" "dest" "css/tags.css") }}
{{ end }}
{{ define "main" }}
{{ $dateFormat := .Site.Params.dateFormat | default "Jan 2 2006" }}
<div class="post-list__container">
<div class="tag__header">
<a href="/posts">All posts</a><span class="separator">/</span>
<h1 class="tag__term">{{ .Title }}</h1>
</div>
<ul class="post-list">
{{ range .Data.Pages }}
<li class="post">
<div class="post__header">
<time class="post__date" datetime="{{ .Date }}">{{ .Date.Format $dateFormat }}</time>
<h2 class="post__title">
<a href="{{.RelPermalink}}">{{ .Title }}</a>
</h2>
</div>
</li>
{{ end }}
</ul>
</div>
{{ end }}