import { StyleValue, ExtractPropTypes, PropType } from 'vue'; export interface TableColumnT { key: string; label?: string; style?: StyleValue; } export type TableRowT = { key?: string | number; /** 树形懒加载时指示本行是否有子节点 */ hasChildren?: boolean; /** 子节点列表 */ children?: TableRowT[]; } & Record; export interface TableCellT { value: unknown; key: string | number; colspan?: number; rowspan?: number; last?: boolean; } export type CellSpanT = (rowIndex: number, columnIndex: number, rowData?: TableRowT, column?: TableColumnT) => { rowspan?: number; colspan?: number; } | undefined; export declare const TableBorderTypes: readonly ["all", "row", "column", "frame", "row-column", "row-frame", "column-frame", "none"]; export type TableBorderT = (typeof TableBorderTypes)[number]; export declare const tableProps: { /** * @zh-CN 表头数据 * @en-US Table header data */ readonly columns: { readonly type: PropType; }; /** * @zh-CN 表格数据 * @en-US Table data */ readonly data: { readonly type: PropType; }; /** * @zh-CN 表格边框 * @en-US Table border * @default 'row' */ readonly border: { readonly type: PropType; readonly default: "row"; }; /** * @zh-CN 表格斑马纹,仅body中无纵向合并单元格时生效 * @en-US Table striping, taking effect only when there are no vertically merged cells in the table body. */ readonly stripe: { readonly type: BooleanConstructor; readonly default: false; }; /** * @zh-CN 是否使用小尺寸 * @en-US Use small size */ readonly small: { readonly type: BooleanConstructor; }; /** * @zh-CN 单元格合并(不含表头) * @en-US Cell merge (excluding header) */ readonly cellSpan: { readonly type: PropType; }; /** * @zh-CN 空数据提示文本 * @en-US Empty data prompt text */ readonly emptyLabel: { readonly type: StringConstructor; }; /** * @zh-CN 是否显示加载中状态 * @en-US Whether to show loading state */ readonly loading: { readonly type: BooleanConstructor; }; /** * @zh-CN 加载中提示文本 * @en-US Loading prompt text */ readonly loadingLabel: { readonly type: StringConstructor; }; /** * @zh-CN 是否高亮当前行 * @en-US Whether to highlight the current row */ readonly highlightCurrentRow: { readonly type: BooleanConstructor; readonly default: false; }; }; export type TablePropsT = ExtractPropTypes;