aboutsummaryrefslogtreecommitdiff
path: root/layouts/_default/single.html
blob: a00bc3b8d4c9a79d3e50334cd570393866d292c0 (plain) (blame)
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
{{ define "head" }}
	<style>
	.bg-img {background-image: url('
	{{- if .Params.featuredImg -}}
		{{.Params.featuredImg | absURL}}
	{{- else if .Params.images -}}
		{{- range first 1 .Params.images -}}
		{{. | absURL}}
		{{- end -}}
	{{- end -}}
	');}
	</style>
{{ end }}

{{ define "header" }}
{{ partial "header.html" . }}
{{ end }}

{{ define "main" }}
	{{- if (or .Params.images .Params.featuredImg) }}
	<div class="bg-img"></div>
	{{- end }}
	<main class="site-main section-inner thin animated fadeIn faster">
		<h1>{{ .Title }}</h1>
		<div class="content">
			{{ .Content }}
		</div>
		{{- if .Params.comments }}
		<div id="comments" class="thin">
			{{ partial "comments.html" . }}
		</div>
		{{- end }}
	</main>
{{ end }}

{{ define "footer" }}
{{ partialCached "footer.html" . }}
{{ end }}