summaryrefslogtreecommitdiffstats
path: root/layouts/index.html
blob: 7b54a46c7c31f07004298de1be3b04f6569a7482 (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
{{ define "main" }}
{{- with .Content }}
    <div class="introduction">
        {{ . }}
    </div>
    <hr>
    <div class="toc">
        {{/* TODO: Translate me */}}
        <h2>Latest Publications</h2>
        <ul class="texts">
            {{ range first 10 (where site.RegularPages "Section" "!=" "") }}
                <li class="text-title">
                    <a href="{{ .Permalink }}">{{ .Title }}</a>
                </li>
            {{ end }}
        </ul>
    </div>
{{- else }}
    {{ $paginator := .Paginate (where site.RegularPages "Type" "in" site.Params.main_sections) }}
    <div class="articles">
    {{- range $paginator.Pages }}
        {{- .Render "teaser" }}
    {{- end }}
    </div>
{{- end }}
{{- end }}