aboutsummaryrefslogtreecommitdiff
path: root/themes/default/layouts/_default/home.authors.html
blob: 8e63d51a3caa07d7437e857125d883decd410cfb (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
27
28
29
30
31
32
33
34
35
36
37
38
39
{{ define "title" }}Authors — {{ end }}
{{ define "description" }}This page contains a list of all authors — {{ end }}
{{ define "styles" }}
<style>
  {{ partial "styles-navigator.html" (dict "Link" "/authors/") | safeCSS }}
</style>
{{ end }}

{{ define "middle" }}

  {{ partial "navigator-middle.html"
    (dict
      "Title"      "Authors"
      "Subtitle"   (partial "count-authors.html" .)
      "Icon"       "arrow-left"
      "IconLabel"  "Back"
      "Href"       "/"
      "Id"         "back"
      "Context"    .
    )
  }}

  {{ $authors := partial "function-authors-slice.html" . }}

  {{- range $author := shuffle $authors -}}
    {{ $data := index $.Site.Data $author | default "default" }}
    {{- $date := (index (first 1 (where $.Site.Pages.ByDate.Reverse "Section" $author)) 0).Date -}}
    {{- partial "author-card.html" (dict
        "Data" $data
        "Date" $date
      )
    -}}
  {{ end }}

{{ end }}

{{ define "right" }}
  {{- partial "navigator-right.html" . -}}
{{ end }}