-
Notifications
You must be signed in to change notification settings - Fork 2.1k
(ripple): No blur after focus on mobile #809
Comments
Thanks for reporting this @touficbatache! So what looks like is happening is the background doesn't fade out the first time the ripple is activated, but does on each subsequent time. Definitely a bug. |
Yes, it doesn't fade only the first time. Forgot to mention that 😄😅 |
Is someone working on this? @amsheehan @traviskaufman |
More specifically, this happens initially upon a ripple target receiving focus when it didn't already have it. Repeated taps when already focused behave fine, but if you blur again and re-focus, the same problem occurs. Moreover, when testing with timestamps in Chrome's console in device emulation mode, I notice that not only does the addClass from the focus handler fire after the removeClass from |
Hey @kfranqueiro, I was testing the ripple in the Chrome's console in device emulation mode. I can see the removeClass from |
I did some tests in desktop mode and in device emulation mode, I used the compiled JavaScript file, added a breakpoint on On desktop, those are the functions it calls in order:
Everything is back to normal On mobile, those are the functions it calls in order:(Those are the result if you click on the ripple element the first time, when you click again step 2 returns false for the 1st one and true for the second)
Everything is back to normal but the element is still focused To conclude, the difference is that on mobile it calls the EDIT:The problem is |
On http://material-components-web.appspot.com/ripple.html using
The problem here is that on mobile devices Luckily,
This change affects only mouse-/touch-related focusing, I tried to:
In all cases Please let me know if I should submit a PR for this change. |
The recent design and development work on States for hover/focus/press styles has resulted in simplifying MDC Ripple logic to no longer forcibly suppress focus styles after press (see #1784), and instead adhere more naturally to native browser behavior (since the element is still actually focused). As a result, this issue is obsolete, since there is no longer inconsistency in how focus is represented. Thanks @anton-kachurin and @touficbatache for investigating the current behavior. It's useful to have this information for historical purposes and future reference. |
Bug
What MDC-Web Version are you using?
What browser(s) is this bug affecting?
What OS are you using?
What are the steps to reproduce the bug?
What is the expected behavior?
What is the actual behavior?
Any other information you believe would be useful?
EDIT
The text was updated successfully, but these errors were encountered: