mirror of
https://github.com/TrezOne/congo-hindi-gujarati.git
synced 2026-07-19 09:03:02 -04:00
✨ Independent control of taxonomy display on list AND single pages
Sensible defaults: `.Params` will trump article and list `showTaxonomies` settings.
This commit is contained in:
@@ -52,6 +52,7 @@ enableCodeCopy = false
|
|||||||
showSummary = false
|
showSummary = false
|
||||||
showTableOfContents = false
|
showTableOfContents = false
|
||||||
groupByYear = true
|
groupByYear = true
|
||||||
|
showTaxonomies = false
|
||||||
|
|
||||||
[sitemap]
|
[sitemap]
|
||||||
excludedKinds = ["taxonomy", "term"]
|
excludedKinds = ["taxonomy", "term"]
|
||||||
|
|||||||
@@ -52,6 +52,7 @@ mainSections = ["samples"]
|
|||||||
showSummary = false
|
showSummary = false
|
||||||
showTableOfContents = true
|
showTableOfContents = true
|
||||||
groupByYear = false
|
groupByYear = false
|
||||||
|
showTaxonomies = false
|
||||||
|
|
||||||
[sitemap]
|
[sitemap]
|
||||||
excludedKinds = ["taxonomy", "term"]
|
excludedKinds = ["taxonomy", "term"]
|
||||||
|
|||||||
@@ -46,7 +46,10 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
{{/* Output taxonomies */}}
|
{{/* Output taxonomies */}}
|
||||||
{{ if .Params.showTaxonomies | default (.Site.Params.article.showTaxonomies | default false) }}
|
{{ if or
|
||||||
|
(and (ne $scope "single") (.Params.showTaxonomies | default (.Site.Params.list.showTaxonomies | default (.Site.Params.article.showTaxonomies | default false))))
|
||||||
|
(and (eq $scope "single") (.Params.showTaxonomies | default (.Site.Params.article.showTaxonomies | default false)))
|
||||||
|
}}
|
||||||
<div class="my-1 text-xs text-neutral-500 dark:text-neutral-400 ">
|
<div class="my-1 text-xs text-neutral-500 dark:text-neutral-400 ">
|
||||||
{{ range $taxonomy, $terms := .Site.Taxonomies }}
|
{{ range $taxonomy, $terms := .Site.Taxonomies }}
|
||||||
{{ if (gt (len ($context.GetTerms $taxonomy)) 0) }}
|
{{ if (gt (len ($context.GetTerms $taxonomy)) 0) }}
|
||||||
|
|||||||
Reference in New Issue
Block a user