How to limit the moving range of the connection line of the fishbone diagram?

I have a problem with the fishbone diagram layout. In my fishbone diagram, when I move node A left and right, I hope that the connection line of node A will not exceed the range of the connection line of the parent node. When I move up and down, I don’t move to the bottom, only move on one side. I don’t have an idea at present, please help me, thank you!


I suggest that you set the node’s minLocation and maxLocation.

https://gojs.net/latest/intro/tools.html

Thank you for your answer, but according to your suggestion, the api has not been implemented yet, and if I set it like this, will its subordinate nodes move together when I drag the node? Can you tell me in detail or provide a demo as a reference, thank you!

Although setting the maximum and minimum positions can be limited, it is a rectangular area. I hope it can be the effect of Figure 1 instead of Figure 2.


1604557604(1)

Yes minLocation and maxLocation form a rectangular area. For more general control over where a node may be dragged, setting dragComputation lets you determine precisely where it can go. Part | GoJS API
There are other examples in the samples.