mirror of
https://github.com/ant-design/ant-design.git
synced 2025-08-06 07:56:28 +08:00
doc: add disableCheckbox property for TreeSelect (#7370)
This commit is contained in:
parent
bc3a285e64
commit
a5b0848efe
@ -41,7 +41,7 @@ treeCheckStrictly | Whether to check nodes precisely (in the `checkable` mode),
|
||||
filterTreeNode | Whether to filter treeNodes by input value. The value of `treeNodeFilterProp` is used for filtering by default. | boolean\|Function(inputValue: string, treeNode: TreeNode) (should return boolean) | Function
|
||||
treeNodeFilterProp | Will be used for filtering if `filterTreeNode` returns true | string | 'value'
|
||||
treeNodeLabelProp | Will render as content of select | string | 'title'
|
||||
treeData | Data of the treeNodes, manual construction work is no longer needed if this property has been set(ensure the Uniqueness of each value) | array<{ value, label, children, [disabled, selectable] }> | []
|
||||
treeData | Data of the treeNodes, manual construction work is no longer needed if this property has been set(ensure the Uniqueness of each value) | array<{ value, label, children, [disabled, disableCheckbox, selectable] }> | []
|
||||
treeDataSimpleMode | Enable simple mode of treeData.(treeData should like this: [{id:1, pId:0, value:'1', label:"test1",...},...], pId is parent node's id) | false\|Array<{ id: string, pId: string, rootPId: null }> | false
|
||||
loadData | Load data asynchronously. | function(node) | -
|
||||
getPopupContainer | To set the container of the dropdown menu. The default is to create a `div` element in `body`, you can reset it to the scrolling area and make a relative reposition. [example](http://codepen.io/anon/pen/xVBOVQ?editors=001) | Function(triggerNode) | () => document.body
|
||||
@ -53,6 +53,7 @@ getPopupContainer | To set the container of the dropdown menu. The default is to
|
||||
Property | Description | Type | Default
|
||||
-----|-----|-----|------
|
||||
disabled | Disabled or not | boolean | false
|
||||
disableCheckbox | Disables the checkbox of the treeNode | boolean | false
|
||||
key | Required property, should be unique in the tree | string | -
|
||||
value | Will be treated as `treeNodeFilterProp` by default, should be unique in the tree | string | -
|
||||
title | Content showed on the treeNodes | string\|ReactNode | '---'
|
||||
|
@ -40,7 +40,7 @@ title: TreeSelect
|
||||
| filterTreeNode | 是否根据输入项进行筛选,默认用 treeNodeFilterProp 的值作为要筛选的 TreeNode 的属性值 | boolean\|Function(inputValue: string, treeNode: TreeNode) (函数需要返回bool值) | Function |
|
||||
| treeNodeFilterProp | 输入项过滤对应的 treeNode 属性 | string | 'value' |
|
||||
| treeNodeLabelProp | 作为显示的 prop 设置 | string | 'title' |
|
||||
| treeData | treeNodes 数据,如果设置则不需要手动构造 TreeNode 节点(value 在整个树范围内唯一)| array<{value, label, children, [disabled, selectable]}> | [] |
|
||||
| treeData | treeNodes 数据,如果设置则不需要手动构造 TreeNode 节点(value 在整个树范围内唯一)| array<{value, label, children, [disabled, disableCheckbox, selectable]}> | [] |
|
||||
|treeDataSimpleMode | 使用简单格式的 treeData,具体设置参考可设置的类型 (此时 treeData 应变为这样的数据结构: [{id:1, pId:0, value:'1', label:"test1",...},...], `pId` 是父节点的 id) | false\|Array<{ id: string, pId: string, rootPId: null }> | false |
|
||||
| loadData | 异步加载数据 | function(node) | - |
|
||||
| getPopupContainer | 菜单渲染父节点。默认渲染到 body 上,如果你遇到菜单滚动定位问题,试试修改为滚动的区域,并相对其定位。[示例](http://codepen.io/anon/pen/xVBOVQ?editors=001) | Function(triggerNode) | () => document.body |
|
||||
@ -52,6 +52,7 @@ title: TreeSelect
|
||||
| 参数 | 说明 | 类型 | 默认值 |
|
||||
|-----------|------------------------------------------|------------|--------|
|
||||
| disabled | 是否禁用 | boolean | false |
|
||||
| disableCheckbox | 禁掉 checkbox | boolean | false |
|
||||
| key | 此项必须设置(其值在整个树范围内唯一) | string | - |
|
||||
| value | 默认根据此属性值进行筛选(其值在整个树范围内唯一) | string | - |
|
||||
| title | 树节点显示的内容 | string\|ReactNode | '---' |
|
||||
|
Loading…
Reference in New Issue
Block a user