jakiestfu / Snap.js

A Library for creating beautiful mobile shelfs in Javascript (Facebook and Path style side menus)
http://jakiestfu.github.io/Snap.js/
5.99k stars 666 forks source link

nested data-snap-ignore="true" unpredictable on Android 5 #257

Closed eyalkatz closed 9 years ago

eyalkatz commented 9 years ago

This is supposed to prevent snap.js from sliding inside the div. Using this with marking nested elements, sometimes it works when it's not supposed to, and some other times doesn't work hen it is supposed to.

Then sometimes it seems to block my div's from scrolling altogether. Only on Android 5.

eyalkatz commented 9 years ago

Turns out it was not snap.js's fault.. but my hammer.js settings:

This is what finally solved the problem, along with simplifying properties, etc.:

Hammer.defaults.stop_browser_behavior.touchAction = 'pan-y';

It was an issue with the hammer.js plugin with touchAction property. This affects some browsers - and apparently also Android 5 (but doesn't affect Android 4.* when using PhoneGap).

Not as simple as it seems, more details here: https://github.com/hammerjs/hammer.js/wiki/How-to-fix-Chrome-35--and-IE10--scrolling-(touch-action)