fix(widget): Hugo 0.55 broke display of taxonomy term names (e.g. tags)

Prior to this update, Hugo began displaying urlized tags like
`deep-learning` rather than `Deep Learning` in the Tag Cloud widget and
the list_tags/categories shortcodes.

Fix #1072
This commit is contained in:
George Cushen committed 2019-05-07 22:55:02 +01:00
1 parent c88f90bd5d
commit 507523aeb9
3 files changed
+5 -5

No files matched your search

+1 -1
View File
@@ -24,7 +24,7 @@
{{ $tagCount := len $taxonomy.Pages }}
{{ $weight := div (sub (math.Log $tagCount) (math.Log $min)) (sub (math.Log $max) (math.Log $min)) }}
{{ $fontSize := add $fontSmall (mul (sub $fontBig $fontSmall) $weight) }}
<a href="{{ .Page.RelPermalink }}" style="font-size:{{ $fontSize }}rem">{{ $name }}</a>
<a href="{{ .Page.RelPermalink }}" style="font-size:{{ $fontSize }}rem">{{ .Page.Title }}</a>
{{ end }}
</div>
{{ end }}
+2 -2
View File
@@ -1,5 +1,5 @@
<ul class="list-unstyled">
{{ range (site.GetPage "taxonomyTerm" "categories").Pages }}
<li><a href="{{.RelPermalink}}">{{.Title}}</a></li>
{{ range site.Taxonomies.categories }}
<li><a href="{{.Page.RelPermalink}}">{{.Page.Title}}</a></li>
{{ end }}
</ul>
+2 -2
View File
@@ -1,5 +1,5 @@
<ul class="list-unstyled">
{{ range (site.GetPage "taxonomyTerm" "tags").Pages }}
<li><a href="{{.RelPermalink}}">{{.Title}}</a></li>
{{ range site.Taxonomies.tags }}
<li><a href="{{.Page.RelPermalink}}">{{.Page.Title}}</a></li>
{{ end }}
</ul>