Is there a way to limit panning maybe by 50% of the image. For example while panning the image, if 50% of image is out of screen/panning area, then stop panning in that direction.
Check this demo for the behaviour which I am looking for.
Is there a way to limit panning maybe by 50% of the image. For example while panning the image, if 50% of image is out of screen/panning area, then stop panning in that direction.
Check this demo for the behaviour which I am looking for.
Just use inverted containment http://timmywil.github.io/jquery.panzoom/demo/#inverted-contain and adjust the whitespace around the element to stop when panning in a particular direction.