@serenity-is/corelib / ConfirmDialogOptions
Interface: ConfirmDialogOptions
Additional options for confirm dialog
Hierarchy
-
↳
ConfirmDialogOptions
Table of contents
Properties
- autoDispose
- autoOpen
- backdrop
- buttons
- cancelButton
- centered
- closeButton
- closeOnEscape
- dialogClass
- element
- fade
- fullScreen
- htmlEncode
- modal
- onCancel
- onClose
- onNo
- onOpen
- preWrap
- preferBSModal
- preferPanel
- providerOptions
- scrollable
- size
- title
- width
Properties
autoDispose
• Optional autoDispose: boolean
Auto dispose dialog on close, default is true
Inherited from
MessageDialogOptions.autoDispose
Defined in
autoOpen
• Optional autoOpen: boolean
True to auto open dialog
Inherited from
Defined in
backdrop
• Optional backdrop: boolean | "static"
Backdrop type, static to make it modal, e.g. can't be closed by clicking outside
Inherited from
Defined in
buttons
• Optional buttons: DialogButton[]
List of buttons to show on the dialog
Inherited from
Defined in
cancelButton
• Optional cancelButton: boolean
True to also add a cancel button
Defined in
centered
• Optional centered: boolean
Vertically center modal
Inherited from
Defined in
closeButton
• Optional closeButton: boolean
Show close button, default is true
Inherited from
MessageDialogOptions.closeButton
Defined in
closeOnEscape
• Optional closeOnEscape: boolean
Close dialog on escape key. Default is true for message dialogs.
Inherited from
MessageDialogOptions.closeOnEscape
Defined in
dialogClass
• Optional dialogClass: string
CSS class to use for all dialog types. Is added to the top ui-dialog, panel or modal element
Inherited from
MessageDialogOptions.dialogClass
Defined in
element
• Optional element: HTMLElement | ArrayLike<HTMLElement> | (element: HTMLElement) => void
Dialog content/body element, or callback that will populate the content element
Inherited from
Defined in
fade
• Optional fade: boolean
Enable / disable animation. Default is false for message dialogs, true for other dialogs
Inherited from
Defined in
fullScreen
• Optional fullScreen: boolean | "sm-down" | "md-down" | "lg-down" | "xl-down" | "xxl-down"
Sets one of modal-fullscreen{-...-down} classes. Only used for bootstrap modals
Inherited from
MessageDialogOptions.fullScreen
Defined in
htmlEncode
• Optional htmlEncode: boolean
HTML encode the message, default is true
Inherited from
MessageDialogOptions.htmlEncode
Defined in
modal
• Optional modal: boolean
Modal option for jQuery UI dialog compatibility only. Not to be confused with Bootstrap modal.
Inherited from
Defined in
onCancel
• Optional onCancel: () => void
Event handler for cancel button click
Type declaration
▸ (): void
Returns
void
Defined in
onClose
• Optional onClose: (result: string, e?: Event) => void
Event handler that is called when dialog is closed
Type declaration
▸ (result, e?): void
Parameters
| Name | Type |
|---|---|
result |
string |
e? |
Event |
Returns
void
Inherited from
Defined in
onNo
• Optional onNo: () => void
Event handler for no button click
Type declaration
▸ (): void
Returns
void
Defined in
onOpen
• Optional onOpen: (e?: Event) => void
Event handler that is called when dialog is opened
Type declaration
▸ (e?): void
Parameters
| Name | Type |
|---|---|
e? |
Event |
Returns
void
Inherited from
Defined in
preWrap
• Optional preWrap: boolean
Wrap the message in a <pre> element, so that line endings are preserved, default is true
Inherited from
Defined in
preferBSModal
• Optional preferBSModal: boolean
Prefer Bootstrap modals to jQuery UI dialogs when both are available
Inherited from
MessageDialogOptions.preferBSModal
Defined in
preferPanel
• Optional preferPanel: boolean
Prefer Panel even when Modal / jQuery UI is available
Inherited from
MessageDialogOptions.preferPanel
Defined in
providerOptions
• Optional providerOptions: (type: DialogType, opt: DialogOptions) => any
Callback to get options specific to the dialog provider type
Type declaration
▸ (type, opt): any
Parameters
| Name | Type |
|---|---|
type |
DialogType |
opt |
DialogOptions |
Returns
any
Inherited from
MessageDialogOptions.providerOptions
Defined in
scrollable
• Optional scrollable: boolean
Scrollable, sets content of the modal to scrollable, only for Bootstrap
Inherited from
MessageDialogOptions.scrollable
Defined in
size
• Optional size: "sm" | "md" | "lg" | "xl"
Size. Default is null for (500px) message dialogs, lg for normal dialogs
Inherited from
Defined in
title
• Optional title: string
Dialog title
Inherited from
Defined in
width
• Optional width: number
Only used for jQuery UI dialogs for backwards compatibility