diff --git a/content/news/2022-04-04-Konzert-Katzengejammer/banner_2.jpeg b/content/news/2022-04-04-Konzert-Katzengejammer/banner_2.jpeg
index 145eab3..9fde3c4 100644
Binary files a/content/news/2022-04-04-Konzert-Katzengejammer/banner_2.jpeg and b/content/news/2022-04-04-Konzert-Katzengejammer/banner_2.jpeg differ
diff --git a/content/news/foodsaving/banner.png b/content/news/foodsaving/banner.png
index a898c6a..48ee115 100644
Binary files a/content/news/foodsaving/banner.png and b/content/news/foodsaving/banner.png differ
diff --git a/themes/buha/assets/scss/banner.scss b/themes/buha/assets/scss/banner.scss
index 23f1332..e62b1ac 100644
--- a/themes/buha/assets/scss/banner.scss
+++ b/themes/buha/assets/scss/banner.scss
@@ -1,11 +1,11 @@
.banner {
- height: calc(1em * 33vh);
+ min-height: calc(100vw / 3.5);
display: flex;
align-items: center;
font-size: 115%;
//box-shadow: inset 0px -11px 8px -10px #444;
background-repeat: no-repeat;
- background-size: cover;
+ background-size: 100%;
background-position: top center;
flex-direction: column;
align-content: center;
diff --git a/themes/buha/layouts/partials/layout/gen_list.html b/themes/buha/layouts/partials/layout/gen_list.html
index fc23fc0..6d771df 100644
--- a/themes/buha/layouts/partials/layout/gen_list.html
+++ b/themes/buha/layouts/partials/layout/gen_list.html
@@ -37,26 +37,23 @@
{{ if $title }}{{ else }}{{ end }}
{{ with .Resources.GetMatch $banner }}
{{ if eq hugo.Environment "development" }}
- {{ $good_ratio := "1.7777777777777777"}}
+ {{ $good_w := "1920"}}
+ {{ $good_h := "550"}}
{{ $ratio := div (float .Width) (float .Height) }}
- {{ if lt $ratio $good_ratio }}
- Ratio: {{ $ratio }}: not a good ratio, better around {{ $good_ratio }} (lower the hight in relation to the width)
- {{ else if gt $ratio $good_ratio }}
- Ratio: {{ $ratio }}: not a good ratio, better around {{ $good_ratio }}(higher)
+ {{ if lt (int .Width) $good_w }}
+ Width: {{ .Width }}px: too small, better {{ $good_w -}}px in width
+ {{ else if gt (int .Width) $good_w }}
+ Width: {{ .Width }}px: too big, better {{ $good_w -}}px in width
{{ end }}
- {{ if lt (int .Width) "1920" }}
- Width: {{ .Width }}px: too small, better 1920px in width
- {{ else if gt (int .Width) "1920" }}
- Width: {{ .Width }}px: too big, better 1920px in width
- {{ end }}
- {{ if lt (int .Height) "1080" }}
- Height: {{ .Height }}px: too small, better 1080px in height
- {{ else if gt (int .Height) "1080" }}
- Height: {{ .Height }}px: too big, better 1080px in height
+ {{ if lt (int .Height) $good_h }}
+ Height: {{ .Height }}px: too small, better {{ $good_h -}}px in height
+ {{ else if gt (int .Height) $good_h }}
+ Height: {{ .Height }}px: too big, better {{ $good_h -}}px in height
{{ end }}
{{ end }}
-