diff --git a/assets/sass/navigation.scss b/assets/sass/navigation.scss index f191a26..909d2c7 100644 --- a/assets/sass/navigation.scss +++ b/assets/sass/navigation.scss @@ -14,6 +14,7 @@ .o-header__wrapper { display: flex; justify-content: space-between; + padding: 0; @media (min-width: #{$breakpoint-md}) { justify-content: unset; @@ -56,9 +57,8 @@ .o-header__logo { display: flex; - margin: .6rem; + margin: .6rem 0; position: relative; - left: -1.6rem; text-decoration: none; border-radius: var(--border-radius-m); diff --git a/assets/sass/styles.scss b/assets/sass/styles.scss index 2dce8cc..05f34dd 100644 --- a/assets/sass/styles.scss +++ b/assets/sass/styles.scss @@ -180,11 +180,20 @@ img { } .o-startpage .row { - margin-bottom: 3.2rem; + margin-bottom: 2.4rem; } .o-startpage__intro { text-wrap: balance; + margin-bottom: 2rem; + display: grid; + grid-template-columns: 1fr 1fr; + gap: 2rem; + + @media (max-width: #{$breakpoint-md}) { + display: flex; + flex-direction: column; + } h2 { font-family: Sansita,Arial,Helvetica,sans-serif; @@ -196,4 +205,47 @@ img { > div { align-content: center; } + + @media (max-width: #{$breakpoint-md}) { + h2 { + font-size: 4.8rem; + } + } +} + +.o-startpage__image { + @media (max-width: #{$breakpoint-md}) { + display: none; + } +} + +.o-startpage__shortcut-wrapper { + display: grid; + grid-template-columns: 1fr 1fr 1fr 3fr; + gap: 2rem; + margin-bottom: 2rem; + + @media (max-width: #{$breakpoint-lg}) { + display: flex; + flex-wrap: wrap; + gap: 1rem; + } + +} + +.o-startpage__search { + margin-bottom: 2rem; + width: 100%; +} + +.o-startpage__news-teaser-wrapper { + display: grid; + grid-template-columns: 1fr 1fr 1fr; + gap: 2rem; + + @media (max-width: #{$breakpoint-md}) { + display: flex; + flex-direction: column; + } + } diff --git a/assets/sass/teaser.scss b/assets/sass/teaser.scss index 55a0d65..f4f1037 100644 --- a/assets/sass/teaser.scss +++ b/assets/sass/teaser.scss @@ -10,44 +10,35 @@ border-radius: var(--border-radius-l); display: flex; flex-direction: column; - - &:nth-child(-n+3) { - @media (max-width: #{$breakpoint-lg}) { - margin-bottom: 2rem; - } - } } .m-teaser--listview .m-teaser__wrapper { margin-bottom: 2.4rem; - flex-direction: row; + display: grid; + grid-template-columns: 1fr 2fr; @media (max-width: #{$breakpoint-md}) { + display: flex; flex-direction: column; } - .m-teaser__image { - @media (min-width: #{$breakpoint-md}) { - max-width: 33%; - } - - img { - border-radius: var(--border-radius-l) 0 0 var(--border-radius-l); + .m-teaser__image img { + border-radius: var(--border-radius-l) 0 0 var(--border-radius-l); - @media (max-width: #{$breakpoint-md}) { - border-radius: var(--border-radius-l) var(--border-radius-l) 0 0; - width: 100%; - } + @media (max-width: #{$breakpoint-md}) { + border-radius: var(--border-radius-l) var(--border-radius-l) 0 0; + width: 100%; } } } .m-teaser--shortcut-tile { + flex-basis: calc( 50% - 0.5rem ); + .m-teaser__wrapper { width: 100%; - height: 12rem; - padding: .8rem; - flex-direction: row; + height: 11rem; + padding: 1.4rem; justify-content: space-between; span { @@ -59,16 +50,29 @@ a { h3 { - text-decoration: underline; - align-self: center; + overflow-wrap: normal; + word-break: normal; + white-space: normal; + hyphens: manual; margin-bottom: 0; } + + transition: background 0.2s, color 0.2s; + + &:hover, + &:focus { + background: var(--link-hovered); + border-color: var(--link-hovered); + color: #fff; + } } } .m-teaser__image img { aspect-ratio: 16/9; border-radius: var(--border-radius-l) var(--border-radius-l) 0 0; + object-fit: cover; + height: 100%; } .m-teaser__dateline { @@ -80,5 +84,13 @@ } .m-teaser__content { - padding: .8rem; + padding: 1.4rem; +} + +.m-teaser__text { + line-clamp: 3; + display: -webkit-box; + -webkit-line-clamp: 3; + -webkit-box-orient: vertical; + overflow: hidden; } diff --git a/content/operator/_index.de.md b/content/operator/_index.de.md index 8db859a..55d83a7 100644 --- a/content/operator/_index.de.md +++ b/content/operator/_index.de.md @@ -1,5 +1,5 @@ --- -title: "Übersicht der Betreiber mit FIP" +title: "Übersicht der Betreiber" description: "Übersicht über die Betreiber, die FIP-Vergünstigungen anbieten." --- diff --git a/content/operator/_index.en.md b/content/operator/_index.en.md index 3997c4f..8eaec5a 100644 --- a/content/operator/_index.en.md +++ b/content/operator/_index.en.md @@ -1,5 +1,5 @@ --- -title: "Overview of operators supporting FIP" +title: "Overview of operators" description: "Overview of the operators providing FIP benefits." --- diff --git a/layouts/_default/baseof.html b/layouts/_default/baseof.html index ac6338c..968ca55 100644 --- a/layouts/_default/baseof.html +++ b/layouts/_default/baseof.html @@ -4,7 +4,7 @@ dir="{{ or site.Language.LanguageDirection `ltr` }}" > - {{ partial "head.html" . }} + {{ partial "head" . }} diff --git a/layouts/_default/home.html b/layouts/_default/home.html index 3d72d91..5ca1200 100644 --- a/layouts/_default/home.html +++ b/layouts/_default/home.html @@ -1,21 +1,21 @@ {{ define "main" }}

{{ T "home-page-text" }}

-
-
+
+
{{ .Content }}
-
+
{{ $image := resources.Get "images/startpage.png" }} - {{ partial "image.html" (dict "image" $image "eager" true) }} + {{ partial "image" (dict "image" $image "eager" true) }}
-
-
- {{ partial "search-slot" }} -
+ + -
+ +
{{ partial "shortcut-tile" (.Site.GetPage "generalinformation") }} {{ partial "shortcut-tile" (.Site.GetPage "country") }} {{ partial "shortcut-tile" (.Site.GetPage "operator") }} @@ -23,17 +23,15 @@

{{ T "home-page-text" }}

-
- {{ (site.GetPage "_supportUs").Content }} -
+ {{ (site.GetPage "_supportUs").Content }}
-
-

{{ T "news-headline"}}

- {{ range first 3 (where site.RegularPages "Section" "news") }} - {{ partial "teaser.html" (dict "listview" false "type" "news" "page" .) }} - {{ end }} +

{{ T "news-headline"}}

+
+ {{ range first 3 (where site.RegularPages "Section" "news") }} + {{ partial "teaser" (dict "listview" false "type" "news" "page" .) }} + {{ end }}
diff --git a/layouts/_default/rss.xml b/layouts/_default/rss.xml index bf0ae9c..092bdbb 100644 --- a/layouts/_default/rss.xml +++ b/layouts/_default/rss.xml @@ -11,7 +11,7 @@ {{ .Title }} {{ .Permalink }} - {{ $cleanedHTML := .Summary | replaceRE `]*class="material-symbols-rounded"[^>]*>.*?` "" | transform.XMLEscape | safeHTML}} + {{ $cleanedHTML := partial "strip-material-icons" .Summary | transform.XMLEscape | safeHTML}} {{ $cleanedHTML }} {{ .PublishDate.Format "Mon, 02 Jan 2006 15:04:05 -0700" | safeHTML }} diff --git a/layouts/news/list.html b/layouts/news/list.html index 1c926e5..7c3fe0e 100644 --- a/layouts/news/list.html +++ b/layouts/news/list.html @@ -5,7 +5,7 @@

{{ .Title }}

{{ .Content }}
{{ range .Pages }} - {{ partial "teaser.html" (dict "listview" "true" "page" .) }} + {{ partial "teaser" (dict "listview" "true" "page" .) }} {{ end }}
diff --git a/layouts/partials/head.html b/layouts/partials/head.html index 19fbaf9..3c9f8d6 100644 --- a/layouts/partials/head.html +++ b/layouts/partials/head.html @@ -1,9 +1,9 @@ -{{ partial "headMeta.html" . }} +{{ partial "headMeta" . }} {{ if .IsHome }}{{ site.Title }}{{ else }}{{ printf "%s | %s" .Title site.Title }}{{ end }} -{{ partialCached "head/js.html" . }} +{{ partialCached "head/js" . }} {{ $options := (dict "targetPath" "css/styles.css" "outputStyle" "compressed") }} {{ with resources.Get "sass/main.scss" }} {{ $style := (resources.ExecuteAsTemplate "sass/main_templated.scss" $ .) | toCSS $options | minify }} @@ -43,4 +43,4 @@ {{- end -}} -{{ partial "structuredData.html" . }} +{{ partial "structuredData" . }} diff --git a/layouts/partials/header.html b/layouts/partials/header.html index 8995308..fef7af1 100644 --- a/layouts/partials/header.html +++ b/layouts/partials/header.html @@ -1 +1 @@ -{{ partial "menu.html" (dict "menuID" "main" "page" .) }} +{{ partial "menu" (dict "menuID" "main" "page" .) }} diff --git a/layouts/partials/shortcut-tile.html b/layouts/partials/shortcut-tile.html index edeb6cb..3515c8b 100644 --- a/layouts/partials/shortcut-tile.html +++ b/layouts/partials/shortcut-tile.html @@ -1,4 +1,4 @@ -
+

{{ .Title }}

{{- partial "icon" "arrow_forward" -}} diff --git a/layouts/partials/sidemenu.html b/layouts/partials/sidemenu.html index 2f5d9b4..1ba7637 100644 --- a/layouts/partials/sidemenu.html +++ b/layouts/partials/sidemenu.html @@ -20,7 +20,7 @@ {{ end }}

{{ .Title }}

- {{ partial "toc.html" (dict "context" . "startLevel" 2 "endLevel" 3 ) }} + {{ partial "toc" (dict "context" . "startLevel" 2 "endLevel" 3 ) }} {{ if eq .Page.Type "country" }} {{ partial "related" (dict "index" "country" "pageType" "operator" "title" (T "_operator__list_title") "page" . "identifier" "operators") }} diff --git a/layouts/partials/strip-material-icons.html b/layouts/partials/strip-material-icons.html new file mode 100644 index 0000000..4459372 --- /dev/null +++ b/layouts/partials/strip-material-icons.html @@ -0,0 +1 @@ +{{ return replaceRE `]*class="[^"]*\bmaterial-symbols-rounded\b[^"]*"[^>]*>.*?` "" . }} diff --git a/layouts/partials/teaser.html b/layouts/partials/teaser.html index 46b7e86..4699687 100644 --- a/layouts/partials/teaser.html +++ b/layouts/partials/teaser.html @@ -3,7 +3,7 @@ {{ $dateMachine := $page.Date | time.Format "2006-01-02T15:04:05-07:00" }} {{ $dateHuman := $page.Date | time.Format ":date_long" }} -
+
{{ $image := (partial "helper/contentImage" $page ) }} {{ if $image }} @@ -22,7 +22,7 @@

{{ $page.Title }}

- {{ $page.Summary | plainify | truncate 100 }} + {{ partial "strip-material-icons" $page.Summary | plainify | truncate 500 }}
diff --git a/layouts/partials/toc.html b/layouts/partials/toc.html index 49dc738..5b0972a 100644 --- a/layouts/partials/toc.html +++ b/layouts/partials/toc.html @@ -64,7 +64,7 @@ @returns {template.HTML} -@example {{ partial "toc.html" (dict "context" . "startLevel" 2 "endLevel" 3 ) }} +@example {{ partial "toc" (dict "context" . "startLevel" 2 "endLevel" 3 ) }} */}} {{- /* Initialize. */}}