import Link from "next/link"; import { ChangeCell } from "@/components/ui/price"; import { cx, EVENT_TYPE_LABEL, formatInt, instrumentHref } from "@/lib/format"; import type { Changes } from "@/lib/types"; /** "What changed" across markets in a window — counts derived from Market Atlas' own bars/events. */ export function ChangesPanel({ changes, className }: { changes: Changes; className?: string }) { return (

What changed · last {changes.window}

derived
{changes.events_by_type.length > 0 && (
{changes.events_by_type.slice(0, 6).map((t) => ( {EVENT_TYPE_LABEL[t.type] ?? t.type} {t.n} ))}
)} {changes.top_movers.length > 0 && ( )}
); } function Num({ n, label, sub }: { n: number; label: string; sub?: string }) { return (
{formatInt(n)}
{label}
{sub &&
{sub}
}
); }