Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/austingebauer/devise.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAustin Gebauer <agebauer@hashicorp.com>2020-07-06 01:56:43 +0300
committerAustin Gebauer <agebauer@hashicorp.com>2020-07-06 01:56:43 +0300
commita5b61129d191f46cd0bf7c25c2f54faba1cdc55c (patch)
tree91e0d2cc3416129a2d4da4860437f71a6392a392
parent5998ca3195dfc90a6635a948674f69b569116cb0 (diff)
fixes tags taxonomy template to behaves similar to categories
-rw-r--r--layouts/_default/list.html2
-rw-r--r--layouts/categories/list.html2
-rw-r--r--layouts/tag/list.html24
3 files changed, 18 insertions, 10 deletions
diff --git a/layouts/_default/list.html b/layouts/_default/list.html
index 4b64981..f6fd397 100644
--- a/layouts/_default/list.html
+++ b/layouts/_default/list.html
@@ -6,7 +6,7 @@
<time datetime="{{ .Date.Format "2006-01-02T15:04:05Z07:00" | safeHTML }}">
{{ .Date.Format "Jan 2 2006" }}
</time>
- <a href="{{ .URL | relURL }}">
+ <a href="{{ .RelPermalink }}">
{{ if .Draft }}DRAFT: {{end}}{{ .Title }}
</a>
</li>
diff --git a/layouts/categories/list.html b/layouts/categories/list.html
index 28ef6e3..a2b1ec0 100644
--- a/layouts/categories/list.html
+++ b/layouts/categories/list.html
@@ -10,7 +10,7 @@
{{ .Date.Format "Jan 2 2006" }}
</time>
{{ end }}
- <a href="{{ .URL | relURL }}">
+ <a href="{{ .RelPermalink }}">
{{ .Title }}
</a>
</li>
diff --git a/layouts/tag/list.html b/layouts/tag/list.html
index 8ae303d..030b4d7 100644
--- a/layouts/tag/list.html
+++ b/layouts/tag/list.html
@@ -1,12 +1,20 @@
{{ define "main" }}
- <div class="pl-sm-4 ml-sm-5">
- <h4>Tags</h4>
- <ul class="list-unstyled">
- {{ range $.Site.Taxonomies.tags.ByCount }}
+<div class="pl-sm-4 ml-sm-5">
+ <h4>{{ if eq .Name "Tags" }} Tags {{ else }} Tags - {{ .Name }} {{ end }}</h4>
+ {{ $outerName := .Name }}
+ <ul class="list-unstyled">
+ {{ range .Pages }}
<li>
- {{ .Count }} Articles - <a href="/tags{{ .Name | relURL }}">{{ .Name }}</a>
+ {{ if ne $outerName "Tags" }}
+ <time datetime="{{ .Date.Format "2006-01-02T15:04:05Z07:00" | safeHTML }}">
+ {{ .Date.Format "Jan 2 2006" }}
+ </time>
+ {{ end }}
+ <a href="{{ .RelPermalink }}">
+ {{ .Title }}
+ </a>
</li>
- {{ end }}
- </ul>
- </div>
+ {{ end }}
+ </ul>
+</div>
{{ end }}