update LibraryTree with MapZoom

This commit is contained in:
axolotle
2021-06-11 20:40:28 +02:00
parent 56e1c81aef
commit cfee58bde7
4 changed files with 148 additions and 16 deletions
+2 -3
View File
@@ -177,7 +177,7 @@ export default {
})
},
activeNodes: (state) => {
activeNodes: state => {
if (!state.nodebook) return []
return state.nodebook.reduce((acc, ids) => [...acc, ...ids], [])
},
@@ -218,8 +218,7 @@ export default {
},
nodeTree: (state, rootState) => {
if (state.nodeDepartId === undefined) return
return state.trees[state.nodeDepartId]
return state.trees[state.nodeDepartId] || { nodes: [], links: [] }
}
}
}