chore(core): cleanup dimension update

This commit is contained in:
braks
2022-11-17 17:55:20 +01:00
committed by Braks
parent 7100c7e173
commit 0876a189eb
+3 -3
View File
@@ -83,15 +83,15 @@ export default (state: State, getters: ComputedGetters): Actions => {
if (!viewportNode) return
const style = window.getComputedStyle(viewportNode)
const { m22: zoom } = new window.DOMMatrixReadOnly(style.transform)
const changes: NodeDimensionChange[] = updates.reduce<NodeDimensionChange[]>((res, update) => {
const node = getters.getNode.value(update.id)
if (node) {
const dimensions = getDimensions(update.nodeElement)
const style = window.getComputedStyle(viewportNode)
const { m22: zoom } = new window.DOMMatrixReadOnly(style.transform)
const doUpdate =
!!(
dimensions.width &&