B-secties: nav, hero, Over, Werkwijze, contactblok en footer volgens ontwerp B
Nieuwe tokens (brand, inv, panel, field, prog, body), Archivo als lettertype (Sora en Instrument Sans verwijderd), witte toggles op het rode kopblok, en tests voor structuur, landmarks en contrast in alle vier de thema's. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -1,41 +1,59 @@
|
||||
import { heroContent } from '../data/content';
|
||||
import { handleAnchorClick } from '../../../utils/scrollToHash';
|
||||
|
||||
/**
|
||||
* Hero of design B: display headline on the brand-red block, lead + two buttons, and the black
|
||||
* code strip with the blinking caret. The nav sits directly above in the same colour.
|
||||
*/
|
||||
export function Hero() {
|
||||
return (
|
||||
<header id="top" className="relative overflow-hidden pb-[88px] pt-24">
|
||||
<div className="mx-auto max-w-[1080px] px-6">
|
||||
<span className="font-mono mb-5 block text-sm uppercase tracking-wider text-accent">
|
||||
{heroContent.eyebrow}
|
||||
</span>
|
||||
<h1 className="font-display mb-6 max-w-[15ch] text-4xl font-extrabold leading-tight tracking-tight sm:text-5xl">
|
||||
{heroContent.heading}
|
||||
</h1>
|
||||
<p className="mb-9 max-w-[52ch] text-lg text-muted">{heroContent.lead}</p>
|
||||
<div
|
||||
aria-hidden="true"
|
||||
className="font-mono mb-10 inline-flex max-w-full items-center gap-2 overflow-x-auto whitespace-nowrap rounded border border-line bg-surface px-6 py-4 shadow-lg"
|
||||
<section id="top" aria-labelledby="hero-heading" className="bg-brand text-on-brand">
|
||||
<div className="mx-auto max-w-[1280px] px-6 pb-16 pt-10 sm:px-8 sm:pb-24 sm:pt-16">
|
||||
<h1
|
||||
id="hero-heading"
|
||||
className="text-[clamp(56px,10.5vw,168px)] font-extrabold leading-[0.88] tracking-[-0.03em] [font-stretch:125%]"
|
||||
aria-label={heroContent.heading}
|
||||
>
|
||||
<span>{heroContent.codeLine}</span>
|
||||
<span className="caret" data-testid="hero-caret" />
|
||||
</div>
|
||||
<div className="flex flex-col gap-4 sm:flex-row sm:flex-wrap">
|
||||
<a
|
||||
href="#pakketten"
|
||||
onClick={(event) => handleAnchorClick(event, '#pakketten')}
|
||||
className="rounded-lg bg-accent px-6 py-3.5 text-center text-[0.98rem] font-semibold text-[var(--color-accent-contrast)] transition-transform hover:bg-[var(--color-accent-hover)] active:scale-[0.98] sm:text-left"
|
||||
>
|
||||
Bekijk pakketten
|
||||
</a>
|
||||
<a
|
||||
href="#contact"
|
||||
onClick={(event) => handleAnchorClick(event, '#contact')}
|
||||
className="rounded-lg border border-line px-6 py-3.5 text-center text-[0.98rem] font-semibold text-text transition-colors hover:border-accent-line sm:text-left"
|
||||
>
|
||||
Plan een gesprek
|
||||
</a>
|
||||
{heroContent.displayHeading.map((line, index) => (
|
||||
<span
|
||||
key={line}
|
||||
className="block"
|
||||
aria-hidden="true"
|
||||
data-testid={`hero-line-${index}`}
|
||||
>
|
||||
{line}
|
||||
</span>
|
||||
))}
|
||||
</h1>
|
||||
<div className="mt-12 flex flex-wrap items-end justify-between gap-10 sm:mt-[72px] lg:gap-x-16">
|
||||
<p className="max-w-[48ch] text-[19px] leading-[1.55]">{heroContent.lead}</p>
|
||||
<div className="flex flex-wrap gap-3">
|
||||
<a
|
||||
href="#pakketten"
|
||||
onClick={(event) => handleAnchorClick(event, '#pakketten')}
|
||||
className="bg-white px-[26px] py-[17px] text-base font-bold text-[#0e0d0d] no-underline hover:opacity-90"
|
||||
>
|
||||
Bekijk pakketten
|
||||
</a>
|
||||
<a
|
||||
href="#contact"
|
||||
onClick={(event) => handleAnchorClick(event, '#contact')}
|
||||
className="border-2 border-white px-6 py-[15px] text-base font-bold text-white no-underline hover:opacity-90"
|
||||
>
|
||||
Plan een gesprek
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</header>
|
||||
<div className="bg-inv">
|
||||
<div className="font-mono mx-auto flex max-w-[1280px] flex-wrap items-center justify-between gap-x-8 gap-y-2 px-6 py-[22px] text-base sm:px-8">
|
||||
<span className="text-white" aria-hidden="true">
|
||||
<span className="text-[#a8a29c]">~/slp $</span> {heroContent.codeLine}
|
||||
<span className="caret ml-1.5 !bg-white" data-testid="hero-caret" />
|
||||
</span>
|
||||
<span className="text-sm text-[#a8a29c]">{heroContent.eyebrow}</span>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user