Allow Pinch-To-Zoom in LightBox in Mobile

Hi.
I have implemented a regular lightbox and it works well. The main image is a thumbnail & on click of it, larger image loads in the light box.
This UX works well for desktop. But for mobile, the size of thumbnail and image in lightbox don’t change much. It usually just 1.5/2 times the thumbnail… whereas the actual image could be 4/5 time bigger.

I see that the lightbox has “swipe left/right” gestures to navigate between images, but there is no option to pinch-to-zoom on current image.
I tried changing the page’s meta tag to user-scalable=yes, but when lightbox is open, there is conflict between swipe gesture and pinch gestures.

Is there any way to allow pinch to zoom in lightbox? It could be an alternate between swipe and pinch gestures. I understand both can’t work at the same time since the zoomed image needs to be panned, which would invoke the swipe geture.

Community Page
Last updated: