, handler: (e?: Event) => void, opt?: {
+ before?: boolean;
+ oneOff?: boolean;
+ }): void;
+ /** Opens the dialog */
+ open(): this;
+ /** Gets the title text of the dialog */
+ title(): string;
+ /** Sets the title text of the dialog. */
+ title(value: string): this;
+ /** Returns the type of the dialog, or null if no dialog on the current element or if the element is null, e.g. dialog was disposed */
+ get type(): DialogProviderType;
+ /** Gets the body/content element of the dialog */
+ getContentNode(): HTMLElement;
+ /** Gets the dialog element of the dialog */
+ getDialogNode(): HTMLElement;
+ /** Gets the node that receives events for the dialog. It's .ui-dialog-content, .modal, or .panel-body */
+ getEventsNode(): HTMLElement;
+ /** Gets the footer element of the dialog */
+ getFooterNode(): HTMLElement;
+ /** Gets the header element of the dialog */
+ getHeaderNode(): HTMLElement;
+ private onButtonClick;
+ private createBSButtons;
+ private createBSModal;
+ private createPanel;
+ private createUIDialog;
+ /**
+ * Disposes the dialog, removing it from the DOM and unbinding all event handlers.
+ */
+ dispose(): void;
}
/** Returns true if Bootstrap modal is available */
-declare function hasBSModal(): boolean;
+export declare function hasBSModal(): boolean;
/** Returns true if jQuery UI dialog is available */
-declare function hasUIDialog(): boolean;
+export declare function hasUIDialog(): boolean;
/** Calls Bootstrap button.noConflict method if both jQuery UI and Bootstrap buttons are available in the page */
-declare function uiAndBSButtonNoConflict(): void;
+export declare function uiAndBSButtonNoConflict(): void;
/**
* Creates a dialog button which, by default, has "Yes" as caption (localized) and "ok" as the result.
* @param opt - Optional configuration for the dialog button.
* @returns The dialog button with the specified configuration.
*/
-declare function okDialogButton(opt?: DialogButton): DialogButton;
+export declare function okDialogButton(opt?: DialogButton): DialogButton;
/**
* Creates a dialog button which, by default, has "Yes" as the caption (localized) and "yes" as the result.
* @param opt - Optional configuration for the dialog button.
* @returns The dialog button with the specified configuration.
*/
-declare function yesDialogButton(opt?: DialogButton): DialogButton;
+export declare function yesDialogButton(opt?: DialogButton): DialogButton;
/**
* Creates a dialog button which, by default, has "No" as the caption (localized) and "no" as the result.
* @param opt - Optional configuration for the dialog button.
* @returns The dialog button with the specified configuration.
*/
-declare function noDialogButton(opt?: DialogButton): DialogButton;
+export declare function noDialogButton(opt?: DialogButton): DialogButton;
/**
* Creates a dialog button which, by default, has "Cancel" as the caption (localized) and "cancel" as the result.
* @param opt - Optional configuration for the dialog button.
* @returns The dialog button with the specified configuration.
*/
-declare function cancelDialogButton(opt?: DialogButton): DialogButton;
+export declare function cancelDialogButton(opt?: DialogButton): DialogButton;
/**
* Namespace containing localizable text constants for dialogs.
*/
-declare namespace DialogTexts {
- /**
- * Title for alert dialogs.
- */
- const AlertTitle: string;
- /**
- * Text for the cancel button in dialogs.
- */
- const CancelButton: string;
- /**
- * Text for the close button in dialogs.
- */
- const CloseButton: string;
- /**
- * Title for confirmation dialogs.
- */
- const ConfirmationTitle: string;
- /**
- * Title for information dialogs.
- */
- const InformationTitle: string;
- /**
- * Hint for maximizing dialogs.
- */
- const MaximizeHint: string;
- /**
- * Text for the "No" button in dialogs.
- */
- const NoButton: string;
- /**
- * Text for the "OK" button in dialogs.
- */
- const OkButton: string;
- /**
- * Hint for restoring dialogs.
- */
- const RestoreHint: string;
- /**
- * Title for success dialogs.
- */
- const SuccessTitle: string;
- /**
- * Title for warning dialogs.
- */
- const WarningTitle: string;
- /**
- * Text for the "Yes" button in dialogs.
- */
- const YesButton: string;
+export declare namespace DialogTexts {
+ /**
+ * Title for alert dialogs.
+ */
+ const AlertTitle: string;
+ /**
+ * Text for the cancel button in dialogs.
+ */
+ const CancelButton: string;
+ /**
+ * Text for the close button in dialogs.
+ */
+ const CloseButton: string;
+ /**
+ * Title for confirmation dialogs.
+ */
+ const ConfirmationTitle: string;
+ /**
+ * Title for information dialogs.
+ */
+ const InformationTitle: string;
+ /**
+ * Hint for maximizing dialogs.
+ */
+ const MaximizeHint: string;
+ /**
+ * Text for the "No" button in dialogs.
+ */
+ const NoButton: string;
+ /**
+ * Text for the "OK" button in dialogs.
+ */
+ const OkButton: string;
+ /**
+ * Hint for restoring dialogs.
+ */
+ const RestoreHint: string;
+ /**
+ * Title for success dialogs.
+ */
+ const SuccessTitle: string;
+ /**
+ * Title for warning dialogs.
+ */
+ const WarningTitle: string;
+ /**
+ * Text for the "Yes" button in dialogs.
+ */
+ const YesButton: string;
}
/**
* Options that apply to all message dialog types
*/
-interface MessageDialogOptions extends DialogOptions {
- /** HTML encode the message, default is true */
- htmlEncode?: boolean;
- /** Wrap the message in a `` element, so that line endings are preserved, default is true */
- preWrap?: boolean;
+export interface MessageDialogOptions extends DialogOptions {
+ /** HTML encode the message, default is true */
+ htmlEncode?: boolean;
+ /** Wrap the message in a `` element, so that line endings are preserved, default is true */
+ preWrap?: boolean;
}
/**
* Displays an alert dialog
@@ -564,15 +559,15 @@ interface MessageDialogOptions extends DialogOptions {
* @example
* alertDialog("An error occured!"); }
*/
-declare function alertDialog(message: string, options?: MessageDialogOptions): Partial