From 12ac6cf0e9874c6f52280e5b6f8362ff888bf18b Mon Sep 17 00:00:00 2001 From: teldra Date: Sun, 3 Apr 2022 01:27:41 +0200 Subject: [PATCH] small fixes --- themes/buha/layouts/_default/single.html | 62 +++---------------- .../partials/{ => orga}/generator.html | 0 .../partials/{ => orga}/nottranslated.html | 0 .../buha/layouts/partials/single/article.html | 48 ++++++++++++++ 4 files changed, 55 insertions(+), 55 deletions(-) rename themes/buha/layouts/partials/{ => orga}/generator.html (100%) rename themes/buha/layouts/partials/{ => orga}/nottranslated.html (100%) create mode 100644 themes/buha/layouts/partials/single/article.html diff --git a/themes/buha/layouts/_default/single.html b/themes/buha/layouts/_default/single.html index 351144a..f07bfe3 100644 --- a/themes/buha/layouts/_default/single.html +++ b/themes/buha/layouts/_default/single.html @@ -2,59 +2,11 @@ {{ end }} {{ define "main" }} -{{ if eq .Description "nottranslated" }} - {{ partial "nottranslated.html" . }} -{{ else if eq .Description "generator" }} - {{ partial "generator.html" . }} - -{{ else }} -
-

{{- .Title -}}

-
-
-
-
- {{ if and (ne .Params.when "") (ne .Params.when nil) }} -
{{ .Params.when }}
- {{ end }} - {{ if and (ne .Params.price "") (ne .Params.price nil) }} - {{ if eq .Params.price "free" }} -
Der Eintritt ist frei.
- {{ else }} -
Eintritt: {{ .Params.price }}
- {{ end }} - {{ end }} - {{ if and (ne .Params.register "") (ne .Params.register nil) }} -
Anmeldung unter {{ .Params.register | markdownify }} erwünscht
- {{ end }} - {{ if and (ne .Params.covid "") (ne .Params.covid nil) }} -
Es gilt die {{ .Params.covid }} Regel
- {{ end }} - {{ if and (ne .Params.contact "") (ne .Params.contact nil) }} -
Kontakt: {{ .Params.contact }}
- {{ end }} -
-
-
- {{- if .Resources.ByType "image" -}} - {{ if eq .Content "" }} -
- {{ else }} -
- {{ end }} - {{ range .Resources.ByType "image" }} - {{- $pic := . -}} - {{- $thumb := $pic.Resize "1024x" }} - - {{ end }} -
- {{- end }} -
- {{- .Content -}} -
-
-
-
-
-{{ end }} + {{ if eq .Description "nottranslated" }} + {{ partial "orga/nottranslated.html" . }} + {{ else if eq .Description "generator" }} + {{ partial "orga/generator.html" . }} + {{ else }} + {{ partial "single/article" . }} + {{ end }} {{ end }} diff --git a/themes/buha/layouts/partials/generator.html b/themes/buha/layouts/partials/orga/generator.html similarity index 100% rename from themes/buha/layouts/partials/generator.html rename to themes/buha/layouts/partials/orga/generator.html diff --git a/themes/buha/layouts/partials/nottranslated.html b/themes/buha/layouts/partials/orga/nottranslated.html similarity index 100% rename from themes/buha/layouts/partials/nottranslated.html rename to themes/buha/layouts/partials/orga/nottranslated.html diff --git a/themes/buha/layouts/partials/single/article.html b/themes/buha/layouts/partials/single/article.html new file mode 100644 index 0000000..aca4aeb --- /dev/null +++ b/themes/buha/layouts/partials/single/article.html @@ -0,0 +1,48 @@ +
+

{{- .Title -}}

+
+
+
+
+ {{ if and (ne .Params.when "") (ne .Params.when nil) }} +
{{ .Params.when }}
+ {{ end }} + {{ if and (ne .Params.price "") (ne .Params.price nil) }} + {{ if eq .Params.price "free" }} +
Der Eintritt ist frei.
+ {{ else }} +
Eintritt: {{ .Params.price }}
+ {{ end }} + {{ end }} + {{ if and (ne .Params.register "") (ne .Params.register nil) }} +
Anmeldung unter {{ .Params.register | markdownify }} erwünscht
+ {{ end }} + {{ if and (ne .Params.covid "") (ne .Params.covid nil) }} +
Es gilt die {{ .Params.covid }} Regel
+ {{ end }} + {{ if and (ne .Params.contact "") (ne .Params.contact nil) }} +
Kontakt: {{ .Params.contact }}
+ {{ end }} +
+
+
+ {{- if .Resources.ByType "image" -}} + {{ if eq .Content "" }} +
+ {{ else }} +
+ {{ end }} + {{ range .Resources.ByType "image" }} + {{- $pic := . -}} + {{- $thumb := $pic.Resize "1024x" }} + + {{ end }} +
+ {{- end }} +
+ {{- .Content -}} +
+
+
+
+
\ No newline at end of file