DialogContext
Provides methods for interacting with a dialog.
interface DialogContext {
/** Gets values of inputs in the dialog */
inputs(): Dictionary<string | null>;
/** Updates the dialog */
update(opts: UpdateDialogOptions): void;
/** Closes the dialog */
close(): void;
/** Finds parts of the html content of the dialog */
find(selector: string): JQuery;
/** Whether the dialog is currently open. */
isOpen(): boolean;
/** The document that the dialog is on */
getDocument(): Document;
/** The window that the dialog is rendered on */
getWindow(): Window;
/** @deprecated Deprecated in v8.0. This method now always returns true since the library no longer does non-inline dialogs. */
isInlineDialog(): boolean;
/** Creates DOM element for a raw html string for the target window. */
$(html: any): JQuery;
/** Callback after the dialog is open and initialized */
onOpen(callback: DialogContextCallback): void;
/** Callback after the dialog is closed */
onClose(callback: DialogContextCallback): void;
/** Whether the dialog has been initialized and is ready to be accessed. */
isInitialized(): boolean;
}