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

Paper ripple shouldn't be executed when scrolling over paper-ripple elements. #37

Open
AndreasGalster opened this issue Apr 1, 2015 · 3 comments

Comments

@AndreasGalster
Copy link

When you scroll through a website for example on mobile and you have paper ripple elements and you place your finger exactly on that element to scroll, a paper ripple executes. This shouldn't happen IMO since the user did never intend to click the button. He's scrolling. This is confusing the user and also fires core-transitionend when you don't want it to happen.

@aktasmehmet
Copy link

I am facing exactly the same problem. Still waiting for a fix

@dixitcy
Copy link

dixitcy commented Jun 8, 2015

Yea me too, seems like a pretty basic issue . Is there a way around using touch/gestures ?

@aktasmehmet
Copy link

I did a workaround for this, put a 0,5 second timeout when scrolling. So I can set a variable called "scrolling" to true. By doing this, you can stop ripple effect using core-transitionend callback of the item paper-ripple used. Maybe not a perfect solution but may help to someone else.

    window.onscroll = function (e) {
          scrolling = true;
          clearTimeout(scrollTimeout);
          scrollTimeout = setTimeout(function(){ notScrolling = true; }, 500);
    };

    <div on-core-transitionend="{{rippleFinished}}"><paper-ripple fit></paper-ripple></div>

    rippleFinished: function(e, detail, sender){ ... }

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants