diff options
Diffstat (limited to 'layouts/_default/terms.html')
-rw-r--r-- | layouts/_default/terms.html | 32 |
1 files changed, 16 insertions, 16 deletions
diff --git a/layouts/_default/terms.html b/layouts/_default/terms.html index 04b98f8..08498f6 100644 --- a/layouts/_default/terms.html +++ b/layouts/_default/terms.html @@ -1,44 +1,44 @@ -{{ define "title" }}{{ T .Data.Plural }} - {{ .Site.Title }}{{ end }} +{{- define "title" }}{{ T .Data.Plural }} - {{ .Site.Title }}{{ end -}} -{{ define "content" }} +{{- define "content" -}} {{ $name := .Data.Plural -}} {{ $terms := .Data.Terms.ByCount -}} {{ $length := len $terms -}} - {{ if eq $name "categories" }} + {{ if eq $name "categories" -}} <div class="categories"> <div class="categories-title"> - {{ if eq $length 0 }} + {{ if eq $length 0 -}} {{ T "zeroCategoryCounter" }} - {{ else }} + {{- else -}} {{ T "categoryCounter" $length }} - {{ end }} + {{- end }} </div> <div class="categories-tags"> - {{ range $key, $value := $terms }} + {{ range $key, $value := $terms -}} <a class="category-link" href="{{ $name | relLangURL }}/{{ $value.Term | urlize }}/"> {{ $value.Term }} <span class="category-count">{{ len $value.Pages }}</span> </a> - {{ end }} + {{ end -}} </div> </div> - {{ else if eq $name "tags" }} + {{- else if eq $name "tags" -}} <div class="tag-cloud"> <div class="tag-cloud-title"> - {{ if eq $length 0 }} + {{ if eq $length 0 -}} {{ T "zeroTagCounter" }} - {{ else }} + {{- else -}} {{ T "tagCounter" $length }} - {{ end }} + {{- end }} </div> <div class="tag-cloud-tags"> - {{ range $key, $value := $terms }} + {{- range $key, $value := $terms }} <a href="{{ $name | relLangURL }}/{{ $value.Term | urlize }}/"> {{ $value.Term }} <span class="tag-count">{{ len $value.Pages }}</span> </a> - {{ end }} + {{ end -}} </div> </div> - {{ end }} -{{ end }}
\ No newline at end of file + {{- end }} +{{- end }}
\ No newline at end of file |