diff options
| author | Francesco <tomaselli.fr@gmail.com> | 2024-05-11 22:48:26 +0200 | 
|---|---|---|
| committer | Francesco <tomaselli.fr@gmail.com> | 2024-05-11 22:48:26 +0200 | 
| commit | 1b40d37d7b35b6090a088ba049883dcf4c1e8dba (patch) | |
| tree | 40bf4111208f2bf8ee9a872fc80cd74476b6ba19 /layouts/_default | |
| parent | 43de5d69b894aec43f993743b2d03f4157952e15 (diff) | |
Breadcrumbs and tags
Diffstat (limited to 'layouts/_default')
| -rw-r--r-- | layouts/_default/single.html | 23 | 
1 files changed, 20 insertions, 3 deletions
| diff --git a/layouts/_default/single.html b/layouts/_default/single.html index 3eb46af..59ab477 100644 --- a/layouts/_default/single.html +++ b/layouts/_default/single.html @@ -6,7 +6,7 @@  <div {{ if .Param "autonumber" }} class="autonumber" {{ end }}> -  <div class=" single-intro-container"> +  <div class="single-intro-container">      {{/* Title and Summary */}} @@ -32,11 +32,28 @@    </div> -  {{/* {{ .Params.tags }} */}} +  {{ if .Param "showTags" }} + +  {{ $taxonomy := "tags" }} + +  {{ with .Param $taxonomy }} +  {{ $last := sub (. | len) 1 }} + +  <div class="single-tags"> +    {{ range $index, $tag := . }} +    {{ with $.Site.GetPage (printf "/%s/%s" $taxonomy $tag) -}} +    <span> +      <a href="{{ .Permalink }}">#{{ $tag | urlize }}</a> +    </span> +    {{ end }} +    {{ end }} +  </div> +  {{ end }} +  {{ end }}    {{/* Table of Content */}} -  {{if .Param "toc" }} +  {{ if .Param "toc" }}    <aside class="toc">      <p><strong>Table of contents</strong></p>      {{ .TableOfContents }} | 
