From 2f77558201f0fde08238a3431bf0d749ea0ed580 Mon Sep 17 00:00:00 2001 From: teldra Date: Tue, 12 Apr 2022 08:26:18 +0200 Subject: [PATCH] small fixes --- config/_default/config.toml | 3 ++- themes/buha/assets/css/article.css | 22 +++++++++---------- themes/buha/assets/css/big.css | 6 ++--- themes/buha/layouts/_default/baseof.html | 2 +- .../layouts/partials/l1/article_list.html | 10 ++++----- .../buha/layouts/partials/layout/article.html | 14 ++++++------ .../partials/snippets/article_metadata.html | 2 +- 7 files changed, 30 insertions(+), 29 deletions(-) diff --git a/config/_default/config.toml b/config/_default/config.toml index 968a1026..455f5070 100644 --- a/config/_default/config.toml +++ b/config/_default/config.toml @@ -1,6 +1,5 @@ baseURL = "https://bunteshaus.de/" languageCode = "de-DE" -defaultContentLanguage = "de" title = "Bunteshaus e.V." theme = "buha" enableGitInfo = true @@ -8,3 +7,5 @@ paginate = 5 description = "Buntes Haus e.V. - Soziokulturelles Zentrum in Celle - probably the friendliest place on earth" copyright = "bunteshaus.de" +defaultContentLanguageInSubdir = true +defaultContentLanguage = "de" diff --git a/themes/buha/assets/css/article.css b/themes/buha/assets/css/article.css index f6aa0f5b..767af74c 100644 --- a/themes/buha/assets/css/article.css +++ b/themes/buha/assets/css/article.css @@ -8,7 +8,7 @@ article { align-items: stretch; } -#articletitle h2 { +.articletitle h2 { margin-top: 0; } @@ -16,7 +16,7 @@ article a { text-decoration: underline; } -#article_list a { +.article_list a { text-decoration: none; } @@ -24,25 +24,25 @@ article p:first-child { margin-top: 0; } -article #readmore { +article .readmore { margin-top: 1rem; } -#articlemeta { +.articlemeta { margin-bottom: 1rem; margin-left: .3rem; } -#articletext img { +.articletext img { width: 80%; } -#articlemeta div:first-child { +.articlemeta div:first-child { font-size: medium; font-weight: bold; } -#articletext { +.articletext { margin-bottom: 1rem; /* These are technically the same, but use both */ overflow-wrap: break-word; @@ -78,13 +78,13 @@ article #readmore { flex: 0 0 100%; } -#articleinner { +.articleinner { display: flex; flex-direction: column-reverse; margin-left: .3rem; } -#article_footer { +.article_footer { margin-left: 1rem; margin-right: 1rem; margin-top: 0rem; @@ -96,12 +96,12 @@ article #readmore { color: var(--text-muted); } -#article_footer_foundations1 { +.article_footer_foundations1 { display: flex; height: 3rem; } -#article_footer_foundations2 { +.article_footer_foundations2 { display: flex; justify-content: space-between; margin-top: 1rem; diff --git a/themes/buha/assets/css/big.css b/themes/buha/assets/css/big.css index c2b1897c..a43d401f 100644 --- a/themes/buha/assets/css/big.css +++ b/themes/buha/assets/css/big.css @@ -28,13 +28,13 @@ article { margin-left: 1rem; } - #articlemeta { + .articlemeta { margin-bottom: 1.5rem; } - #articletext { + .articletext { margin-top: -0.4rem; } - #articleinner { + .articleinner { display: flex; flex-direction: row; } diff --git a/themes/buha/layouts/_default/baseof.html b/themes/buha/layouts/_default/baseof.html index 1d45d959..975e794a 100644 --- a/themes/buha/layouts/_default/baseof.html +++ b/themes/buha/layouts/_default/baseof.html @@ -1,5 +1,5 @@ - + {{- partial "snippets/head.html" . -}} {{ block "css" . -}}{{- end }} diff --git a/themes/buha/layouts/partials/l1/article_list.html b/themes/buha/layouts/partials/l1/article_list.html index 9f48ac7f..f7b63932 100644 --- a/themes/buha/layouts/partials/l1/article_list.html +++ b/themes/buha/layouts/partials/l1/article_list.html @@ -14,14 +14,14 @@ {{- if gt (len $pages) 0 -}} {{ if .title }}

{{ .title }}

{{ end }} {{- range first $amount $pages -}} -
- -
+
+ +

{{- .Title -}}

- -
+ +
{{ partial "layout/article" (dict "context" . "type" "list" "pic" "true") }}
diff --git a/themes/buha/layouts/partials/layout/article.html b/themes/buha/layouts/partials/layout/article.html index 5df6aac2..826f3ac1 100644 --- a/themes/buha/layouts/partials/layout/article.html +++ b/themes/buha/layouts/partials/layout/article.html @@ -15,7 +15,7 @@ {{ end }} {{ partial "snippets/article_metadata" $metas }} -
+
{{- if and (.context.Resources.ByType "image") (eq .pic "true") -}} {{ $resize := "500x" }} {{- $img := index (.context.Resources.ByType "image") 0 -}} @@ -26,17 +26,17 @@ {{- $resize = "500x" }} {{ end }} {{- $thumb = $img.Resize $resize }} -
+
{{ if and (ne .type "list") (.context.Resources.ByType "image") }}{{ end }} {{ if and (ne .type "list") (.context.Resources.ByType "image") }}{{ end }}
{{ end }} {{- if or .context.Content .context.Summary -}} -
+
{{ if eq .type "list" }}{{- .context.Summary -}}{{ else }}{{- .context.Content -}}{{ end }} {{ if and .context.Truncated (eq .type "list") }} -
{{- if i18n "readmore" -}}{{- i18n "readmore" -}}{{- else -}}{{- "readmore" -}}{{- end -}}..
+
{{- if i18n "readmore" -}}{{- i18n "readmore" -}}{{- else -}}{{- "readmore" -}}{{- end -}}..
{{ end }}
{{- end }} @@ -44,10 +44,10 @@ {{ define "pagefooter" }} {{ if and (eq .Kind "page") (or (eq .Section "news") (eq .Section "events") (eq .Section "about")) }} -
+