-
Notifications
You must be signed in to change notification settings - Fork 841
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
Overlay Mask child element onClick event bubble up #3429
Comments
I think the solution depends on: @cchaos how do we want consumers to think about the overlay mask:
If the first, the answer here might be for the consumer to The second two (and maybe we still do it for the first) would require the proposed solution within EUI |
@chandlerprall @cchaos |
I ran around in circles about the correct "implementation" for the behavior but couldn't come up with a solid solution so instead I'll just describe the expected behavior: Consumer provides So this seems to me, that the component should manage when to perform the |
@TAYTS with all of that, we'll take your suggestion with one modification: will need to compare |
@chandlerprall I have created the PR(#3462) |
Hi, may I know is it possible to add a check on the event target for the
OverlayMask
component to preventonClick
getting triggered by the bubbling up of the child element's click event?The use case is that I was trying to allow both the
EuiOverlayMask
andEuiModal
's close button to close the modal. However, when I tried to submit the modal form, theEuiOverlayMask
'sonClick
got triggered by the bubbling of the click event from the modal submit button.eui/src/components/overlay_mask/overlay_mask.tsx
Lines 52 to 54 in 84bbe8d
Suggestion:
The text was updated successfully, but these errors were encountered: