UNPKG

2.25 kBTypeScriptView Raw
1/// <reference types="react" />
2import type { ColumnsType, ColumnType, Direction, ExpandableType, ExpandedRowRender, GetComponent, GetComponentProps, GetRowKey, RenderExpandIcon, RowClassName, TableLayout, TriggerEventHandler } from '../interface';
3import type { FixedInfo } from '../utils/fixUtil';
4declare const makeImmutable: <T extends import("react").ComponentType<any>>(Component: T, shouldTriggerRender?: import("@rc-component/context/lib/Immutable").CompareProps<T>) => T, responseImmutable: <T_1 extends import("react").ComponentType<any>>(Component: T_1, propsAreEqual?: import("@rc-component/context/lib/Immutable").CompareProps<T_1>) => T_1, useImmutableMark: () => number;
5export { makeImmutable, responseImmutable, useImmutableMark };
6export interface TableContextProps<RecordType = any> {
7 scrollX: number | string | true;
8 prefixCls: string;
9 getComponent: GetComponent;
10 scrollbarSize: number;
11 direction: Direction;
12 fixedInfoList: readonly FixedInfo[];
13 isSticky: boolean;
14 supportSticky: boolean;
15 componentWidth: number;
16 fixHeader: boolean;
17 fixColumn: boolean;
18 horizonScroll: boolean;
19 rowClassName: string | RowClassName<RecordType>;
20 expandedRowClassName: RowClassName<RecordType>;
21 onRow?: GetComponentProps<RecordType>;
22 emptyNode?: React.ReactNode;
23 tableLayout: TableLayout;
24 indentSize: number;
25 expandableType: ExpandableType;
26 expandRowByClick: boolean;
27 expandedRowRender: ExpandedRowRender<RecordType>;
28 expandIcon: RenderExpandIcon<RecordType>;
29 onTriggerExpand: TriggerEventHandler<RecordType>;
30 expandIconColumnIndex: number;
31 allColumnsFixedLeft: boolean;
32 columns: ColumnsType<RecordType>;
33 flattenColumns: readonly ColumnType<RecordType>[];
34 onColumnResize: (columnKey: React.Key, width: number) => void;
35 hoverStartRow: number;
36 hoverEndRow: number;
37 onHover: (start: number, end: number) => void;
38 rowExpandable: (record: RecordType) => boolean;
39 expandedKeys: Set<React.Key>;
40 getRowKey: GetRowKey<RecordType>;
41 childrenColumnName: string;
42 rowHoverable?: boolean;
43}
44declare const TableContext: import("@rc-component/context").SelectorContext<TableContextProps<any>>;
45export default TableContext;