Topic: Modal Stacking
davesmacer pro premium priority asked a year ago
I wanted to ask if there's a way of stacking modals (open modal on top of a modal and maybe on top of another modal). I'm playing with z-index, but the problem is basically that the .modal-backdrop is not related to each modal, so there is no way of knowing with certainty which backdrop belongs to which modal.
Best Regards
Kamila Pieńkowska staff answered a year ago
davesmacer pro premium priority answered a year ago
I want to use invasive one to block everything else on the page, even previous modals
Kamila Pieńkowska staff commented a year ago
It is not possible. When using a regular modal opening new will close the previous one. If you try to cheat and open two modals with JS you will get one modal and two backdrops, out of which one will not disappear when clicked.
davesmacer pro premium priority commented a year ago
It is possible, I did it. I wanted to show a "Please wait" modal on top of another modal that asks for user input. They are both blocking and they appear on top of each other. even made it so that I can stack them as much as I want. Sorry to hear you can't.
FREE CONSULTATION
Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.
Answered
- User: Pro
- Premium support: Yes
- Technology: MDB Standard
- MDB Version: MDB5 6.4.2
- Device: Laptop
- Browser: Chrome
- OS: Windows
- Provided sample code: No
- Provided link: No