Umstellung der Meta-Daten in Partials
This commit is contained in:
parent
be11de4217
commit
1e520f3f39
9 changed files with 22 additions and 40 deletions
|
@ -28,7 +28,7 @@
|
||||||
{{ range $pag.Pages }}
|
{{ range $pag.Pages }}
|
||||||
<article class="blog-post">
|
<article class="blog-post">
|
||||||
<h3 class="blog-post-title_ mb-1"><a href="{{ .RelPermalink }}">{{ .Title }}</a></h3>
|
<h3 class="blog-post-title_ mb-1"><a href="{{ .RelPermalink }}">{{ .Title }}</a></h3>
|
||||||
<p class="blog-post-meta">{{ partial "metadata.html" . }}</p>
|
<p class="blog-post-meta">{{ partial "meta/data.html" . }}</p>
|
||||||
<p>{{ .Summary }}</p>
|
<p>{{ .Summary }}</p>
|
||||||
</article>
|
</article>
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
|
|
@ -4,11 +4,11 @@
|
||||||
<div class="columns is-centered">
|
<div class="columns is-centered">
|
||||||
<div class="column">
|
<div class="column">
|
||||||
<h1 class="title is-1">{{ .Title }}</h1>
|
<h1 class="title is-1">{{ .Title }}</h1>
|
||||||
<div class="blog-post-meta">{{ partial "metadata.html" . }}</div>
|
<div class="blog-post-meta">{{ partial "meta/data.html" . }}</div>
|
||||||
<div class="content">
|
<div class="content">
|
||||||
{{ .Content }}
|
{{ .Content }}
|
||||||
</div>
|
</div>
|
||||||
<div class="blog-post-meta mt-5">{{ partial "metafooter.html" . }}</div>
|
<div class="blog-post-meta mt-5">{{ partial "meta/footer.html" . }}</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</article>
|
</article>
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
{{ range .Paginator.Pages.ByTitle }}
|
{{ range .Paginator.Pages.ByTitle }}
|
||||||
<article class="blog-post">
|
<article class="blog-post">
|
||||||
<h3 class="blog-post-title_ mb-1"><a href="{{ .RelPermalink }}">{{ .Title }}</a></h3>
|
<h3 class="blog-post-title_ mb-1"><a href="{{ .RelPermalink }}">{{ .Title }}</a></h3>
|
||||||
<!--p class="blog-post-meta">{{ partial "metadata.html" . }}</p-->
|
<!--p class="blog-post-meta">{{ partial "meta/data.html" . }}</p-->
|
||||||
<p>{{ .Summary }}</p>
|
<p>{{ .Summary }}</p>
|
||||||
</article>
|
</article>
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
|
|
@ -4,11 +4,11 @@
|
||||||
<div class="columns is-centered">
|
<div class="columns is-centered">
|
||||||
<div class="column">
|
<div class="column">
|
||||||
<h1 class="title is-1">{{ .Title }}</h1>
|
<h1 class="title is-1">{{ .Title }}</h1>
|
||||||
<div class="blog-post-meta">{{ partial "metadata.html" . }}</div>
|
<div class="blog-post-meta">{{ partial "meta/data.html" . }}</div>
|
||||||
<div class="content">
|
<div class="content">
|
||||||
{{ .Content }}
|
{{ .Content }}
|
||||||
</div>
|
</div>
|
||||||
<div class="blog-post-meta mt-5">{{ partial "metafooter.html" . }}</div>
|
<div class="blog-post-meta mt-5">{{ partial "meta/footer_skill.html" . }}</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</article>
|
</article>
|
||||||
|
|
5
layouts/partials/meta/footer.html
Normal file
5
layouts/partials/meta/footer.html
Normal file
|
@ -0,0 +1,5 @@
|
||||||
|
{{ $tagsIdent := .Site.Params.Blog.Tags | default "tags" }}
|
||||||
|
{{- partial "taxonomy/metatag.html" (dict "Params" .Params "Ident" $tagsIdent "Feather" "tag") -}}
|
||||||
|
|
||||||
|
{{ $catIdent := .Site.Params.Blog.Categories | default "categories" }}
|
||||||
|
{{- partial "taxonomy/metatag.html" (dict "Params" .Params "Ident" $catIdent "Feather" "award") -}}
|
2
layouts/partials/meta/footer_skill.html
Normal file
2
layouts/partials/meta/footer_skill.html
Normal file
|
@ -0,0 +1,2 @@
|
||||||
|
{{ $skillIdent := .Site.Params.KnowHow.Skills | default "skills" }}
|
||||||
|
{{- partial "taxonomy/metatag.html" (dict "Params" .Params "Ident" $skillIdent "Feather" "code") -}}
|
|
@ -1,34 +0,0 @@
|
||||||
{{/* TODO Sollte mal aufgeteilt werden*/}}
|
|
||||||
|
|
||||||
{{ $tagsIdent := .Site.Params.Blog.Tags | default "tags" }}
|
|
||||||
{{ with (index .Params $tagsIdent) }}
|
|
||||||
<i data-feather="tag"></i>
|
|
||||||
<i class="bi bi-tag"></i> <!-- TODO: umstellen auf bootstrap-icons??? -->
|
|
||||||
{{ range . }}
|
|
||||||
{{ $href := print (absURL (printf "%s/" $tagsIdent)) (urlize .) }}
|
|
||||||
<a class="btn btn-sm btn-outline-dark tag-btn" href="{{ $href | relURL }}">{{ . }}</a>
|
|
||||||
{{ end }}
|
|
||||||
<i class="mx-2"></i>
|
|
||||||
{{ end }}
|
|
||||||
|
|
||||||
{{ $catIdent := .Site.Params.Blog.Categories | default "categories" }}
|
|
||||||
{{ with (index .Params $catIdent) }}
|
|
||||||
<!-- list -->
|
|
||||||
<i data-feather="award"></i>
|
|
||||||
{{ range . }}
|
|
||||||
{{ $href := print (absURL (printf "%s/" $catIdent)) (urlize .) }}
|
|
||||||
<a class="btn btn-sm btn-outline-dark tag-btn" href="{{ $href | relURL }}">{{ . }}</a>
|
|
||||||
{{ end }}
|
|
||||||
<i class="mx-2"></i>
|
|
||||||
{{ end }}
|
|
||||||
|
|
||||||
{{ $skillIdent := .Site.Params.KnowHow.Skills | default "skills" }}
|
|
||||||
{{ with (index .Params $skillIdent) }}
|
|
||||||
<!-- list -->
|
|
||||||
<i data-feather="code"></i>
|
|
||||||
{{ range . }}
|
|
||||||
{{ $href := print (absURL (printf "%s/" $skillIdent)) (urlize .) }}
|
|
||||||
<a class="btn btn-sm btn-outline-dark tag-btn" href="{{ $href | relURL }}">{{ . }}</a>
|
|
||||||
{{ end }}
|
|
||||||
<i class="mx-2"></i>
|
|
||||||
{{ end }}
|
|
9
layouts/partials/taxonomy/metatag.html
Normal file
9
layouts/partials/taxonomy/metatag.html
Normal file
|
@ -0,0 +1,9 @@
|
||||||
|
{{ with (index .Params .Ident) }}
|
||||||
|
<i data-feather="{{ $.Feather }}"></i>
|
||||||
|
<i class="bi bi-tag"></i> <!-- TODO: umstellen auf bootstrap-icons??? -->
|
||||||
|
{{ range . }}
|
||||||
|
{{ $href := print (absURL (printf "%s/" $.Ident)) (urlize .) }}
|
||||||
|
<a class="btn btn-sm btn-outline-dark tag-btn" href="{{ $href | relURL }}">{{ . }}</a>
|
||||||
|
{{ end }}
|
||||||
|
<i class="mx-2"></i>
|
||||||
|
{{ end }}
|
Loading…
Reference in a new issue