CONTENT-WP-0002-T03 renders manifest columns through a pure row mapper and replaceable cell renderers. Assistant: grok Assistant-Session: 01a1346c-fdff-7741-b1af-b7283661554b
15 lines
631 B
TypeScript
15 lines
631 B
TypeScript
import { RecordBrowser } from "@/components/RecordBrowser";
|
|
import { PageHeader } from "@/components/PageHeader";
|
|
import type { KindView } from "@/lib/catalog";
|
|
|
|
/** Kind directory. The heading and rows come from the snapshot kind registry. */
|
|
export function KindIndex({ kind }: { kind: KindView }) {
|
|
const count = kind.rows.length;
|
|
const lede = count === 1 ? `1 record in ${kind.dataspaceTitle}.` : `${count} records in ${kind.dataspaceTitle}.`;
|
|
return (
|
|
<>
|
|
<PageHeader kicker={kind.dataspaceTitle} title={kind.plural} lede={lede} />
|
|
<RecordBrowser rows={kind.rows} columns={kind.columns} />
|
|
</>
|
|
);
|
|
}
|