{{ partial "header.html" . }} {{ partial "navbar.html" . }} {{ if .IsHome }} {{ .Scratch.Set "section" "home" }} {{ else }} {{ .Scratch.Set "section" .Section }} {{ end }} {{ $section := .Scratch.Get "section" }} {{ range $index, $page := where (where .Data.Pages "Section" $section) ".Params.active" "!=" false }} {{ $params := dict "root" $ "page" $page }} {{ $widget := printf "widgets/%s.html" ( or $page.Params.widget "custom" ) }} {{ if eq $page.Params.widget "hero" }} {{ partial $widget $params }} {{ else }} {{ partial $widget $params }} {{ end }} {{ end }} {{ partial "footer_container.html" . }} {{ partial "footer.html" . }}