Hi GoJS expert,
We notice that when we have two nodes far away from each other. One in viewport, one is not. When we delete one node in viewport, the viewport will be automatically changed to display another one which is not in viewport.
Is there anyway to disable/enable the automatic change so that we could programmatically control view port?
In your scenario, I assume there were no nodes near the one that was deleted.
The standard behavior is to always show some area of the document bounds, because all nodes and links are within the document bounds and one does not want to leave the user off in the wilderness where there is nothing. (Even with that policy, the viewport might be showing an empty area within the document bounds, but that cannot be avoided.)
But you could change the Diagram.scrollMode, or maybe just fix the Diagram.fixedBounds.