Lightweight modal designed to be easily ported to SPA frameworks et al.
Classes
Methods
(static) .destroy()
Remove event listeners and close all open modals.
(static) .hideModal(modalID)
Hides all modals or specific modalID
Parameters:
Name | Type | Description |
---|---|---|
modalID |
string | ID of modal to hide (optional) |
(static) .showModal(modalID)
Displays a modal
Parameters:
Name | Type | Description |
---|---|---|
modalID |
string | event | ID of modal to show or click event who's target contains a data-modal-id attribute |