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

使用DirectoryTree时,按住shift连续多选报错 #47552

Closed
Dzxwind opened this issue Feb 23, 2024 · 2 comments · Fixed by #47567
Closed

使用DirectoryTree时,按住shift连续多选报错 #47552

Dzxwind opened this issue Feb 23, 2024 · 2 comments · Fixed by #47567

Comments

@Dzxwind
Copy link

Dzxwind commented Feb 23, 2024

Reproduction link

Edit on StackBlitz

Steps to reproduce

使用DirectoryTree且multiple = true的时候,当treeData的isLeaf都为true,defaultExpandAll为false,按住shift连续多选会报错

What is expected?

不再报错

What is actually happening?

Error in /turbo_modules/antd@4.24.12/lib/tree/utils/dictUtil.js (60:25)
Cannot read properties of undefined (reading 'includes')

Environment Info
antd 4.24.15
React 17.x
System macOS和windows都有
Browser 最新版chrome
Copy link

stackblitz bot commented Feb 23, 2024

Fix this issue in StackBlitz Codeflow Start a new pull request in StackBlitz Codeflow.

@wkmyws
Copy link
Contributor

wkmyws commented Feb 23, 2024

这个应该是因为第一层的叶子应该默认是展开状态,但事实上并没有展开导致的,我稍后尝试提个pr

@yoyo837 yoyo837 linked a pull request Feb 23, 2024 that will close this issue
20 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants