mirror of
https://github.com/davegallant/davegallant.github.io.git
synced 2025-08-07 00:58:13 +00:00
21 lines
806 B
HTML
21 lines
806 B
HTML
{{- $defaultConfig := .Site.Data.config.default.widgets.taxonomy_cloud -}}
|
|
{{- $configData := ( or .Site.Data.config.widgets.taxonomy_cloud $defaultConfig ) -}}
|
|
{{- $lang := .Site.Language.Lang -}}
|
|
{{- $config := ( ( index $configData $lang ) | default $configData ) -}}
|
|
|
|
{{- $shuffle := ( $config.shuffle | default true ) -}}
|
|
{{- $taxonomy := ( $config.taxonomy | default "tags" ) -}}
|
|
{{- $taxonomyData := ( .Site.GetPage $taxonomy ).Data -}}
|
|
{{- $taxonomySingular := $taxonomyData.Singular -}}
|
|
|
|
<section class='widget widget-taxonomy_cloud sep-after'>
|
|
<header>
|
|
<h4 class='title widget-title'>
|
|
{{- ( $config.title | default ( i18n $taxonomySingular 2 ) ) -}}
|
|
</h4>
|
|
</header>
|
|
|
|
{{ partial "extras/taxonomy_cloud" ( dict "Taxonomy" $taxonomy "Shuffle" $shuffle "Scope" . ) }}
|
|
|
|
</section>
|