Skip to content

Commit 0a38914

Browse files
Rework Conf 2026 sponsor sizing for clearer tier hierarchy (#2404)
Closes #2403 ## Summary The 2026 Sponsors section had inconsistent visual hierarchy: Gold and Silver logos rendered larger than Platinum because every non-Meta logo was forced into a fixed `aspect-[3]` box while Meta was constrained by `aspect-video`. Logos with internal SVG whitespace (Meta, airbnb) and logos with very different aspect ratios within the same tier (wide Apollo vs square ChilliCream) further compounded the imbalance. This PR replaces the fixed-aspect approach with **per-tier `max-h` / `max-w` envelopes** plus optional **per-logo overrides** for cases where intrinsic aspect ratios make a single tier rule look unbalanced. ## Changes ### `src/app/conf/2026/components/sponsors.tsx` - Tier sizing uses Tailwind `max-h-* max-w-*` per tier with mobile + desktop breakpoints. Logos render at their natural aspect via `object-contain` capped by the envelope. - Added optional `sizeOverride` field on `Sponsor` so individual logos with extreme aspect ratios (square ChilliCream, stacked airbnb, small Grafast) can be tuned without raising the whole tier. - Switched the row layout from a 2-column grid to flex with `justify-center` so single-logo tiers (Platinum, Community, Bronze) center on the section instead of sitting in the left grid column. - Tier label is `md:absolute` on desktop so logos align to the section's true horizontal center, not centered relative to the post-label area. - Meta `<img>` no longer needs the `aspect-video` wrapper; the cropped SVG handles its own sizing. ### SVG asset cleanup - Cropped internal whitespace from `Meta.svg` and `Meta-dark.svg` (`viewBox="940 940 5100 1120"`). - Aligned `airbnb.svg` `width`/`height` attributes with the cropped viewBox so the logo fills its envelope without internal padding. - Added explicit `width`/`height` attributes to `Chillicream.svg`, `airbnb.svg`, `Meta.svg`, `Meta-dark.svg` so they have intrinsic dimensions when sized via `max-h`/`max-w` alone (previously these collapsed without the `aspect-[3]` wrapper). ## Result Visual hierarchy now reads Platinum > Gold > Silver/Community > Bronze at any viewport, and logos within a tier feel comparable in visual weight regardless of shape. ## Test plan - [ ] Open `/conf/2026/#sponsors` and confirm tier hierarchy reads correctly - [ ] Verify all logos render in light and dark mode - [ ] Check at 375px, 768px, 1280px, 1920px viewports - [ ] Confirm hover state (subtle gray background) still appears on each logo tile
1 parent eee85f2 commit 0a38914

5 files changed

Lines changed: 39 additions & 36 deletions

File tree

public/img/conf/Sponsors/Chillicream.svg

Lines changed: 1 addition & 1 deletion
Loading

public/img/conf/Sponsors/Meta-dark.svg

Lines changed: 1 addition & 1 deletion
Loading

public/img/conf/Sponsors/Meta.svg

Lines changed: 1 addition & 1 deletion
Loading

public/img/conf/Sponsors/airbnb.svg

Lines changed: 1 addition & 1 deletion
Loading

src/app/conf/2026/components/sponsors.tsx

Lines changed: 35 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -14,32 +14,29 @@ interface Sponsor {
1414
| React.FC<React.HTMLAttributes<HTMLDivElement>>
1515
name: string
1616
link: string
17+
// Per-logo size override appended after the tier classes; use sparingly to
18+
// even out logos with extreme aspect ratios within the same tier.
19+
sizeOverride?: string
1720
}
1821

1922
const sponsorPlatinum: Sponsor[] = [
2023
{
21-
icon: (props: React.HTMLAttributes<HTMLDivElement>) => (
22-
// When attempting to render the Meta logo with SVGR, the image becomes
23-
// corrupted (something to do with a `clip-path`?); this means we need to
24-
// render as an `<img>` and prevents us updating the viewBox.
25-
<div
26-
{...props}
27-
className={clsx(props.className, "relative aspect-video flex-shrink-0")}
28-
>
24+
icon: ({ className }: React.HTMLAttributes<HTMLElement>) => (
25+
<>
2926
<img
3027
src={
3128
new URL("/public/img/conf/Sponsors/Meta.svg", import.meta.url).href
3229
}
33-
className="absolute inset-0 size-full object-contain dark:hidden"
30+
className={clsx(className, "dark:hidden")}
3431
/>
3532
<img
3633
src={
3734
new URL("/public/img/conf/Sponsors/Meta-dark.svg", import.meta.url)
3835
.href
3936
}
40-
className="absolute inset-0 hidden size-full object-contain dark:block"
37+
className={clsx(className, "hidden dark:block")}
4138
/>
42-
</div>
39+
</>
4340
),
4441
name: "Meta",
4542
link: "https://about.facebook.com/meta/",
@@ -101,6 +98,8 @@ const sponsorSilver: Sponsor[] = [
10198
),
10299
name: "Chillicream",
103100
link: "https://chillicream.com/",
101+
// Square logo — needs more height to feel comparable to wide silver logos.
102+
sizeOverride: "md:max-h-36 md:max-w-[200px]",
104103
},
105104
]
106105

@@ -118,16 +117,17 @@ const sponsorBronze: Sponsor[] = [
118117
),
119118
name: "Grafast",
120119
link: "https://grafast.org/",
120+
sizeOverride: "md:max-h-[72px] md:max-w-[280px]",
121121
},
122122
]
123123

124124
const sponsorCommunity: Sponsor[] = [
125125
{
126-
icon: (props: React.SVGProps<SVGElement>) => (
127-
<Airbnb {...props} viewBox="567 570 1979.77 660.012" />
128-
),
126+
icon: (props: React.SVGProps<SVGElement>) => <Airbnb {...props} />,
129127
name: "Airbnb",
130128
link: "https://www.airbnb.com/",
129+
// Tall stacked logo — bump height to match silver visual weight.
130+
sizeOverride: "md:max-h-[76px] md:max-w-[230px]",
131131
},
132132
]
133133

@@ -139,33 +139,42 @@ interface Tier {
139139
rank: number
140140
name: string
141141
items: Sponsor[]
142+
logoClass: string
142143
}
143144

145+
// Tier envelopes: cap glyph height and width per breakpoint so visual hierarchy
146+
// stays Platinum > Gold > Silver/Community > Bronze regardless of each logo's
147+
// intrinsic aspect ratio.
144148
const sponsorTiers: Tier[] = [
145149
{
146150
rank: 0,
147151
name: "Platinum",
148152
items: sponsorPlatinum,
153+
logoClass: "max-h-20 max-w-[320px] md:max-h-24 md:max-w-[420px]",
149154
},
150155
{
151156
rank: 1,
152157
name: "Gold",
153158
items: sponsorGold,
159+
logoClass: "max-h-16 max-w-[260px] md:max-h-24 md:max-w-[340px]",
154160
},
155161
{
156162
rank: 2,
157163
name: "Silver",
158164
items: sponsorSilver,
165+
logoClass: "max-h-14 max-w-[220px] md:max-h-[76px] md:max-w-[280px]",
159166
},
160167
{
161168
rank: 2,
162169
name: "Open Source Community Sponsor",
163170
items: sponsorCommunity,
171+
logoClass: "max-h-14 max-w-[220px] md:max-h-[76px] md:max-w-[280px]",
164172
},
165173
{
166174
rank: 3,
167175
name: "Bronze",
168176
items: sponsorBronze,
177+
logoClass: "max-h-12 max-w-[200px] md:max-h-16 md:max-w-[240px]",
169178
},
170179
]
171180

@@ -176,42 +185,36 @@ export function Sponsors({ heading }: SponsorsProps) {
176185

177186
<div className="mt-10 md:mt-16">
178187
{sponsorTiers.map(
179-
tier =>
180-
tier.items.length > 0 && (
181-
<Tier
182-
key={tier.name}
183-
tier={tier}
184-
logoHeight={(7 - tier.rank) * 32}
185-
/>
186-
),
188+
tier => tier.items.length > 0 && <Tier key={tier.name} tier={tier} />,
187189
)}
188190
</div>
189191
</section>
190192
)
191193
}
192194

193-
function Tier({ tier, logoHeight }: { tier: Tier; logoHeight: number }) {
195+
function Tier({ tier }: { tier: Tier }) {
194196
return (
195-
<div className="flex gap-x-12 gap-y-4 border-t border-neu-200 py-4 pb-12 dark:border-neu-50 max-md:flex-col">
196-
<h3 className="flex w-[80px] shrink-0 items-center gap-1 self-start whitespace-nowrap font-mono text-sm/none font-normal uppercase text-pri-base">
197+
<div className="relative flex gap-y-4 border-t border-neu-200 py-4 pb-12 dark:border-neu-50 max-md:flex-col">
198+
<h3 className="flex shrink-0 items-center gap-1 self-start whitespace-nowrap font-mono text-sm/none font-normal uppercase text-pri-base md:absolute md:left-0 md:top-4">
197199
<ChevronRight className="shrink-0 translate-y-[-0.5px]" />
198200
{tier.name}
199201
</h3>
200-
<div className="flex min-w-[70%] flex-wrap justify-center gap-y-4 pt-6 lg:grid lg:w-full lg:grid-cols-2 lg:gap-4">
201-
{tier.items.map(({ link, icon: Icon, name }, i) => (
202+
<div className="flex w-full flex-wrap items-center justify-center gap-x-12 gap-y-4 pt-6 lg:gap-x-20">
203+
{tier.items.map(({ link, icon: Icon, name, sizeOverride }, i) => (
202204
<a
203205
key={i}
204206
href={link}
205207
target="_blank"
206208
rel="noreferrer"
207209
title={name}
208-
className="group flex min-h-24 grow items-center justify-center hover:bg-neu-500/10 dark:opacity-90 dark:hover:opacity-100 md:basis-1/2"
210+
className="group flex min-h-24 items-center justify-center px-6 hover:bg-neu-500/10 dark:opacity-90 dark:hover:opacity-100"
209211
>
210212
<Icon
211-
className="aspect-[3] w-auto max-w-[80%] shrink-0"
212-
style={{
213-
height: logoHeight,
214-
}}
213+
className={clsx(
214+
"h-auto w-auto shrink-0 object-contain",
215+
tier.logoClass,
216+
sizeOverride,
217+
)}
215218
/>
216219
</a>
217220
))}

0 commit comments

Comments
 (0)