new Dialog(options)
Parameters:
Name | Type | Description | |||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
options |
* |
Properties
|
Extends
Methods
-
close()
-
Close the dialog
-
getContentElement()
-
Get dialog content element
Returns:
- Type
- Element
-
getInputs()
-
Get inputs, textarea an select of the dialog by classname
Returns:
a {key:value} list of Elements by classname
- Type
- Object
-
hide()
-
Close the dialog
-
isOpen()
-
The dialog is shown
Returns:
true if a dialog is open
- Type
- bool
-
open()
-
Open the dialog
-
setContent(options)
-
Set the dialog content
Parameters:
Name Type Description options
* Properties
Name Type Argument Description content
Element | String dialog content
title
string title of the dialog
className
string dialog class name
max
number if not null add a progress bar to the dialog
progress
number set the progress bar value
buttons
Object a key/value list of button to show
onButton
function <optional>
a function that takes the button id and a list of input by className
-
setContentMessage(content)
-
Set the dialog content
Parameters:
Name Type Description content
Element | String dialog content
-
setProgress(val, max, message)
-
Set progress
Parameters:
Name Type Description val
number | boolean the progress value or false to hide the progressBar
max
number message
string | element -
setTitle(content)
-
Set the dialog title
Parameters:
Name Type Description content
Element | String dialog content
-
show(options)
-
Show a new dialog
Parameters:
Name Type Description options
* | Element | string options or a content to show
Properties
Name Type Argument Description content
Element | String dialog content
title
string title of the dialog
className
string dialog class name
autoclose
number a delay in ms before auto close
hideOnBack
boolean close dialog when click the background
max
number if not null add a progress bar to the dialog
progress
number set the progress bar value
buttons
Object a key/value list of button to show
onButton
function <optional>
a function that takes the button id and a list of input by className