diff options
author | tdro <tdro@noreply.example.com> | 2023-11-21 15:42:01 -0500 |
---|---|---|
committer | tdro <tdro@noreply.example.com> | 2023-11-21 15:42:01 -0500 |
commit | 9a38bf790011a771a753ef6e01bf7c2b5d5635c8 (patch) | |
tree | dbc1b3a0ffba18259a69fea2893eb8de885e69ff /themes/default/layouts | |
parent | 6d7dec46271651785443321fc26344b355d8bd98 (diff) | |
download | canory-9a38bf790011a771a753ef6e01bf7c2b5d5635c8.tar.gz canory-9a38bf790011a771a753ef6e01bf7c2b5d5635c8.tar.bz2 canory-9a38bf790011a771a753ef6e01bf7c2b5d5635c8.zip |
themes/default/layouts/_default/index: Simplify
Sooner rather than later
Diffstat (limited to 'themes/default/layouts')
-rw-r--r-- | themes/default/layouts/_default/index.html | 12 | ||||
-rw-r--r-- | themes/default/layouts/partials/navigator-right.html | 22 |
2 files changed, 2 insertions, 32 deletions
diff --git a/themes/default/layouts/_default/index.html b/themes/default/layouts/_default/index.html index 2f97bbd..1de28d6 100644 --- a/themes/default/layouts/_default/index.html +++ b/themes/default/layouts/_default/index.html @@ -30,15 +30,5 @@ {{- end -}} {{- define "right" -}} - {{- $author := "Section" -}} - {{- partial "author-list.html" . -}} - - {{- range first 1 (where .Site.Pages $author .Site.Author.default.gallery) -}} - {{- partial "gallery.html" . -}} - {{- end -}} - - {{- range first 1 (where .Site.Pages $author .Site.Author.default.webring) -}} - {{- partial "following-list.html" . -}} - {{- partial "webring.html" . -}} - {{- end -}} + {{- partial "navigator-right.html" . -}} {{- end -}} diff --git a/themes/default/layouts/partials/navigator-right.html b/themes/default/layouts/partials/navigator-right.html index 4ad5d42..c2e6f4c 100644 --- a/themes/default/layouts/partials/navigator-right.html +++ b/themes/default/layouts/partials/navigator-right.html @@ -1,27 +1,7 @@ {{- partial "author-list.html" . -}} -{{- $author := "Section" -}} - -{{- if or - (eq .Page.Kind "page") - (eq .Page.Kind "section") --}} +{{- if (in (slice "page" "section") .Page.Kind) -}} {{- partial "gallery.html" . -}} {{- partial "following-list.html" . -}} - -{{- end -}} - -{{- if or - (eq .Page.Kind "page") - (eq .Page.Kind "section") --}} - {{- partial "webring.html" . -}} - -{{- else -}} - - {{- range first 1 (where .Site.Pages $author .Site.Author.default.webring) -}} - {{- partial "webring.html" . -}} - {{- end -}} - {{- end -}} |