[fixed] pointer events in iOS
ClosedPublic

Authored by appsforartists on Mar 7 2017, 6:47 PM.

Details

Summary

The current prototype of createDragStream() uses streams of Pointer Events to create a drag stream. Pointer Events are not natively supported by Safari, but can be polyfilled.

To receive pointermove events, an element must set its touch-action to none. In native implementations, an ancestor view can have touch-action: none and its pointermove listener will receive events. However, there's a bug in the polyfill that won't propagate pointermove if a child has touch-action set to something other than none.

Thus, instead of setting touch-action: none for draggable views and touch-action: auto others, we omit touch-action entirely unless it needs to be explicitly set.

Closes https://github.com/material-motion/material-motion-js/issues/153

Diff Detail

Repository
R13 material-motion/material-motion-js
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
appsforartists created this revision.Mar 7 2017, 6:47 PM
Restricted Application completed building Restricted Buildable.Mar 7 2017, 6:47 PM
appsforartists planned changes to this revision.Mar 7 2017, 6:47 PM
Restricted Application failed to build Restricted Buildable!Mar 7 2017, 6:52 PM

I ran WIP by mistake

Restricted Application failed to build Restricted Buildable!Mar 7 2017, 6:59 PM
featherless accepted this revision.Mar 7 2017, 7:41 PM
featherless added a subscriber: featherless.

This diff could benefit from an explanation of what the original problem was and how this diff solves it.

This revision is now accepted and ready to land.Mar 7 2017, 7:41 PM
appsforartists retitled this revision from [fixed] touch events in iOS to [fixed] pointer events in iOS.Mar 7 2017, 7:48 PM
appsforartists edited the summary of this revision. (Show Details)

Explanation added.

Rebasing on ts-loader

Restricted Application completed building Restricted Buildable.Mar 22 2017, 8:50 PM
appsforartists edited the summary of this revision. (Show Details)Mar 23 2017, 11:37 PM
This revision was automatically updated to reflect the committed changes.