import { DialogRef, ModalComponent, CloseGuard } from 'angular2-modal'; import { BSModalContext } from 'angular2-modal/plugins/bootstrap'; export declare class ConfirmationDialogData extends BSModalContext { title: string; body: string; okCallback: any; cancelCallBack: any; } export declare class CustomDialogData extends BSModalContext { title: string; body: string; buttons: Array; } /** * A Sample of how simple it is to create a new window, with its own injects. */ export declare class ConfirmationDialog implements CloseGuard, ModalComponent { dialog: DialogRef; context: ConfirmationDialogData; constructor(dialog: DialogRef); okCallback: () => void; cancelCallback: () => void; close: () => void; beforeDismiss(): boolean; beforeClose(): boolean; } /** *** Custom dialog **/ export interface IDialogButton { name: string; clickHandler: Function; isPrimary: boolean; } export interface CustomDialogScope { title: string; body: string; buttons: Array; close: () => void; } export declare class CustomDialog implements CloseGuard, ModalComponent { dialog: DialogRef; context: CustomDialogData; scope: CustomDialogScope; beforeDismiss?(): boolean | Promise; beforeClose?(): boolean | Promise; constructor(dialog: DialogRef); close: () => void; }