From 072679758bd81502c941e63fb100ff95983f3de2 Mon Sep 17 00:00:00 2001 From: Josh Goldberg Date: Wed, 11 Sep 2024 08:27:58 -0400 Subject: [PATCH] fix: assorted a11y fixes --- src/components/BioLinks.astro | 9 ++++++--- src/components/Session.astro | 6 +++++- src/components/SpeakerSmall.astro | 13 ++++++++++--- src/pages/travel.astro | 1 + 4 files changed, 22 insertions(+), 7 deletions(-) diff --git a/src/components/BioLinks.astro b/src/components/BioLinks.astro index 188d91f..7932da5 100644 --- a/src/components/BioLinks.astro +++ b/src/components/BioLinks.astro @@ -88,11 +88,13 @@ const aliases = [ align-items: center; display: flex; flex-wrap: wrap; - gap: 0.25rem 0.5rem; + gap: 0 var(--bioLinkPadding); + margin-left: calc(-1 * var(--bioLinkPadding)); + --bioLinkPadding: 0.25rem; } .bio-links-normal { - --bioLinkImageSize: 1.15rem; + --bioLinkImageSize: 1.2rem; } .bio-links-large { @@ -101,7 +103,8 @@ const aliases = [ .bio-link { display: flex; - gap: 0.25rem; + gap: var(--bioLinkPadding); + padding: var(--bioLinkPadding); text-decoration: none; } diff --git a/src/components/Session.astro b/src/components/Session.astro index 3f3b6b4..1342aca 100644 --- a/src/components/Session.astro +++ b/src/components/Session.astro @@ -33,7 +33,11 @@ const { diff --git a/src/components/SpeakerSmall.astro b/src/components/SpeakerSmall.astro index c86284a..c69a0e8 100644 --- a/src/components/SpeakerSmall.astro +++ b/src/components/SpeakerSmall.astro @@ -5,15 +5,22 @@ import SafeMarkdown from "./SafeMarkdown.astro"; import SpeakerImage from "./SpeakerImage.astro"; interface Props { + as: "div" | "li"; class?: string; href?: string; person: Person; } -const { class: className, href, person: speaker, ...rest } = Astro.props; +const { + as: As = "div", + class: className, + href, + person: speaker, + ...rest +} = Astro.props; --- -
+
@@ -42,7 +49,7 @@ const { class: className, href, person: speaker, ...rest } = Astro.props;
- +