feat(web): restyle partner sections
This commit is contained in:
@@ -17,7 +17,7 @@
|
||||
a link through to What We Do.
|
||||
Newsroom three cards from the newsroom, newest first.
|
||||
FAQs a sticky heading column beside the accordion.
|
||||
Consortium the three members, then the civil society network logos.
|
||||
Consortium the three members, then the civil society network logos.
|
||||
|
||||
WHAT THE DRAFT SHIPS THAT THIS PAGE DOES NOT
|
||||
--------------------------------------------
|
||||
@@ -141,10 +141,9 @@ const PARTNER_PAGE_SIZE = 36;
|
||||
/**
|
||||
* Below this many partners the wall stays a grid.
|
||||
*
|
||||
* The marquee loops by carrying the tiles twice and sliding exactly half the
|
||||
* track, which only reads as a loop while the half is wider than the frame it
|
||||
* slides through. Eight 178px tiles clear a desktop container; fewer would
|
||||
* drift a short row across an empty band, so the grid keeps them still.
|
||||
* The loop slides exactly half the track; fewer than eight wider tiles would
|
||||
* leave a short drift instead of filling a desktop frame, so the grid keeps
|
||||
* them still.
|
||||
*/
|
||||
const PARTNER_MARQUEE_MIN = 8;
|
||||
/** The draft's newsroom band is a straight three-up row. */
|
||||
@@ -487,10 +486,21 @@ function PartnerTile({
|
||||
src={partner.logo.src}
|
||||
alt={decorative ? "" : partner.name}
|
||||
loading="lazy"
|
||||
className="max-h-[3.5rem] w-auto max-w-full object-contain"
|
||||
className={cx(
|
||||
"w-auto max-w-full object-contain",
|
||||
fixedWidth
|
||||
? "h-[6.75rem] transition-transform duration-[var(--motion-duration-base)] group-hover:scale-105"
|
||||
: "max-h-[3.5rem]",
|
||||
)}
|
||||
/>
|
||||
) : (
|
||||
<span className="body-sm-bold text-center text-[var(--text-secondary)]">
|
||||
<span
|
||||
className={cx(
|
||||
"body-sm-bold text-center text-[var(--text-secondary)]",
|
||||
fixedWidth &&
|
||||
"transition-colors duration-[var(--motion-duration-base)] group-hover:text-[var(--text-accent)]",
|
||||
)}
|
||||
>
|
||||
{partner.name}
|
||||
</span>
|
||||
);
|
||||
@@ -499,17 +509,16 @@ function PartnerTile({
|
||||
<li
|
||||
{...(decorative ? { "aria-hidden": true } : {})}
|
||||
className={cx(
|
||||
"flex h-[5.5rem] items-center justify-center",
|
||||
"rounded-control border border-[var(--border-subtle)] bg-[var(--surface-card)] p-md",
|
||||
"transition-colors duration-[var(--motion-duration-base)]",
|
||||
"hover:border-[var(--border-accent)]",
|
||||
"flex items-center justify-center",
|
||||
fixedWidth
|
||||
? "group me-lg h-[7.5rem] w-[12.5rem] shrink-0 ps-lg pe-lg"
|
||||
: "h-[5.5rem] rounded-control border border-[var(--border-subtle)] bg-[var(--surface-card)] p-md transition-colors duration-[var(--motion-duration-base)] hover:border-[var(--border-accent)] sh-reveal sh-reveal--in",
|
||||
/* A still grid reveals tile by tile; a travelling track must not, or
|
||||
each tile would ramp its own opacity while it moves.
|
||||
|
||||
The track's spacing is a margin on the tile rather than a `gap` on
|
||||
the row: the loop slides exactly half the track, so each half has to
|
||||
carry its own trailing space or the seam lands half a gap short. */
|
||||
fixedWidth ? "me-md w-[11.125rem] shrink-0" : "sh-reveal sh-reveal--in",
|
||||
decorative && "sh-marquee__clone",
|
||||
)}
|
||||
>
|
||||
|
||||
Reference in New Issue
Block a user