diff --git a/src/components/ImageSection.astro b/src/components/ImageSection.astro index 835dae4..b752cd5 100644 --- a/src/components/ImageSection.astro +++ b/src/components/ImageSection.astro @@ -5,28 +5,17 @@ interface Props { title: string; description: string; note: string; - idnr: number; - centered?: boolean; + span?: boolean; } -const { - imgUrl, - imgAlt, - title, - description, - note, - idnr, - centered = false, -} = Astro.props; +const { imgUrl, imgAlt, title, description, note, span = false } = Astro.props; import "../styles/components/ImageSection.scss"; --- -
+
+

{title}

+
+ {imgAlt} +

{description}

+
+

{note}

-

{title}

-
- {imgAlt} -

{description}

-
-
-

{note}

-
diff --git a/src/pages/features.astro b/src/pages/features.astro index 7ba3722..5793c60 100644 --- a/src/pages/features.astro +++ b/src/pages/features.astro @@ -14,7 +14,6 @@ import "../styles/pages/features.scss"; title="Time Planning and Management" description="Helps you to see on which days your fellow team mates are available." note="The bot can send these planning messages every monday at 3AM. Members can click the buttons on each message to communicate, if they have time on that day." - idnr={1} /> diff --git a/src/styles/components/ImageSection.scss b/src/styles/components/ImageSection.scss index 01b8774..c09c2ec 100644 --- a/src/styles/components/ImageSection.scss +++ b/src/styles/components/ImageSection.scss @@ -1,75 +1,54 @@ .ImageSection { - border-radius: 0.5rem; - width: 100%; - grid-row: var(--id)/calc(var(--id) + 2); - grid-row: var(--id)/calc(var(--id) + 2); - grid-column: mod(var(--id), 2)/calc(mod(var(--id), 2) + 1); - - @media (max-width: 1100px) { - max-width: 80vw; - } - - position: relative; - - background-size: contain; - background-color: rgba(0, 0, 0, 0.5); - - &.centered { - grid-column: 1/-1; - width: 50%; - justify-self: center; - } - -} -h1 { - z-index: 1; - grid-row: var(--id)/calc(var(--id) + 1); - grid-column: mod(var(--id), 2)/calc(mod(var(--id), 2) + 1); -} -.imgDiv { - z-index: 1; - grid-row: calc(var(--id) + 1)/calc(var(--id) + 2); - grid-column: mod(var(--id), 2)/calc(mod(var(--id), 2) + 1); - padding: 0.5rem; - margin-left: 3rem; - margin-right: 3rem; - border-radius: 0.5rem; - display: flex; flex-direction: column; align-items: center; + justify-content: space-around; + padding: 2rem 1rem; + gap: 1rem; + border-radius: 0.5rem; + width: 100%; + background-color: rgba(0, 0, 0, 0.5); - img { + @media (min-width: 1150px) { + max-width: 80vw; + + &.span { + grid-column: 1/-1; + width: 50%; + justify-self: center; + } + } + + .imgDiv { border-radius: 0.5rem; - max-width: 80%; - max-height: 280px; + + display: flex; + flex-direction: column; + align-items: center; + + img { + border-radius: 0.5rem; + max-width: 80%; + max-height: 280px; + } + + p { + padding-top: 0.25rem; + font-size: 0.8rem; + text-align: center; + } } - p { - padding-top: 2px; - font-size: 0.8rem; + .noteP { + line-height: 1.5; + vertical-align: middle; + + margin: 0 3rem; + font-size: 1rem; text-align: center; - } -} - -.noteP { - z-index: 1; - grid-row: calc(var(--id) + 2)/calc(var(--id) + 3); - grid-column: mod(var(--id), 2)/calc(mod(var(--id), 2) + 1); - - line-height: 1.5; - vertical-align: middle; - - margin: auto; - font-size: 1rem; - text-align: center; - - display: flex; - justify-content: center; - align-items: center; - - p { - margin: auto; - padding: 2rem; + + display: flex; + justify-content: center; + align-items: center; } } diff --git a/src/styles/pages/features.scss b/src/styles/pages/features.scss index 193fc81..3346dbd 100644 --- a/src/styles/pages/features.scss +++ b/src/styles/pages/features.scss @@ -20,7 +20,7 @@ gap: 1rem; } - @media (min-width: 1100px) { + @media (min-width: 1150px) { .gridlayout { grid-template-columns: repeat(2, 550px); }