File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1- {{ partial "widget/taxonomy" (dict
2- "Context" .Context
3- "Params" (dict
4- "taxonomy" "categories"
5- "title" (T "widget.categoriesCloud.title")
6- "icon" "categories"
7- )
8- ) }}
1+ {{ $params := merge (dict "taxonomy" "categories" "title" (T "widget.categoriesCloud.title") "icon" "categories") .Params }}
2+ {{ partial "widget/taxonomy" (dict "Context" .Context "Params" $params) }}
Original file line number Diff line number Diff line change 1- {{ partial "widget/taxonomy" (dict
2- "Context" .Context
3- "Params" (dict
4- "taxonomy" "tags"
5- "title" (T "widget.tagCloud.title")
6- "icon" "tag"
7- )
8- ) }}
1+ {{ $params := merge (dict "taxonomy" "tags" "title" (T "widget.tagCloud.title") "icon" "tag") .Params }}
2+ {{ partial "widget/taxonomy" (dict "Context" .Context "Params" $params) }}
Original file line number Diff line number Diff line change 88
99{{- $limit := default 10 .Params.limit -}}
1010{{- $icon := default .Params.taxonomy .Params.icon -}}
11+ {{- $showLink := default false .Params.showLink -}}
1112
1213< section class ="widget tagCloud ">
1314 < div class ="widget-icon ">
1415 {{ partial "helper/icon" $icon }}
1516 </ div >
16- < h2 class ="widget-title section-title "> {{ default .Params.title $taxonomyPage.Title }}</ h2 >
17+ < h2 class ="widget-title section-title ">
18+ {{ if $showLink }}
19+ < a href ="{{ $taxonomyPage.RelPermalink }} ">
20+ {{ default .Params.title $taxonomyPage.Title }}
21+ </ a >
22+ {{ else }}
23+ {{ default .Params.title $taxonomyPage.Title }}
24+ {{ end }}
25+ </ h2 >
1726
1827 < div class ="tagCloud-tags ">
1928 {{ range first $limit $taxonomy.ByCount }}
You can’t perform that action at this time.
0 commit comments