@voerro/vue-modal

A flexible & responsive modal component for Vue.js 2 by Voerro

View on Github

Dynamic Modals

Customize Buttons

Modals can have as many buttons as you need, each with a unique handler/action. A button without a handler simply closes the modal.


Loading Modal's Body via AJAX

This works as a regular modal, except you need to provide a URL to fetch the content instead of a body.


Inline Modals

You can also define multiple modals inline with Vue slots. Each modal should have a unique id. Open this page's source code and find the two <modal> blocks defining these modals if you want to see how it works.


Hiding Modals Programmatically


Options

Undismissible Modals. An undismissible modal can not be dismissed by pressing on the close button or on the overlay outside the modal. An action (a button click) is required to close the modal.

No Header

Prevent Default Button's Action. By default the active modal will be closed after you press on any of the buttons (even if that button has a handler). Luckily, you can prevent that.