update(connection): pass source node to ConnectionLine as prop

Signed-off-by: Braks <78412429+bcakmakoglu@users.noreply.github.com>
This commit is contained in:
Braks
2021-11-24 10:44:06 +01:00
parent 04b64de1de
commit 89849f4eac
3 changed files with 13 additions and 13 deletions

View File

@@ -2,7 +2,7 @@
import { useVueFlow } from '~/index'
const store = useVueFlow()
const nodes = computed(() => store.nodes)
const nodes = computed(() => store.getNodes)
const transform = computed(() => store.transform)
const selectAll = () => {
@@ -19,7 +19,7 @@ const selectAll = () => {
<div class="transform">{{ [transform[0].toFixed(2), transform[1].toFixed(2), transform[2].toFixed(2)] }}</div>
<div class="title">Nodes</div>
<div v-for="node of nodes" :key="node.id">
Node {{ node.id }} - x: {{ node.__vf.position.x.toFixed(2) }}, y: {{ node.__vf.position.y.toFixed(2) }}
Node {{ node.id }} - x: {{ node.position.x.toFixed(2) }}, y: {{ node.position.y.toFixed(2) }}
</div>
<div class="selectall">