vasturiano/force-graph

make a rectangle that follows the building node.

Opened this issue · 0 comments

Hello master! @vasturiano
I want to make a rectangle that follows the building node.

code sample.
https://codesandbox.io/s/force-graph-svg-images-forked-fxf0sj?file=/index.js

this is my 'ORIGIN' test step
step 1.
Input key code 'A' (this step is to connect the 'building node' with 'the rectangle'.

step 2.
Move a building node (The building node and the rectangle move together, move well together.)


and this is my 'NEW' test steps.

step 1.
Move a building node (Only the building node is moving.)

step 2.
Input key code 'A' (this step is to connect the 'building node' with 'the rectangle'.

step 3.
Move a building node again(The building node and the rectangle move together, move well together.)

but, the rectangle position has been changed at press keycode.
'NEW' test steps applies only at the same interval.(x:10, y:10)
um.......how do I keep the distance between the building node and the rectangle at ?🤷‍♂️

thank you so much.