import * as React from 'react'; import { Nullish } from '@table-library/react-table-library/types/common'; import { Theme } from '@table-library/react-table-library/types/theme'; import { Layout } from '@table-library/react-table-library/types/layout'; import { ColumnResizeProps } from '@table-library/react-table-library/types/resize'; import { Select } from '@table-library/react-table-library/types/select'; import { Tree } from '@table-library/react-table-library/types/tree'; import { Sort } from '@table-library/react-table-library/types/sort'; import { Pagination } from '@table-library/react-table-library/types/pagination'; export declare type Identifier = string | number; export declare type TableNode = { id: Identifier; nodes?: TableNode[] | Nullish; [prop: string]: any; }; export declare type ExtendedNode = T & { treeXLevel?: number; treeYLevel?: number; parentNode?: ExtendedNode | Nullish; ancestors?: ExtendedNode[]; }; export declare type Data = { pageInfo?: any; nodes: T[]; }; export declare type RestProps = Record; export declare type Event = React.SyntheticEvent | React.KeyboardEvent; export declare type OnClick = (node: T, event: Event) => void; export declare type CellProps = { className?: string; pinLeft?: boolean; pinRight?: boolean; stiff?: boolean; gridColumnStart?: number; gridColumnEnd?: number; onClick?: (event: React.SyntheticEvent) => void; children?: React.ReactNode; } & RestProps; export declare type HeaderCellProps = { index?: number; className?: string; hide?: boolean; pinLeft?: boolean; pinRight?: boolean; stiff?: boolean; isFooter?: boolean; gridColumnStart?: number; gridColumnEnd?: number; resize?: ColumnResizeProps; children?: React.ReactNode; } & RestProps; export declare type RowProps = { item: T; className?: string; disabled?: boolean; onClick?: OnClick; onDoubleClick?: OnClick; children: React.ReactNode; } & RestProps; export declare type BodyProps = { children: React.ReactNode; } & RestProps; export declare type HeaderRowProps = { isFooter?: boolean; className?: string; children: React.ReactNode; } & RestProps; export declare type HeaderProps = { children: React.ReactNode; } & RestProps; export declare type TableProps = { data: Data; theme?: Theme; layout?: Layout; sort?: Sort; pagination?: Pagination; select?: Select; tree?: Tree; onInit?: OnInitFunction; children?: (nodes: ExtendedNode[]) => React.ReactNode; } & RestProps; export declare type OnInitFunction = (node: HTMLTableElement) => void; export declare type Features = { select: Select | Nullish; tree: Tree | Nullish; sort: Sort | Nullish; pagination: Pagination | Nullish; }; export declare type FeatureProps = { theme?: string; className?: string; onClick: OnClick; }; export declare type GetRowProps = (props: RowProps, features: Features) => FeatureProps;