Skip to content

Commit

Permalink
MAGETWO-55608: [GITHUB] M2.1: Not scrollable picture on mobile / prod…
Browse files Browse the repository at this point in the history
…uct page #5302
  • Loading branch information
omiroshnichenko committed Sep 15, 2016
1 parent 9e93eed commit 7597a52
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 4 deletions.
10 changes: 8 additions & 2 deletions lib/web/fotorama/fotorama.js
Original file line number Diff line number Diff line change
Expand Up @@ -1433,8 +1433,14 @@ fotoramaVersion = '4.6.4';
xWin = (tail.go || tail.x || xyDiff >= 0) && !tail.noSwipe,
yWin = xyDiff < 0;

stopEvent(e);
(options.onMove || noop).call(el, e, {touch: touchFLAG});
if (touchFLAG && !tail.checked) {
if (touchEnabledFLAG = xWin) {
stopEvent(e);
}
} else {
stopEvent(e);
(options.onMove || noop).call(el, e, {touch: touchFLAG});
}

if (!moved && Math.sqrt(Math.pow(xDiff, 2) + Math.pow(yDiff, 2)) > tolerance) {
moved = true;
Expand Down
Loading

15 comments on commit 7597a52

@jessp855
Copy link

@jessp855 jessp855 commented on 7597a52 Sep 26, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi Guys,

Is there any fix update on this issue? I still encounter this problem on my magento 2.1.1 mobile template on product view page.

@LucScu
Copy link

@LucScu LucScu commented on 7597a52 Sep 27, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jessp855 i tried this fix and it works.

@adam-kb
Copy link

@adam-kb adam-kb commented on 7597a52 Oct 3, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I found this works when js files are not minified nor concatenated. However in a production type environment the issue is still present.

@Ctucker9233
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Works on 2.1.2 production environment.

@lucasalfaro
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can´t get it to work on production environment. In my test account was fast and simple.

I have done this:

  • apply above changes to lib/web/fotorama/fotorama.js and lib/web/fotorama/fotorama.min.js
  • apply changes to vendor/magento/magento2-base/lib/web/fotorama/fotorama.js and vendor/magento/magento2-base/lib/web/fotorama/fotorama.min.js

Is this correct?

@LucScu
Copy link

@LucScu LucScu commented on 7597a52 Nov 14, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@lucasalfaro /magento2-base/lib/ js files are not executed, they are copied from composer to /lib/, so is useless change them.

@erikhansen
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Applying this commit as a patch to my environment fixed the issue for me. I tested while Magento was in production mode. I have JS merging set to "Yes", but I have JS bundling and minification set to "No".

@yofisim
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

After replacing the following files on M2.1.1 on dev environment, with no cache enabled. Fix is not working. At least, not for everyone.

@kunzi
Copy link

@kunzi kunzi commented on 7597a52 Dec 1, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This fixed our problem after setting the Minify Javascript Files to No in Magento settings.

@kunzi
Copy link

@kunzi kunzi commented on 7597a52 Dec 6, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jmtakahashi Yes still working on Android phone + Chrome incognito mode after reloading page multiple times.

@jmtakahashi
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@kunzi thank you. this must be a bug in my Magento 2.1.2, or something to do with the iphone. After 1 reload (slider scroll stopped working). I will remove my comments.

@zchking
Copy link

@zchking zchking commented on 7597a52 Dec 9, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks , this works on Magento 2.1.2.

@CPGupta
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, its working in Magento version 2.1.2.

@Anshu-Mishra
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is not working for me in Magento version 2.1.2.

@CPGupta
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Once you change in above js files, make sure you have removed pub/static/frontend folder and deployed content. It might cache issues of browser.
php bin/magento setup:static-content:deploy

Please sign in to comment.