import Link from "next/link"; import clsx from "clsx"; import type { ReactNode } from "react"; const TONE = { expired: "border-l-expired text-expired", warn: "border-l-warn text-warn", accent: "border-l-accent text-accent", } as const; export function Queue({ title, count, tone, items, }: { title: string; count: number; tone: keyof typeof TONE; /* `meta` is a node rather than a string so a queue about time can carry the * term measurement itself. A tier name told the reader what the instance * was; the queue is sorted by how soon it lapses, and that was the one * figure the row did not show. */ items: { label: string; href: string; meta: ReactNode }[]; }) { return (

{title}

{count}

{items.length === 0 ? (

Nothing to do here.

) : ( )}
); }