Skip to content
This repository has been archived by the owner on Jan 13, 2025. It is now read-only.

fix(ripple): Relax deduplication conditions for touch devices #1990

Merged
merged 1 commit into from
Jan 18, 2018

Conversation

kfranqueiro
Copy link
Contributor

This fixes problems where a ripple surface would show the ripple twice on touch events, observable on ripple.html on Chrome on Android or Chrome on desktop with device emulation enabled.

The issue is fixed by relaxing the delay to 300ms to match tap delay on touch devices, and by removing the event x/y coordinate comparisons, as apparently sometimes the coordinates can change from the original user-initiated touch event to the simulated mouse event fired by the user agent.

@codecov-io
Copy link

Codecov Report

Merging #1990 into master will decrease coverage by <.01%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1990      +/-   ##
==========================================
- Coverage   99.43%   99.43%   -0.01%     
==========================================
  Files          84       84              
  Lines        3718     3717       -1     
  Branches      486      485       -1     
==========================================
- Hits         3697     3696       -1     
  Misses         21       21
Impacted Files Coverage Δ
packages/mdc-ripple/constants.js 100% <ø> (ø) ⬆️
packages/mdc-ripple/foundation.js 100% <100%> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 31aa288...c02aaaa. Read the comment docs.

Copy link
Contributor

@patrickrodee patrickrodee left a comment

Choose a reason for hiding this comment

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

LGTM

@kfranqueiro kfranqueiro merged commit 450a699 into master Jan 18, 2018
@kfranqueiro kfranqueiro deleted the fix/ripple-touch-dedupe branch January 18, 2018 23:31
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants