UBERF-9575: Fix filter disappear problem (#8159)

Signed-off-by: Andrey Sobolev <haiodo@gmail.com>
This commit is contained in:
Andrey Sobolev 2025-03-06 22:34:02 +07:00 committed by Andrey Sobolev
parent 427ef5905b
commit 8eeef589f8
No known key found for this signature in database
GPG Key ID: BD80F68D68D8F7F2

View File

@ -37,8 +37,6 @@
const hierarchy = client.getHierarchy()
const dispatch = createEventDispatcher()
let maxIndex = 1
function onChange (e: Filter | undefined) {
if (e === undefined) return
updateFilter(e)
@ -52,7 +50,7 @@
_class,
target,
space,
index: ++maxIndex,
index: $filterStore.map((it) => it.index).reduce((a, b) => Math.max(a, b), 0) + 1,
onChange
},
target