Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion site/test-coverage.js
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,6 @@ module.exports = {
tag: { statements: '100%', branches: '96.87%', functions: '100%', lines: '100%' },
textarea: { statements: '98.64%', branches: '95%', functions: '93.33%', lines: '100%' },
toast: { statements: '98.73%', branches: '100%', functions: '94.11%', lines: '98.66%' },
treeSelect: { statements: '5.4%', branches: '0%', functions: '0%', lines: '5.88%' },
treeSelect: { statements: '100%', branches: '94.54%', functions: '100%', lines: '100%' },
upload: { statements: '4.28%', branches: '0%', functions: '0%', lines: '4.47%' },
};
63 changes: 63 additions & 0 deletions src/tree-select/TdTreeSelectProps.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
/* eslint-disable */

/**
* 该文件为脚本自动生成文件,请勿随意修改。如需修改请联系 PMC
* */

import { TNode } from '../common';

export interface TdTreeSelectProps {
/**
* 选项数据
*/
options?: Array<TreeSelectOption>;
/**
* 当前选中的值
*/
value?: TreeSelectValue;
/**
* 默认选中的值
*/
defaultValue?: TreeSelectValue;
/**
* 是否多选
*/
multiple?: boolean;
/**
* 占位符文本
*/
placeholder?: string;
/**
* 是否禁用
*/
disabled?: boolean;
/**
* 是否显示清除按钮
*/
clearable?: boolean;
/**
* 选择器高度
*/
height?: string | number;
/**
* 值变化时的回调
*/
onChange?: (value: TreeSelectValue, selectedOptions: TreeSelectOption | TreeSelectOption[]) => void;
/**
* 清除时的回调
*/
onClear?: () => void;
/**
* 展开/收起时的回调
*/
onExpand?: (expandedKeys: Array<string | number>) => void;
}

export interface TreeSelectOption {
label: string;
value: string | number;
disabled?: boolean;
children?: TreeSelectOption[];
}

export type TreeSelectValue = string | number | Array<string | number>;
Loading