Browse Source

fix(DirectoryTree): `selectedKeys` updating (#5732)

- In `multiple` mode, it should emit single value instead of multiple values on single click.
pull/5750/head
Gin 2 years ago committed by GitHub
parent
commit
bddf64e0ad
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      components/tree/DirectoryTree.tsx

2
components/tree/DirectoryTree.tsx

@ -239,7 +239,7 @@ export default defineComponent({
);
} else {
// Single click
newSelectedKeys = keys;
newSelectedKeys = [key];
lastSelectedKey.value = key;
cachedSelectedKeys.value = newSelectedKeys;
newEvent.selectedNodes = convertDirectoryKeysToNodes(

Loading…
Cancel
Save