-
Notifications
You must be signed in to change notification settings - Fork 678
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: 显示所有选中节点(包括父节点) #2233
base: release
Are you sure you want to change the base?
feat: 显示所有选中节点(包括父节点) #2233
Conversation
This pull request is automatically built and testable in CodeSandbox. To see build info of the built libraries, click here or the icon next to each commit SHA. |
content/navigation/tree/index.md
Outdated
@@ -2287,6 +2287,7 @@ import { IconFixedStroked, IconSectionStroked, IconAbsoluteStroked, IconInnerSec | |||
| autoExpandParent | 是否自动展开父节点,默认为 false,当组件初次挂载时为 true | boolean | false | 0.34.0 | | |||
| autoExpandWhenDragEnter | 是否允许拖拽到节点上时自动展开改节点 | boolean | true | 1.8.0 | | |||
| blockNode | 行显示节点 | boolean | true | - | | |||
| bothParents | 多选时,显示所有选中节点(包括父节点) | boolean | false | - | |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这个模式融合到 checkRelation 中更好?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
可以在checkRelation中新增一个选项,命名为all吗?或者是你们提供一个名字?
const isMultiple = this._isMultiple(); | ||
const { keyMaps } = this.getProps(); | ||
const { keyEntities } = this.getStates(); | ||
if (this.getProp('treeDataSimpleJson')) { | ||
if (bothParents) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
我理解这种模式的处理应该在 notifyMultipleChange 中?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
确实是多选下的条件,稍后修改
还需要考虑的点
|
English Template / 英文模板
PR类型 (请至少选择一个)
PR 描述
Fixes #
feature 在Tree组件中新增了bothParents属性,用来在多选时,返回所有子节点时同时返回父节点
更新日志
🇨🇳 Chinese
🇺🇸 English
检查清单
其他要求
附加信息