2022-02-26 17:45:25 -05:00
|
|
|
{{- $scope := default "homepage" .Scope -}}
|
|
|
|
{{- $context := .Context -}}
|
|
|
|
{{- with (index .Context.Site.Params.widgets $scope) -}}
|
2020-08-22 07:20:08 -04:00
|
|
|
<aside class="sidebar right-sidebar sticky">
|
2022-02-26 17:45:25 -05:00
|
|
|
{{ range $widget := . }}
|
|
|
|
{{ if templates.Exists (printf "partials/widget/%s.html" .type) }}
|
|
|
|
{{ partial (printf "widget/%s" .type) (dict "Context" $context "Params" .params) }}
|
|
|
|
{{ else }}
|
|
|
|
{{ warnf "Widget %s not found" .type }}
|
|
|
|
{{ end }}
|
2020-08-22 07:20:08 -04:00
|
|
|
{{ end }}
|
|
|
|
</aside>
|
|
|
|
{{ end }}
|