feat: same container width on all pages (#534)
This commit is contained in:
parent
8f5164b5b9
commit
07e1b856b0
@ -6,7 +6,14 @@
|
|||||||
</head>
|
</head>
|
||||||
<body class="{{ block `body-class` . }}{{ end }}">
|
<body class="{{ block `body-class` . }}{{ end }}">
|
||||||
{{- partial "head/colorScheme" . -}}
|
{{- partial "head/colorScheme" . -}}
|
||||||
{{- $hasWidget := default (gt (len .Site.Params.widgets.homepage) 0) (.Scratch.Get "hasWidget") -}}
|
|
||||||
|
{{/* The container is wider when there's any activated widget */}}
|
||||||
|
{{- $hasWidget := false -}}
|
||||||
|
{{- range .Site.Params.widgets -}}
|
||||||
|
{{- if gt (len .) 0 -}}
|
||||||
|
{{- $hasWidget = true -}}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
<div class="container main-container flex on-phone--column {{ if $hasWidget }}extended{{ else }}compact{{ end }}">
|
<div class="container main-container flex on-phone--column {{ if $hasWidget }}extended{{ else }}compact{{ end }}">
|
||||||
{{- block "left-sidebar" . -}}
|
{{- block "left-sidebar" . -}}
|
||||||
{{ partial "sidebar/left.html" . }}
|
{{ partial "sidebar/left.html" . }}
|
||||||
|
Loading…
Reference in New Issue
Block a user