import { default as React } from 'react'; import { TreeProps as AntTreeProps } from 'antd'; import { BaseComponentProps, DataSetConfig } from '../../types/common'; /** * Tree Semantic DOM 样式配置 * 参考 Ant Design 6.x Semantic DOM 规范 */ export interface TreeSemanticStyles { root?: React.CSSProperties; item?: React.CSSProperties; itemIcon?: React.CSSProperties; itemTitle?: React.CSSProperties; } export interface TreeSemanticClassNames { root?: string; item?: string; itemIcon?: string; itemTitle?: string; } /** * Tree Design Token * 参考 Ant Design 6.x Design Token 规范 */ export interface TreeToken { directoryNodeSelectedBg?: string; directoryNodeSelectedColor?: string; indentSize?: number; nodeHoverBg?: string; nodeHoverColor?: string; nodeSelectedBg?: string; nodeSelectedColor?: string; titleHeight?: number; } /** 与 Ant Design Tree 事件对应的 command 动作名,用于 Extend 中 createWatchCommands 注册 */ export interface AndTreeActionProps { selectAction?: string; checkAction?: string; expandAction?: string; dragEndAction?: string; dragEnterAction?: string; dragLeaveAction?: string; dragOverAction?: string; dragStartAction?: string; dropAction?: string; rightClickAction?: string; loadAction?: string; } export interface AndTreeProps extends Omit, BaseComponentProps, DataSetConfig, AndTreeActionProps { onSelect?: (selectedKeys: React.Key[], info: any) => void; onCheck?: (checkedKeys: React.Key[] | { checked: React.Key[]; halfChecked: React.Key[]; }, info: any) => void; onExpand?: (expandedKeys: React.Key[], info: any) => void; onDragEnd?: (info: { event: React.DragEvent; node: any; }) => void; onDragEnter?: (info: { event: React.DragEvent; node: any; expandedKeys: React.Key[]; }) => void; onDragLeave?: (info: { event: React.DragEvent; node: any; }) => void; onDragOver?: (info: { event: React.DragEvent; node: any; }) => void; onDragStart?: (info: { event: React.DragEvent; node: any; }) => void; onDrop?: (info: { event: React.MouseEvent; node: any; dragNode: any; dragNodesKeys: React.Key[]; }) => void; onRightClick?: (info: { event: React.MouseEvent; node: any; }) => void; onLoad?: (loadedKeys: React.Key[], info: { event: any; node: any; }) => void; styles?: TreeSemanticStyles; classNames?: TreeSemanticClassNames; token?: TreeToken; } export declare const AndTree: React.FC; export default AndTree; //# sourceMappingURL=index.d.ts.map