blob: f1321b541de0615a3a15acb6f9e8633e81834f65 (
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
|
{{ if .Params.Author }}
{{ if $.Site.Taxonomies.authors }}
{{ errorf "[Unexpected Behaviour] Please use \"authors\" or remove \"author\" from the taxonomies." }}
{{ end }}
<h3 class="p-media-object__title">
{{ i18n "byAuthor" | default "By" }}
{{ partial "author-link.html" (dict "siteContext" $.Site "author" .Params.Author "isLast" true ) }}
</h3>
{{ else if .Params.Authors }}
{{ $len := len .Params.Authors}}
<h3 class="p-media-object__title">
{{ i18n "byAuthor" | default "By" }}
{{ range $i, $e := .Params.Authors }}
{{ partial "author-link.html" (dict "siteContext" $.Site "author" $e "isLast" (eq $i (sub $len 1))) }}
{{ end }}
</h3>
{{ end }}
|