From fbd1afb7966d77103eb34228d2095a696e465830 Mon Sep 17 00:00:00 2001 From: mattmc3 Date: Sun, 14 Jul 2024 05:43:54 -0400 Subject: [PATCH] feat: Support custom sidebar limit param (#48) --- layouts/partials/sidebar.html | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/layouts/partials/sidebar.html b/layouts/partials/sidebar.html index 69c1193..df9e372 100644 --- a/layouts/partials/sidebar.html +++ b/layouts/partials/sidebar.html @@ -13,6 +13,7 @@ {{ range $taxonomy, $terms := site.Taxonomies }} {{ if $terms }} - {{ partial "block/sidebar_section.html" (dict "Context" $terms "Taxonomy" $taxonomy "Limit" 10) }} + {{- $limit := site.Params.sidebar.limit | default 10 -}} + {{ partial "block/sidebar_section.html" (dict "Context" $terms "Taxonomy" $taxonomy "Limit" $limit) }} {{ end }} {{ end }}