Skip to content
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

[TreeSelect] 树选择组件的选项disabled,禁用父级时,子级全部都被禁用了 #2993

Closed
Loinver opened this issue Dec 21, 2023 · 3 comments
Assignees
Labels
usage the issue is about usage

Comments

@Loinver
Copy link

Loinver commented Dec 21, 2023

这个功能解决了什么问题

有禁用父级,但是还能选择子级的场景。如ant组件库:

image

你建议的方案是什么

选项的disabled,只禁用当前选项节点,与子级无关。

Copy link
Contributor

👋 @Loinver,感谢给 TDesign 提出了 issue。
请根据 issue 模版确保背景信息的完善,我们将调查并尽快回复你。

Copy link
Contributor

github-actions bot commented Dec 21, 2023

♥️ 有劳 @Godlike-meteor 尽快确认问题。
确认有效后将下一步计划和可能需要的时间回复给 @Loinver

@uyarn
Copy link
Collaborator

uyarn commented Dec 22, 2023

可以通过设置checkStrictly 来满足你的需求

<tree-select
:treeProps="{ checkStrictly:true }"
/>

refer to https://codesandbox.io/p/sandbox/tdesign-vue-demo-forked-dq9xpj?file=%2Fsrc%2Fdemo.vue%3A19%2C1

@uyarn uyarn added the usage the issue is about usage label Dec 22, 2023
@uyarn uyarn closed this as completed Dec 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
usage the issue is about usage
Projects
None yet
Development

No branches or pull requests

3 participants