import type { VirtualizerOptions } from "@tanstack/react-virtual";
import type { ReactNode } from "react";
import type { DataTableBaseProps } from "./data-table.js";
/**
* Virtualized body of DataTable — renders 10K+ rows over @tanstack/react-virtual
* (blueprint M6, ADR D1/D2 + review fix F-dom-1). Semantic `
` preserved
* with the SPACER-ROW technique: two fixed-height spacer ``s grow the
* table's real layout box to the full dataset height, so the sticky ``
* keeps its containing block for the whole scroll and the last row stays
* reachable — per-row transforms (the official example's pattern) do NOT grow
* the layout box and un-stick the header after ~one window.
*
* Limitations (documented contract — mutually exclusive at the type level):
* no pagination, no expandable rows (fixed row heights are required by
* estimateSize). Cell content must fit `rowHeight` (cells are clipped with
* reduced padding; keep rowHeight >= ~32px). A row-action dropdown unmounts
* when its row leaves the overscan window.
*/
export interface DataTableVirtualizedOptions {
/** Scroll container height (px or CSS length). */
height: number | string;
/** Fixed row height in px — required by the virtualizer's estimateSize. */
rowHeight: number;
/** Rows rendered beyond the viewport on each side. @default 5 */
overscan?: number;
/** @internal test-only — inject virtualizer options (e.g. observeElementRect). */
virtualizerOptions?: Partial>;
}
export type DataTableVirtualizedBodyProps = Omit, "stickyHeader"> & {
virtualized: DataTableVirtualizedOptions;
};
export declare function DataTableVirtualizedBody(props: DataTableVirtualizedBodyProps): ReactNode;