From f6dc6ebce8993b3ef7aae4540590fb724b8627c5 Mon Sep 17 00:00:00 2001 From: teldra Date: Mon, 11 Apr 2022 20:53:58 +0200 Subject: [PATCH] small fixes --- themes/buha/assets/css/main.css | 2 +- themes/buha/layouts/_default/baseof.html | 6 ++-- .../buha/layouts/partials/layout/article.html | 1 - .../layouts/partials/snippets/footer.html | 2 +- .../buha/layouts/partials/snippets/head.html | 34 +++++++++++++++++++ .../layouts/partials/snippets/header.html | 15 ++++++++ .../buha/layouts/partials/snippets/langs.html | 10 ++++++ .../buha/layouts/partials/snippets/menu.html | 2 +- .../layouts/partials/snippets/submenu.html | 6 ++++ 9 files changed, 71 insertions(+), 7 deletions(-) create mode 100644 themes/buha/layouts/partials/snippets/head.html create mode 100644 themes/buha/layouts/partials/snippets/header.html create mode 100644 themes/buha/layouts/partials/snippets/langs.html create mode 100644 themes/buha/layouts/partials/snippets/submenu.html diff --git a/themes/buha/assets/css/main.css b/themes/buha/assets/css/main.css index 2bb8266e..1c931433 100644 --- a/themes/buha/assets/css/main.css +++ b/themes/buha/assets/css/main.css @@ -37,7 +37,7 @@ aside { } section { - flex-grow: 1; + flex-grow: 0; flex-shrink: 0; margin-left: 0rem; padding: 1rem; diff --git a/themes/buha/layouts/_default/baseof.html b/themes/buha/layouts/_default/baseof.html index e768e6f1..1d45d959 100644 --- a/themes/buha/layouts/_default/baseof.html +++ b/themes/buha/layouts/_default/baseof.html @@ -1,12 +1,12 @@ - {{- partial "structure/head.html" . -}} + {{- partial "snippets/head.html" . -}} {{ block "css" . -}}{{- end }}
- {{ partialCached "structure/header" . }} - {{ partial "structure/submenu" . }} + {{ partialCached "snippets/header" . }} + {{ partial "snippets/submenu" . }}
diff --git a/themes/buha/layouts/partials/layout/article.html b/themes/buha/layouts/partials/layout/article.html index da7bd620..f16fdab5 100644 --- a/themes/buha/layouts/partials/layout/article.html +++ b/themes/buha/layouts/partials/layout/article.html @@ -32,7 +32,6 @@ {{ end }} {{- if or .context.Content .context.Summary -}}
- {{ if eq .type "contact" }}{{ partial "structure/contact" }}{{ end }} {{ 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 -}}..
diff --git a/themes/buha/layouts/partials/snippets/footer.html b/themes/buha/layouts/partials/snippets/footer.html index 2b0d5d46..66ccfa3f 100644 --- a/themes/buha/layouts/partials/snippets/footer.html +++ b/themes/buha/layouts/partials/snippets/footer.html @@ -5,7 +5,7 @@ {{ $contact = i18n "contact" }} {{ end }} {{- $contact | strings.FirstUpper -}}:

- {{- partial "structure/contact" -}} + {{- partial "snippets/contact" -}}
{{- end -}} diff --git a/themes/buha/layouts/partials/snippets/head.html b/themes/buha/layouts/partials/snippets/head.html new file mode 100644 index 00000000..6939aafe --- /dev/null +++ b/themes/buha/layouts/partials/snippets/head.html @@ -0,0 +1,34 @@ + + + + +{{ $water := resources.Get "css/color.css" }} +{{ $header := resources.Get "css/header.css" }} +{{ $main := resources.Get "css/main.css" }} +{{ $article := resources.Get "css/article.css" }} +{{ $paginator := resources.Get "css/paginator.css" }} +{{ $footer := resources.Get "css/footer.css" }} +{{ $classes := resources.Get "css/classes.css" }} +{{ $generator := resources.Get "css/generator.css" }} +{{ $big := resources.Get "css/big.css" }} +{{ $allcss := slice $water $header $main $article $paginator $footer $generator $big $classes | resources.Concat "/css/vendor.css" | minify | fingerprint "sha512" }} + + +{{ $title := print .Site.Title " | " .Title }} +{{ if .IsHome }}{{ $title = .Site.Title }}{{ end }} +{{ $title }} + + + +{{ range .AlternativeOutputFormats -}} + {{ printf `` .Rel .MediaType.Type .Permalink $.Site.Title | safeHTML }} +{{ end -}} + +{{ if .Site.Params.keywords -}} + +{{- end }} + + + +{{ template "_internal/opengraph.html" . }} + diff --git a/themes/buha/layouts/partials/snippets/header.html b/themes/buha/layouts/partials/snippets/header.html new file mode 100644 index 00000000..b6fe1c0e --- /dev/null +++ b/themes/buha/layouts/partials/snippets/header.html @@ -0,0 +1,15 @@ +
+ + SVG mit img laden + + +
diff --git a/themes/buha/layouts/partials/snippets/langs.html b/themes/buha/layouts/partials/snippets/langs.html new file mode 100644 index 00000000..c5921c14 --- /dev/null +++ b/themes/buha/layouts/partials/snippets/langs.html @@ -0,0 +1,10 @@ +{{ if not .IsHome }} + {{ if .Translations }} +
  • {{ "Languages" }}

  • + {{ range .Translations }} + {{ if ne .Lang $.Lang }} +
  • {{- if i18n .Lang -}}{{- i18n .Lang -}}{{- else -}}{{- humanize .Lang -}}{{ end }}
  • + {{ end }} + {{ end }} + {{ end }} +{{ end }} diff --git a/themes/buha/layouts/partials/snippets/menu.html b/themes/buha/layouts/partials/snippets/menu.html index 2fc2b65d..d78098e6 100644 --- a/themes/buha/layouts/partials/snippets/menu.html +++ b/themes/buha/layouts/partials/snippets/menu.html @@ -23,5 +23,5 @@ {{ end }} {{ end }} {{ if .IsHome }} - {{ partial "structure/langs" . }} + {{ partial "snippets/langs" . }} {{ end }} diff --git a/themes/buha/layouts/partials/snippets/submenu.html b/themes/buha/layouts/partials/snippets/submenu.html new file mode 100644 index 00000000..d7597f80 --- /dev/null +++ b/themes/buha/layouts/partials/snippets/submenu.html @@ -0,0 +1,6 @@ +
    +
    + Menü ☰ + {{ partial "snippets/menu" . }} +
    +