diff --git a/lib/web/mage/gallery/gallery.js b/lib/web/mage/gallery/gallery.js index 245f08f824bd9cb0ab063778b0b328e1d96a59a2..75594a9dfd0c5f0a7980b3fcd3830946e4afd24e 100644 --- a/lib/web/mage/gallery/gallery.js +++ b/lib/web/mage/gallery/gallery.js @@ -90,13 +90,15 @@ define([ this.initApi(); this.setupBreakpoints(); this.initFullscreenSettings(); - this.settings.$element.on('click', '.fotorama__stage__frame', function () { - $('[data-gallery-role="gallery"]').data('fotorama').requestFullScreen(); - $('[data-gallery-role="fotorama__fullscreen-icon"]').css({ - opacity: 1, - visibility: 'visible', - display: 'block' - }); + this.settings.$element.on('mouseup', '.fotorama__stage__frame', function () { + if (!$(this).parents('.fotorama__shadows--left').length) { + $('[data-gallery-role="gallery"]').data('fotorama').requestFullScreen(); + $('[data-gallery-role="fotorama__fullscreen-icon"]').css({ + opacity: 1, + visibility: 'visible', + display: 'block' + }); + } }); },