refactor(core): remove suspension
This commit is contained in:
@@ -1,5 +0,0 @@
|
||||
---
|
||||
"@vue-flow/core": patch
|
||||
---
|
||||
|
||||
Suspens transformationpane until dimensions exist
|
||||
@@ -9,10 +9,11 @@ const { id, viewport, d3Zoom, d3Selection, dimensions, fitViewOnInitDone } = use
|
||||
|
||||
const viewportReady = ref(!isClient)
|
||||
|
||||
await until(() => !!(d3Zoom.value && d3Selection.value && dimensions.value.width > 0 && dimensions.value.height > 0)).toBe(true)
|
||||
|
||||
until(fitViewOnInitDone)
|
||||
.toBe(true)
|
||||
until(
|
||||
() =>
|
||||
!!(d3Zoom.value && d3Selection.value && dimensions.value.width > 0 && dimensions.value.height > 0 && fitViewOnInitDone.value),
|
||||
)
|
||||
.toBe(true, { flush: 'post' })
|
||||
.then(() => {
|
||||
setTimeout(() => {
|
||||
viewportReady.value = true
|
||||
|
||||
@@ -402,11 +402,9 @@ export default {
|
||||
:is-selecting="isSelecting"
|
||||
:class="{ connecting: !!connectionStartHandle, dragging: paneDragging, draggable: shouldPanOnDrag }"
|
||||
>
|
||||
<Suspense>
|
||||
<Transform>
|
||||
<slot />
|
||||
</Transform>
|
||||
</Suspense>
|
||||
<Transform>
|
||||
<slot />
|
||||
</Transform>
|
||||
</Pane>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
Reference in New Issue
Block a user