Class: QuickModal

QuickModal(parameters, bodyopt)

QuickModal class used for the QuickModal plugin

Constructor

new QuickModal(parameters, bodyopt)

Creates an instance of QuickModal
Parameters:
Name Type Attributes Description
parameters Object | String Parameters holder. Use a String if you want a quick initialization
Properties
Name Type Attributes Default Description
darkenBackground Boolean <optional>
true Should the QuickModal darken the background when shown?
isForm Boolean <optional>
true Is the QuickModal a form?
keepHidden Boolean <optional>
false Keep the modal hidden instead of destroying it
form Object <optional>
Form properties holder
Properties
Name Type Attributes Description
action String <optional>
Form URL
method String <optional>
Form METHOD attribute (GET/POST/...)
id String <optional>
Form ID
classes Array.<String> <optional>
Form classes
submit String <optional>
Form submit button text
closeText String <optional>
OK Close button text
classes Array.<String> <optional>
QuickModal classes
attributes Object.<String, String> <optional>
QuickModal attributes
header String Header content
body Array.<Object> Body content
footer Array.<Object> Footer content
document Document <optional>
Document in which the QuickModal should be opened into, window.document is used by default
afterOpen function <optional>
Callback called after the QuickModal gets displayed
beforeClose function <optional>
Callback called before the QuickModal closes
onSubmit function <optional>
Callback called when the QuickModal form gets submitted
body String <optional>
Body content if you want a quick initialization
Source:

Members

id

This ID is unique at the time it's accessed
Source:

Methods

(static) destroy(id)

Removes any QuickModal mutation from the DOM
Parameters:
Name Type Description
id Integer The targeted QuickModal id
Source:

close() → {Promise}

Closes the QuickModal
Source:
Returns:
A promise resolved once the QuickModal is fully hidden
Type
Promise

destroy()

Removes any QuickModal mutation from the DOM
Source:

open() → {Promise}

Opens the QuickModal
Source:
Returns:
A promise resolved once the QuickModal is fully displayed
Type
Promise