When I try to zoom in till a point I am unable to see zoom working centered to mouse point, and when I zoom out diagram shifts to left top corner, how can we avoid this and make zoom centered to mouse pointer?
When zooming using the mouse wheel, this is typically the default behavior. For other types of zooming, you may want to set Diagram.zoomPoint prior to changing the scale.
you mean on mousescroll, we have to update zoomPoint with value of mouse pointer co-ordinates?
No, that is the default behavior. Try using Ctrl-mousewheel on the samples on our website and you’ll see the zoom will focus on the mouse point. It won’t always be perfectly centered if near the edge of the viewport.
yes I have seen that on samples, not sure why is it not working in our case
got the issue, we are using “positionComputation” which was causing it.