blob: 80888928e3c24727316b71b370993e5877a35368 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
|
<!DOCTYPE html>
<html lang="{{ .Site.Language }}">
<head>
<meta charset="utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
<title>
{{- block "title" . -}}
{{ if .IsPage }}
{{ .Title }} - {{ .Site.Title }}
{{ else}}
{{ .Site.Title}}{{ end }}
{{- end -}}
</title>
{{ partial "head.html" . }}
</head>
{{- $.Scratch.Add "bodyClass" slice }}
{{- $config := .Site.Params.config }}
{{- if $config.layout }}
{{- $.Scratch.Add "bodyClass" $config.layout }}
{{- else }}
{{- $.Scratch.Add "bodyClass" "main-center" }}
{{- end }}
{{- with $config.skin }}
{{- $.Scratch.Add "bodyClass" . }}
{{- end}}
{{- if eq .Site.Params.sidebar "none"}}
{{- $.Scratch.Add "bodyClass" "no-sidebar" }}
{{- end }}
<!-- gen regular pages by mainSections -->
<!-- if exists, delete it -->
{{- if ($.Scratch.Get "pages") }}
{{- $.Scratch.Delete "pages"}}
{{- end}}
{{- if and (.Site.Params.mainSections) (ge (len .Site.Params.mainSections) 0) }}
{{- $.Scratch.Add "pages" (where .Site.RegularPages "Type" "in" .Site.Params.mainSections) }}
{{- else }}
{{- $.Scratch.Add "pages" (.Site.RegularPages) }}
{{- end }}
<body class="{{- delimit ( $.Scratch.Get "bodyClass" ) " " }}" itemscope itemtype="http://schema.org/WebPage">
{{- partial "header.html" .}}
{{- if and (.Site.Params.sidebar) (or (ne .Params.sidebar "none") (ne .Params.sidebar "custom"))}}
{{- partial "sidebar.html" . }}
{{end}}
{{ block "content" . }}{{ end }}
{{- partial "footer.html" . }}
{{- partial "script.html" . }}
</body>
</html>
|