import Link from 'next/link'; import { Stat } from '@/components/ui/section'; import { fmtInt } from '@/lib/format'; import { routes } from '@/lib/site'; import type { HomePayload } from '@/lib/types'; /** Headline metrics strip — one hairline row, big tabular numbers, no cards. */ export function HeadlineMetrics({ home }: { home: HomePayload }) { const s = home.stats; const items: { label: string; value: string; hint: string; href: string }[] = [ { label: 'Payloads · 30 d', value: fmtInt(s.payloads_launched_30d), hint: `${fmtInt(home.launches.last_30d)} launches`, href: routes.launches() }, { label: 'Payloads · YTD', value: fmtInt(s.payloads_launched_ytd), hint: `${fmtInt(home.launches.ytd)} launches`, href: routes.launches() }, { label: 'Payloads · 365 d', value: fmtInt(s.payloads_launched_365d), hint: `${fmtInt(home.launches.last_365d)} launches`, href: routes.launches() }, { label: 'Decays · 30 d', value: fmtInt(s.decayed_last_30d), hint: `${fmtInt(s.decayed_last_365d)} in 365 d`, href: routes.reentries() }, { label: 'Debris on orbit', value: fmtInt(s.debris_on_orbit), hint: 'catalogued fragments', href: routes.debris() }, { label: 'Rocket bodies', value: fmtInt(s.rocket_bodies_on_orbit), hint: 'on orbit', href: routes.debris() }, { label: 'With element sets', value: fmtInt(s.with_elements), hint: 'tracked live', href: routes.explore() }, ]; return (
{items.map((it) => ( ))}
); }