-
Notifications
You must be signed in to change notification settings - Fork 30
Add button to select all trees and all segments that match a search #8123
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
Changes from 14 commits
79b3438
e71449d
7fcca34
27e841e
a9ad926
526fcc9
fa56c82
84301eb
9d48473
46c40d9
c5c32aa
b7f484a
304a63a
3c89ebe
9d829da
0f7c1b7
a64028b
13b01f4
52ef6b4
dacdfc3
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -188,8 +188,7 @@ function TreeHierarchyView(props: Props) { | |
| } | ||
| } | ||
|
|
||
| function onSelectGroupNode(node: TreeNode) { | ||
| const groupId = node.id; | ||
| function onSelectGroupNode(groupId: number) { | ||
| const numberOfSelectedTrees = props.selectedTreeIds.length; | ||
|
|
||
| if (numberOfSelectedTrees > 1) { | ||
|
|
@@ -254,11 +253,11 @@ function TreeHierarchyView(props: Props) { | |
| const checkedKeys = deepFlatFilter(UITreeData, (node) => node.isChecked).map((node) => node.key); | ||
|
|
||
| // selectedKeys is mainly used for highlighting, i.e. blueish background color | ||
| const selectedKeys = props.selectedTreeIds.map((treeId) => | ||
| getNodeKey(GroupTypeEnum.TREE, treeId), | ||
| ); | ||
| let selectedKeys = props.selectedTreeIds.map((treeId) => getNodeKey(GroupTypeEnum.TREE, treeId)); | ||
|
|
||
| if (props.activeGroupId) selectedKeys = [getNodeKey(GroupTypeEnum.GROUP, props.activeGroupId)]; | ||
|
||
|
|
||
| if (props.activeGroupId) selectedKeys.push(getNodeKey(GroupTypeEnum.GROUP, props.activeGroupId)); | ||
| treeRef.current?.scrollTo({ key: selectedKeys[0], align: "auto" }); | ||
knollengewaechs marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
|
|
||
| return ( | ||
| <> | ||
|
|
@@ -297,7 +296,7 @@ function TreeHierarchyView(props: Props) { | |
| onSelect={(_selectedKeys, info: { node: TreeNode; nativeEvent: MouseEvent }) => | ||
| info.node.type === GroupTypeEnum.TREE | ||
| ? onSelectTreeNode(info.node, info.nativeEvent) | ||
| : onSelectGroupNode(info.node) | ||
| : onSelectGroupNode(info.node.id) | ||
| } | ||
| onDrop={onDrop} | ||
| onCheck={onCheck} | ||
|
|
||

Uh oh!
There was an error while loading. Please reload this page.