fix: some title case bugs for section page and list page (#251)
This commit is contained in:
@@ -1,12 +1,12 @@
|
||||
{{- define "title" }}
|
||||
{{- T .Section | default .Section | printf (T "allSome") }} | {{ .Site.Title -}}
|
||||
{{- .Title | default (T .Section) | default .Section | printf (T "allSome") }} | {{ .Site.Title -}}
|
||||
{{- end -}}
|
||||
|
||||
{{- define "content" -}}
|
||||
<div class="page archive">
|
||||
{{- /* Title */ -}}
|
||||
<h2 class="single-title animated pulse faster">
|
||||
{{- T .Section | default .Section | humanize | printf (T "allSome") -}}
|
||||
{{- .Title | default (T .Section) | default .Section | printf (T "allSome") -}}
|
||||
</h2>
|
||||
|
||||
{{- /* Paginate */ -}}
|
||||
|
||||
@@ -33,8 +33,9 @@
|
||||
{{- T "included" -}}
|
||||
{{- range $index, $value := . -}}
|
||||
{{- if gt $index 0 }} {{ end -}}
|
||||
<a href="{{ `/categories/` | relLangURL }}{{ urlize $value }}">
|
||||
<i class="far fa-folder fa-fw"></i>{{ $value | humanize }}
|
||||
{{- $category := printf "/categories/%s" $value | $.Site.GetPage -}}
|
||||
<a href="{{ $category.RelPermalink }}">
|
||||
<i class="far fa-folder fa-fw"></i>{{ $category.Title }}
|
||||
</a>
|
||||
{{- end -}}
|
||||
</span>
|
||||
@@ -58,7 +59,8 @@
|
||||
<i class="fas fa-tags fa-fw"></i>
|
||||
{{- range $index, $value := . -}}
|
||||
{{- if gt $index 0 }}, {{ end -}}
|
||||
<a href="{{ `/tags/` | relLangURL }}{{ urlize $value }}">{{ $value }}</a>
|
||||
{{- $tag := printf "/tags/%s" $value | $.Site.GetPage -}}
|
||||
<a href="{{ $tag.RelPermalink }}">{{ $tag.Title }}</a>
|
||||
{{- end -}}
|
||||
</div>
|
||||
{{- end -}}
|
||||
|
||||
Reference in New Issue
Block a user