diff --git a/src/components/tree/index.tsx b/src/components/tree/index.tsx index 511309c3d..25bdb7e4e 100644 --- a/src/components/tree/index.tsx +++ b/src/components/tree/index.tsx @@ -15,8 +15,8 @@ export enum FileTypes { FILE = 'file', FOLDER = 'folder', ROOT = 'rootFolder', -} -export type FileType = keyof typeof FileTypes; +}; +export type FileType = 'file' | 'folder' | 'rootFolder'; export interface ITreeNodeItem { name?: string; @@ -51,11 +51,11 @@ export interface ITreeProps { expandedKeys?: Key[]; defaultCheckedKeys?: Key[]; checkedKeys?: - | Key[] - | { - checked: Key[]; - halfChecked: Key[]; - }; + | Key[] + | { + checked: Key[]; + halfChecked: Key[]; + }; defaultSelectedKeys?: Key[]; selectedKeys?: Key[]; titleRender?: (node: DataNode) => React.ReactNode;