Skip to content

fix: close modal on first overlay click after stopped propagation#1081

Open
wanxiankai wants to merge 1 commit into
reactjs:masterfrom
wanxiankai:fix/overlay-click-after-content-event
Open

fix: close modal on first overlay click after stopped propagation#1081
wanxiankai wants to merge 1 commit into
reactjs:masterfrom
wanxiankai:fix/overlay-click-after-content-event

Conversation

@wanxiankai

Copy link
Copy Markdown

Fixes #1015.

Summary

  • track when a content mouse down should suppress the next overlay mouse down
  • clear stale overlay-close state only on a real overlay mouse down
  • add a regression test for a content click that stops propagation followed by an overlay click

Validation

  • npm run lint
  • NODE_OPTIONS=--openssl-legacy-provider npm run test -- --single-run

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Modal doesn't close on the first click on the overlay after click on elements containing event.stopPropagation() inside modal

1 participant