From df3ad1e06e63f78b6f71db49d07a7662b2dde938 Mon Sep 17 00:00:00 2001 From: f0x Date: Wed, 10 May 2023 20:18:49 +0200 Subject: [PATCH] fix header styling/wrapping --- web/source/css/base.css | 14 +++++----- web/source/css/index.css | 6 ++--- web/template/header.tmpl | 55 +++++++++++++++++++++++++--------------- 3 files changed, 43 insertions(+), 32 deletions(-) diff --git a/web/source/css/base.css b/web/source/css/base.css index cdfe58a00..2d3466d8d 100644 --- a/web/source/css/base.css +++ b/web/source/css/base.css @@ -99,23 +99,21 @@ header a { flex-wrap: wrap; margin: 1.5rem; gap: 1rem; + justify-content: center; img { align-self: center; height: 3rem; } - div { + h1 { flex-grow: 1; align-self: center; - display: flex; + text-align: center; - h1 { - font-size: 1.5rem; - word-wrap: anywhere; - align-self: center; - color: $fg; - } + font-size: 1.5rem; + word-wrap: anywhere; + color: $fg; } } diff --git a/web/source/css/index.css b/web/source/css/index.css index 8f434c6ce..b4ad1bd1c 100644 --- a/web/source/css/index.css +++ b/web/source/css/index.css @@ -24,10 +24,8 @@ header a { height: 6rem; } - div { - h1 { - font-size: 2rem; - } + h1 { + font-size: 2rem; } } diff --git a/web/template/header.tmpl b/web/template/header.tmpl index addd0953e..05e47991a 100644 --- a/web/template/header.tmpl +++ b/web/template/header.tmpl @@ -21,46 +21,61 @@ + - {{ if .ogMeta }}{{ if .ogMeta.Locale }} - {{ end }} + {{ if .ogMeta }}{{ if .ogMeta.Locale }} + + {{ end }} + - {{ if .ogMeta.ArticlePublisher }} + {{ if .ogMeta.ArticlePublisher }} + - {{ end }}{{ if .ogMeta.ProfileUsername }} - {{ end }} - {{ if .ogMeta.ImageAlt }} - {{ end }}{{ if .ogMeta.ImageWidth }} + {{ end }}{{ if .ogMeta.ProfileUsername }} + + {{ end }} + + {{ if .ogMeta.ImageAlt }} + + {{ end }}{{ if .ogMeta.ImageWidth }} + - {{ end }}{{ end }} - {{ if .rssFeed }}{{ end }} + {{ end }}{{ end }} + + {{ if .rssFeed }} + {{ end }} - {{range .stylesheets}} - {{end}} + {{range .stylesheets}} + + {{end}} + - {{range .stylesheets}} + {{range .stylesheets}} + {{end}}{{ if .ogMeta }}{{ .ogMeta.Title }}{{ else }}{{.instance.Title}} - GoToSocial{{ end }} +
- - {{ if .instance.ThumbnailDescription }}{{ .instance.ThumbnailDescription }}{{ else }}Instance Logo{{ end }} -
-

- {{.instance.Title}} -

-
+
+ {{ if .instance.ThumbnailDescription }}{{ .instance.ThumbnailDescription }}{{ else }}Instance Logo{{ end }} +

+ {{.instance.Title}} +

-
+
\ No newline at end of file