bootstrap-multimodal
Version:
A Bootstrap plugin that adds support for multiple open modals.
29 lines (20 loc) • 820 B
Markdown
A Bootstrap plugin that adds support for multiple open modals.
[](http://www.bootply.com/cObcYInvpq)
`npm install bootstrap-multimodal`
`bower install bootstrap-multimodal`
Simply include `js/multimodal.js` (or the minified version).
That's it! You don't have to make any calls to initiate the behavior.
If you need to override or prevent the behavior on certain modals, add an event listener for the `show.bs.modal` and `hidden.bs.modal` events and either return false or call `stopPropagation` on the event.
```js
$('#my-modal').on('show.bs.modal', function(e) {
e.stopPropagation();
});
$('#my-modal').on('hidden.bs.modal', function(e) {
e.stopPropagation();
});
```