25 lines
727 B
HTML
25 lines
727 B
HTML
{{ with .Param "categories" }}
|
|
{{ range $i, $category := . }}
|
|
{{ if eq $i 0 }}
|
|
{{ with $.Site.GetPage (printf "/%s/%s" "categories" $category) }}
|
|
{{ $iconDictionary := dict
|
|
"video" "video"
|
|
"paper" "book"
|
|
"poster" "presentation"
|
|
"thesis" "graduation-cap"
|
|
"presentation" "podium"
|
|
"web" "globe"
|
|
"blog" "block-quote"
|
|
}}
|
|
{{ $categoryIcon := index $iconDictionary $category }}
|
|
<a
|
|
class="category-button"
|
|
href="{{ .RelPermalink }}"
|
|
title="{{ humanize $category }}"
|
|
>
|
|
{{- partial "fa.html" $categoryIcon -}}
|
|
</a>
|
|
{{ end }}
|
|
{{ end }}
|
|
{{ end }}
|
|
{{ end }}
|