diff options
Diffstat (limited to 'layouts')
| -rw-r--r-- | layouts/_default/list.html | 1 | ||||
| -rw-r--r-- | layouts/_default/term.html | 1 | ||||
| -rw-r--r-- | layouts/_default/terms.html | 29 | ||||
| -rw-r--r-- | layouts/index.json | 1 | ||||
| -rw-r--r-- | layouts/partials/templates/opengraph.html | 4 |
5 files changed, 31 insertions, 5 deletions
diff --git a/layouts/_default/list.html b/layouts/_default/list.html index 85e8a43..2fd13ba 100644 --- a/layouts/_default/list.html +++ b/layouts/_default/list.html @@ -1,5 +1,6 @@ {{ define "main" }} +{{/* This template is for list of all publications in a Section */}} <div class="articles"> {{ with .Title }}<h1 class="page-title">{{ . }}</h1>{{ end }} diff --git a/layouts/_default/term.html b/layouts/_default/term.html index 03430d4..6450775 100644 --- a/layouts/_default/term.html +++ b/layouts/_default/term.html @@ -1,5 +1,6 @@ {{ define "main" }} +{{/* This template is for list of all publications in a Term (for example a Tag) */}} <div class="articles"> <h1 class="page-title"> {{ with .Title }}{{ i18n "publications_tagged" . }}{{ end }} diff --git a/layouts/_default/terms.html b/layouts/_default/terms.html new file mode 100644 index 0000000..20e8f29 --- /dev/null +++ b/layouts/_default/terms.html @@ -0,0 +1,29 @@ +{{ define "main" }} + +{{/* This template is for list of all Tags */}} +<div class="articles"> + <h1 class="page-title"> + {{ with .Title }} + {{ i18n "tag_cloud" . }} + {{ end }} + </h1> + + {{ $tags := site.Taxonomies.tags.ByCount }} + + <div class="tags-wrapper"> + <ul class="tags-cloud"> + {{ range uniq $tags }} + {{ if .Term }} + {{ $tagURL := printf "tags/%s" .Term | relURL }} + <li class="tag"> + <a class="tag-link" href="{{ $tagURL }}"> + {{ .Term }} ({{ .Count }}) + </a> + </li> + {{ end }} + {{ end }} + </ul> + </div> +</div> + +{{ end }} diff --git a/layouts/index.json b/layouts/index.json index a71d1e6..2b8aa25 100644 --- a/layouts/index.json +++ b/layouts/index.json @@ -31,7 +31,6 @@ "type" $page.Type "section" $page.Section "content" $page.Plain - "categories" ($page.Params.categories | default slice) "tags" ($page.Params.tags | default slice) ) -}} diff --git a/layouts/partials/templates/opengraph.html b/layouts/partials/templates/opengraph.html index f78f8e8..4f44694 100644 --- a/layouts/partials/templates/opengraph.html +++ b/layouts/partials/templates/opengraph.html @@ -30,10 +30,6 @@ <meta property="article:expiration_time" content="{{ .ExpiryDate.Format "2006-01-02T15:04:05" }}"> {{- end -}} - {{- with .Params.categories -}}{{- range $v := . }} - <meta property="article:section" content="{{ $v }}"> - {{- end -}}{{- end -}} - {{- with .Params.tags -}}{{- range $v := . }} <meta property="article:tag" content="{{ $v }}"> {{- end -}}{{- end -}} |
