Skip to content
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 disappears when creating a modal during the hidden event of an existing modal #162

Closed
dtognazzini opened this issue Oct 5, 2017 · 1 comment
Assignees
Labels
enhancement potential improvement

Comments

@dtognazzini
Copy link
Contributor

I am opening a new modal in the event handler for the 'hidden' event of a closing modal. This works fine, however, there is a race with the overlay/backdrop whereby the new modal shows without the backdrop.

The race is the same as described in #30. The order of events:

  1. existing modal is hidden
  2. hidden event is fired
  3. new modal is created
  • new modal doesn't create overlay due to the check here. This check ensures there aren't two overlays created.
  1. the timeout in hide from the existing modal removes the overlay (here).

PR coming shortly.

@thednp thednp added the enhancement potential improvement label Oct 5, 2017
@thednp
Copy link
Owner

thednp commented Oct 5, 2017

Great work, thanks for the contribution.

@thednp thednp closed this as completed Oct 5, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement potential improvement
Projects
None yet
Development

No branches or pull requests

2 participants