all repos — archie @ dd1612c482e9fd993efe41f2783bbabed9b1e4cc

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><div class="description">
21						{{ if isset .Params "description" }}
22						{{ .Description }}
23						{{ else }}
24						{{ .Summary }}&hellip;
25						{{ end }}
26					</div>
27					<a href="{{ .RelPermalink }}">Read more ⟶</a>
28				</section>
29				{{ end }}
30				{{ template "partials/paginator.html" . }}
31			</main>
32			{{ partial "footer.html" . }}
33		</div>
34		
35	</body>
36</html>