-
Notifications
You must be signed in to change notification settings - Fork 13.5k
fix(ripple-effect): ripple displays on click or touch #25102
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there a way to write a test for this?
} | ||
|
||
// Waits for the ripple effect to be added | ||
await page.waitForSelector(`${selector}.ion-activated`); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If I check the button demo on https://ionicframework.com/docs, the button receives ion-activated
for a brief moment on click, even with the busted ripple effect. Does the test fail with the broken state? 🤔
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are you possibly being served from a cache? I don't see the class added to the button element when clicking and holding on the button in the docs examples. Chrome also doesn't indicate that the class
attribute was modified during mouse down.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Happens in incognito, screencast: https://user-images.githubusercontent.com/90629384/163048183-3adafc01-3551-43a5-b6e9-962630f7df91.mp4 The class is on there as long as I have the mouse button held down.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Strange that doesn't happen on Mac 🤔 https://user-images.githubusercontent.com/13732623/163049314-6e795818-897e-464b-ba0c-ba589f0bd4fe.mp4
Anyways, I confirmed that with the changes on main
, the test suite fails. With the changes in this branch, the test suite passes.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Cool, that's what's important 👍
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great job!
Pull request checklist
Please check if your PR fulfills the following requirements:
npm run build
) was run locally and any changes were pushednpm run lint
) has passed locally and any fixes were made for failuresPull request type
Please check the type of change your PR introduces:
What is the current behavior?
The ripple effect is broken and does not display when clicking or tapping a button.
Issue URL: #25094
What is the new behavior?
Reverts the optional chaining fixes for eslint and restores the original behavior for ripple effect.
Does this introduce a breaking change?
Other information
Dev build:
6.0.17-dev.11649730310.17726968