{{ define "main" }}
<main>
	<article>
		<h2>Archive</h2>
		{{ $pages := where .Site.RegularPages "Type" "in" .Site.Params.mainSections }}
		{{ range $pages.GroupByDate "2006" }}
		<div class="archive-year">
			<h3>{{ .Key }}</h3>
			<ul class="archive-list">
			{{ range .Pages.ByDate.Reverse }}
				<li>
					<span class="archive-date">{{ .Date.Format "01-02" }}</span>
					<a href="{{ .RelPermalink }}">{{ .Title }}</a>
				</li>
			{{ end }}
			</ul>
		</div>
		{{ end }}
	</article>
</main>
{{ end }}
