From ec90ac9b777dff975545228384dbcf47e3d077fa Mon Sep 17 00:00:00 2001 From: Hoernschen Date: Sun, 14 Jan 2024 12:16:30 +0100 Subject: [PATCH] FIX avatar image CHANGE class names --- assets/scss/index.scss | 33 ++++++++++++++------------ layouts/partials/components/image.html | 3 +-- layouts/partials/hero.html | 8 ++++--- 3 files changed, 24 insertions(+), 20 deletions(-) diff --git a/assets/scss/index.scss b/assets/scss/index.scss index d3c6d46..e48598b 100644 --- a/assets/scss/index.scss +++ b/assets/scss/index.scss @@ -321,7 +321,7 @@ a { padding-block-end: 3rem; } -.content { +main > .content { padding-top: 9rem; padding-bottom: 2rem; padding-right: 1.5rem; @@ -344,56 +344,60 @@ a { flex: 1 0 auto; } -.section-even { +.section.even { // background-color: #eee; } -.section-highlight { +.section.highlight { background-color: {{ .Site.Params.color.primary }}; } -.section-content { +.section > .content { width: 100%; max-width: $width; margin: auto; justify-content: center; } -.hero .hero-content { +.hero > .content { display: flex; justify-content: center; } -.hero .description { +.hero > .content > .image { + max-width: 150px; +} + +.hero > .description { padding: 10px; position: relative; margin-block-start: 50px; border: none; } -.hero .description::before, -.hero .description::after { +.hero > .description::before, +.hero > .description::after { position: absolute; width: 33px; height: 25px; content: ""; } -.hero .description::before { +.hero > .description::before { left: 0; top: 0; border-left: 3px solid {{ .Site.Params.color.primary }}; border-top: 3px solid {{ .Site.Params.color.primary }}; } -.hero .description::after { +.hero > .description::after { right: 0; bottom: 0; border-right: 3px solid {{ .Site.Params.color.primary }}; border-bottom: 3px solid {{ .Site.Params.color.primary }}; } -.hero-content > div { +.hero > .content > div { flex-grow: 1; display: flex; flex-direction: column; @@ -401,17 +405,17 @@ a { padding-inline-start: 25px; } -.hero-content .social { +.hero > .content .social { display: flex; flex-direction: row; flex-wrap: wrap; } -.hero-content .social i { +.hero > .content .social i { font-size: x-large; } -.hero-content .social a { +.hero > .content .social a { padding-inline: 6px; color: {{ .Site.Params.color.primary }}; } @@ -473,5 +477,4 @@ img { border-radius: 50%; border: 3px solid {{ .Site.Params.color.primary }}; object-fit: cover; - width: 150px; } \ No newline at end of file diff --git a/layouts/partials/components/image.html b/layouts/partials/components/image.html index a85b628..a933517 100644 --- a/layouts/partials/components/image.html +++ b/layouts/partials/components/image.html @@ -5,7 +5,6 @@ alt: string width: int height: int --> -{{ $avatar := "avatar"}} {{ $sizes := slice "320" "640" "960" "1280" }} {{ $ext := path.Ext .url }} {{ $name := path.Base (replace .url $ext "") }} @@ -31,7 +30,7 @@ height: int " /> -
+
{{ with .hero }} -
+
{{ if .avatar }} - {{ partial "components/image.html" .avatar }} +
+ {{ partial "components/image.html" .avatar }} +
{{ end }}

{{ .greeting }}