diff --git a/themes/tsc_vfl/static/img/banner/Banner-RENOTE.jpg b/assets/banner/Banner-RENOTE.jpg similarity index 100% rename from themes/tsc_vfl/static/img/banner/Banner-RENOTE.jpg rename to assets/banner/Banner-RENOTE.jpg diff --git a/themes/tsc_vfl/static/img/banner/Banner-Show2016.jpg b/assets/banner/Banner-Show2016.jpg similarity index 100% rename from themes/tsc_vfl/static/img/banner/Banner-Show2016.jpg rename to assets/banner/Banner-Show2016.jpg diff --git a/themes/tsc_vfl/static/img/banner/Banner2019.jpg b/assets/banner/Banner2019.jpg similarity index 100% rename from themes/tsc_vfl/static/img/banner/Banner2019.jpg rename to assets/banner/Banner2019.jpg diff --git a/themes/tsc_vfl/static/img/banner/Fotobanner2.jpg b/assets/banner/Fotobanner2.jpg similarity index 100% rename from themes/tsc_vfl/static/img/banner/Fotobanner2.jpg rename to assets/banner/Fotobanner2.jpg diff --git a/themes/tsc_vfl/static/img/banner/Paare_2019.jpg b/assets/banner/Paare_2019.jpg similarity index 100% rename from themes/tsc_vfl/static/img/banner/Paare_2019.jpg rename to assets/banner/Paare_2019.jpg diff --git a/themes/tsc_vfl/static/img/banner/slider-turnier.jpg b/assets/banner/slider-turnier.jpg similarity index 100% rename from themes/tsc_vfl/static/img/banner/slider-turnier.jpg rename to assets/banner/slider-turnier.jpg diff --git a/themes/tsc_vfl/layouts/partials/page/banner-images.html b/themes/tsc_vfl/layouts/partials/page/banner-images.html index fc941371..b37ee0b9 100644 --- a/themes/tsc_vfl/layouts/partials/page/banner-images.html +++ b/themes/tsc_vfl/layouts/partials/page/banner-images.html @@ -1,15 +1,22 @@ - - - - - - - +{{- $images := resources.Match "banner/*" -}} +{{- $first := true -}} +{{- range $images }} + {{- $img := .Fit "1220x340 webp" -}} + {{ if $first }} + + {{ $first = false }} + {{ end }} + +{{ end -}}
-
-
-
-
-
-
+ {{- $count := (len $images) -}} + {{- $first := true -}} + {{- range (seq 0 (sub $count 1)) }} +
+ {{ $first = false }} + {{- end }}
+ + diff --git a/themes/tsc_vfl/layouts/partials/page/head.html b/themes/tsc_vfl/layouts/partials/page/head.html index 02df9b02..3546ad29 100644 --- a/themes/tsc_vfl/layouts/partials/page/head.html +++ b/themes/tsc_vfl/layouts/partials/page/head.html @@ -19,7 +19,6 @@ {{ $title }} - diff --git a/themes/tsc_vfl/static/js/slider.js b/themes/tsc_vfl/static/js/slider.js index ade8bc22..fadebe4e 100644 --- a/themes/tsc_vfl/static/js/slider.js +++ b/themes/tsc_vfl/static/js/slider.js @@ -1,6 +1,6 @@ $(function () { var index = 0 - const maxIndex = 5 + const maxIndex = numImages - 1 const delay = 6000 const shuffeledIndices = []