all repos — archie @ 5d283cd3a9d69d8ff3537d6fddb14e607f785d89

A minimal Hugo Theme

layouts/index.html (view raw)

 1<!DOCTYPE html>
 2<html>
 3	{{ partial "header.html" . }}
 4	<body>
 5		<div class="content">
 6			{{ partial "head.html" . }}
 7			
 8			<main class="list">
 9				<div class="site-description">
10					{{- if isset .Site.Params "subtitle" -}}
11					<p>{{ .Site.Params.Subtitle | markdownify }}</p>
12					{{- end -}}
13				</div>
14				{{ $pages := where .Site.RegularPages "Type" "in" .Site.Params.mainSections }}
15				{{ $paginator := .Paginate (where $pages "Params.hidden" "ne" true) }}
16				{{ range $paginator.Pages }}
17				<section class="list-item">
18					<h1 class="title"><a href="{{ .RelPermalink }}">{{.Title}}</a></h1>
19					<time>{{ dateFormat "Jan 2, 2006" .Date }}{{ if .Draft }} <span class="draft-label">DRAFT</span> {{ end }}</time>
20					<br>{{ template "partials/pagedescription.html" . }}
21				</section>
22				{{ end }}
23				{{ template "partials/paginator.html" . }}
24			</main>
25			{{ partial "footer.html" . }}
26		</div>
27		
28	</body>
29</html>