Magento ver. 2.2.2 on an iOS device, go to a product page that contains an image in the fotorama gallery.
The expected result would be the image for the product in the fotorama gallery box. When I click on the close icon on an iPhone or iPad nothing happens. Hooked the device to my iMac to debug and there are no errors visible in the console.
I fixed this issue with below steps, let’s check it here.
Override gallery.js in your custom theme at app/design///web/fotorama/gallery.js.
You can copy this file from /lib/web/mage/gallery/gallery.js and replace code as mentioned below.
From:
1 2 3 4 5 6 7 8 9 10 11 |
if (this.isTouchEnabled) { this.settings.$element.on('tap', '.fotorama__stage__frame', function () { var translate = getTranslate($(this).parents('.fotorama__stage__shaft')); if (translate[1] === '0' && !$(this).hasClass('fotorama-video-container')) { self.openFullScreen(); self.settings.$pageWrapper.hide(); } }); } |
To:
1 2 3 4 5 6 7 8 9 10 |
if (this.isTouchEnabled && this.settings.isFullscreen) { this.settings.$element.on('tap', '.fotorama__stage__frame', function () { var translate = getTranslate($(this).parents('.fotorama__stage__shaft')); if (translate[1] === '0' && !$(this).hasClass('fotorama-video-container')) { self.openFullScreen(); self.settings.$pageWrapper.hide(); } }); } |
This problem is based on lib/web/mage/gallery/gallery.js file.
[crayon-63d3e2d83792a188138780/] Using above fucntion Images can be imported directly from...
Override view block using di.xml and add the below code...
You can check a list of called layout XML for...
Follow the below steps to install and set up PWA...
If you want to remove all leading zero's from order,...
Let our Magento expert connect to discuss your requirement.
We offer Magento
certified developers.
Our Magento clientele
is 500+.
We sign NDA for the
security of your projects.
We’ve performed 100+
Magento migration projects.
Free quotation
on your project.
Three months warranty on
code developed by us.