-
Notifications
You must be signed in to change notification settings - Fork 47.1k
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
Fix onMouseEnter is fired on disabled buttons #17675
Conversation
This pull request is automatically built and testable in CodeSandbox. To see build info of the built libraries, click here or the icon next to each commit SHA. Latest deployment of this branch, based on commit 64336e9:
|
should |
@benbot Unlike I 'll be doing deeper research these days. Meanwhile, this could a useful workaround for someone. |
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.
👍
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.
This seems okay to me. Ideally we should remove all the custom disabled
logic and come up with a better solution in the future for the event system, but for now this should fix this issues at hand.
This fixes #4251 as well, right? |
What if you want to display tooltip / help text why user cannot perform action connected with disabled button when user hovers the button? (my real world case). The fix should be to make
|
Can you please file a new issue to discuss? |
This pull request fixes issue #17229. I modified
shouldPreventMouseEvent
function to includeonMouseEnter
and added a new test toReactBrowserEventEmmiter-test
.