import { ComponentType, Ref } from 'react'; import { Row } from 'react-table'; import { FixedSizeList, ListChildComponentProps, ListItemKeySelector } from 'react-window'; import { TableHeightKeyType, TableLocalType } from './TableUtils'; import { CSSProperties } from 'styled-components'; type VirtualizedRowsType = Record> = { rows: Row[]; RenderRow: ComponentType[]>>>; rowHeight: TableHeightKeyType; setHasScrollbar: React.Dispatch>; hasScrollbar?: boolean; itemKey?: ListItemKeySelector[]>; onBottom?: (rowLength: number) => void; onBottomOffset?: number; listRef?: Ref[]>>; /** * Signature of the currently visible columns. Each row is rendered through * `memo(RenderRow, areEqual)`, and react-window's `areEqual` skips the render * when `itemData` is referentially unchanged. react-table keeps the `rows` * array identity stable when only column visibility changes (responsive * `dropAt`), so without this the header would update while the virtualized * body kept its stale cells. Changing this key gives `itemData` a fresh * identity, forcing the visible rows to re-render without remounting the list. */ columnsKey?: string; }; export declare const VirtualizedRows: = Record>({ rows, rowHeight, setHasScrollbar, onBottom, onBottomOffset, RenderRow, listRef, itemKey, columnsKey, }: VirtualizedRowsType) => import("react/jsx-runtime").JSX.Element; export declare const useTableScrollbar: () => { hasScrollbar: boolean | undefined; setHasScrollbar: import("react").Dispatch>; scrollBarWidth: number; handleScrollbarWidth: (node: any) => void; }; export type RenderRowType = { index: number; style: CSSProperties; }; type TableRowsProps = Record> = { locale?: TableLocalType; children?: (children: JSX.Element) => JSX.Element; customItemKey?: (index: number, data: DATA_ROW) => string; RenderRow: ComponentType[]>>; listRef?: Ref[]>>; }; export declare function TableRows = Record>({ locale, children, customItemKey, RenderRow, listRef: externalListRef, }: TableRowsProps): import("react/jsx-runtime").JSX.Element | null; export {}; //# sourceMappingURL=TableCommon.d.ts.map