From d9d8befe21221f8de3ccd0be6439e6123bd805b3 Mon Sep 17 00:00:00 2001 From: Hoernschen Date: Wed, 29 Jun 2022 13:03:51 +0200 Subject: [PATCH] FIX image display in hero section; ADD template for tag display --- assets/scss/hero.scss | 1 + assets/scss/index.scss | 9 ++++++++- layouts/_default/list.html | 19 ++++++++++++------- layouts/_default/single.html | 6 +++++- layouts/_default/term.html | 27 +++++++++++++++++++++++++++ layouts/partials/hero.html | 2 +- 6 files changed, 54 insertions(+), 10 deletions(-) create mode 100644 layouts/_default/term.html diff --git a/assets/scss/hero.scss b/assets/scss/hero.scss index e3f36bb..0b61ffe 100644 --- a/assets/scss/hero.scss +++ b/assets/scss/hero.scss @@ -8,6 +8,7 @@ .hero-icon-container { padding: 1rem; + margin: auto; } .hero-button { diff --git a/assets/scss/index.scss b/assets/scss/index.scss index dfd4c83..3b9a2ec 100644 --- a/assets/scss/index.scss +++ b/assets/scss/index.scss @@ -287,10 +287,16 @@ button { } .services { - display: inherit; + display: flex; + align-items: center; padding: 1.5rem 0rem; } +.services-section-content { + display: flex; + align-items: center; +} + .service-icon-container { padding: 1.5rem; margin: auto; @@ -299,6 +305,7 @@ button { .service-icon { width: 100%; height: auto; + object-fit: contain; } .service-button { diff --git a/layouts/_default/list.html b/layouts/_default/list.html index 62aa147..c10ff15 100644 --- a/layouts/_default/list.html +++ b/layouts/_default/list.html @@ -1,11 +1,17 @@ {{ define "main" }} -{{ if .Params.id }} -{{- partial "hero.html" (dict "hero" .Params "color" .Site.Params.color "odd" 0) -}} -{{ end }} -{{.Content}} -
+ {{ if .Content }} +
+ {{ with .Title }} +
+

{{ . }}

+
+
+ {{ end }} + {{.Content}} +
+ {{ end }} {{- range $index, $page := .Pages }} - {{ $odd := mod (add $index 1) 2 }} + {{ $odd := mod $index 2 }} {{ if eq .Params.type "slider" }} {{- partial "slider.html" (dict "id" $page.File.ContentBaseName "slider" .Params "color" $.Site.Params.color "odd" $odd) -}} {{ else if eq .Params.type "hero" }} @@ -22,5 +28,4 @@ {{- partial "links.html" (dict "id" $page.File.ContentBaseName "links" .Params "defaultimage" $.Site.Params.defaultimage "odd" $odd) -}} {{ end }} {{ end }} -
{{ end }} \ No newline at end of file diff --git a/layouts/_default/single.html b/layouts/_default/single.html index ee772a6..2ccfa6b 100644 --- a/layouts/_default/single.html +++ b/layouts/_default/single.html @@ -1,6 +1,10 @@ {{ define "main" }} {{ with .Params.image }} - + {{ if .url }} + + {{ else }} + + {{ end }} {{ end }}
{{ with .Title }} diff --git a/layouts/_default/term.html b/layouts/_default/term.html new file mode 100644 index 0000000..d5ab45d --- /dev/null +++ b/layouts/_default/term.html @@ -0,0 +1,27 @@ +{{ define "main" }} + +{{ end }} \ No newline at end of file diff --git a/layouts/partials/hero.html b/layouts/partials/hero.html index 994a4a4..92ecbd5 100644 --- a/layouts/partials/hero.html +++ b/layouts/partials/hero.html @@ -13,7 +13,7 @@ {{ end }}
-
+

{{ $hero.title }}