Modal Backdrop
Bootstrap 5 Backdrop
Backdrop options for a responsive popup with Bootstrap 5. Prevent close on click outside with static backdrop, remove backdrop, enable interactivity & more.
Basic example
Default modal backdrop is a delicate shadow overlaying the rest of the page design.
Static Backdrop
If you would like to prevent the modal from closing on a click outside of the modal boundries, you can set the
data-mdb-backdrop
attribute to static
.
No Backdrop
If you would like to get rid of the backdrop, you can set the
data-mdb-backdrop
attribute to false
.
Remove backdrop (with interactivity)
This type of modal does not block any interaction on the page. Simply set data-mdb-modal-non-invasive
to true.