diff --git a/i18n/de.yaml b/i18n/de.yaml index d5e5af1..872ac2a 100644 --- a/i18n/de.yaml +++ b/i18n/de.yaml @@ -1,5 +1,5 @@ # -# de.yaml 2020-06-19 +# de.yaml 2021-11-11 # about: @@ -20,6 +20,9 @@ articles-in-section: author: other: Autor +child-topics: + other: Unterbegriffe + contact: other: Kontakt @@ -41,6 +44,9 @@ next: pages: other: Seiten +parent-topics: + other: Oberbegriffe + posts: other: Artikel diff --git a/i18n/en.yaml b/i18n/en.yaml index b183cc4..0d79020 100644 --- a/i18n/en.yaml +++ b/i18n/en.yaml @@ -1,5 +1,5 @@ # -# en.yaml 2020-05-10 +# en.yaml 2021-11-11 # about: @@ -20,6 +20,9 @@ articles-in-section: author: other: Author +child-topics: + other: Child Topics + contact: other: Contact @@ -45,6 +48,9 @@ pages: posts: other: Posts +parent-topics: + other: Parent Topics + prev: other: Previous diff --git a/layouts/partials/sidebar.html b/layouts/partials/sidebar.html index 01483eb..6fd28e9 100644 --- a/layouts/partials/sidebar.html +++ b/layouts/partials/sidebar.html @@ -28,8 +28,8 @@
{{ range . -}} - {{ $page := $site.GetPage (printf "/topics/%s" .) }} - + {{- $page := $site.GetPage (printf "/topics/%s" .) -}} + {{ $page.Title }} {{- end }} diff --git a/layouts/taxonomy/list.html b/layouts/taxonomy/list.html index f4dbdc7..2254c0d 100644 --- a/layouts/taxonomy/list.html +++ b/layouts/taxonomy/list.html @@ -2,17 +2,57 @@
+ {{- $site := .Site -}} + {{- $parents := .Params.Topics -}} + {{- $children := (where + (where .Site.Pages "Section" "topics") + "Params.topics" "intersect" (slice .Name)) -}} + {{- $mainWidth := or (and $parents "col-md-8") "col-md-12" -}}
-
+ +
-
+

{{i18n .Data.Singular}}: {{ .Title }}

- {{ with .Content -}} -

{{ . }}

- {{- end }} +
+ {{ with .Content -}} +
{{ . }}
+ {{- end }} + {{ with $children -}} +

+ {{- i18n "child-topics" -}}: + {{ range . -}} + + {{ .Title }} + + {{- end }} +

+ {{- end }} +
+ + {{ with $parents -}} +
+
+
+

{{i18n "parent-topics"}}

+
+
+ {{ range . -}} + {{- $page := $site.GetPage (printf "/topics/%s" .) -}} + + {{ $page.Title }} + + + {{- end }} +
+
+
+ {{- end }} +