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

Multiple Modals #34

Closed
jednano opened this issue Jan 23, 2013 · 6 comments
Closed

Multiple Modals #34

jednano opened this issue Jan 23, 2013 · 6 comments

Comments

@jednano
Copy link

jednano commented Jan 23, 2013

I know the docs say there can only be one modal at a time, but that's not what I'm finding. I have a link within a modal that opens another modal. What happens is I can stack modals over modals, but when I close the top-most one, I can't then close the others underneath it.

@kylefox
Copy link
Owner

kylefox commented Jan 25, 2013

Closing any open modals before opening a new modal might not be your ideal solution, but I think it's the simplest. It will at least prevent things from breaking.

If you have a multi-modal workflow, you might need to manage the state transitions yourself, or use a more sophisticated modal library.

@jednano
Copy link
Author

jednano commented Jan 25, 2013

So, is the documentation not correct then, in saying "there can only be one modal at a time?" It was from this statement that I concluded things weren't working as expected. What is the expected result?

@kylefox
Copy link
Owner

kylefox commented Jan 25, 2013

The documentation is correct -- there can only be one modal at a time. Now the code is more in line with the docs: if you open a new modal while a modal is open, the first one is closed.

@jednano
Copy link
Author

jednano commented Jan 25, 2013

Ah, excellent. I see the commit. Thanks and sorry for the confusion. Great job on the modal BTW.

@kylefox
Copy link
Owner

kylefox commented Jan 25, 2013

No worries, and thanks :)

@kylefox kylefox reopened this Jan 26, 2013
@kylefox
Copy link
Owner

kylefox commented Jan 26, 2013

As @BH0 pointed out my quick solution broke AJAX modal. For that reason I've reverted back to 0.5.1.

I'll give some more thought to multiple modal, but if anyone has suggestions I'm all ears.

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

No branches or pull requests

2 participants