First try at a HUGO theme for phiax.nl
This commit is contained in:
commit
4d1ddd22ed
13 changed files with 342 additions and 0 deletions
18
layouts/_partials/terms.html
Normal file
18
layouts/_partials/terms.html
Normal file
|
|
@ -0,0 +1,18 @@
|
|||
{{- /*
|
||||
For a given taxonomy, renders a list of terms assigned to the page.
|
||||
|
||||
@context {page} page The current page.
|
||||
@context {string} taxonomy The taxonomy.
|
||||
|
||||
@example: {{ partial "terms.html" (dict "taxonomy" "tags" "page" .) }}
|
||||
*/}}
|
||||
|
||||
{{- $page := .page }}
|
||||
{{- $taxonomy := .taxonomy }}
|
||||
|
||||
{{- with $page.GetTerms $taxonomy }}
|
||||
{{- $label := (index . 0).Parent.LinkTitle }}
|
||||
{{- range . }}
|
||||
<div class="article-end-ribbon">Tags: <a href="{{ .RelPermalink }}">{{ .LinkTitle }}</a></div>
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
Loading…
Add table
Add a link
Reference in a new issue