import * as i0 from '@angular/core'; import { TemplateRef, Type, OnInit, EventEmitter, ViewContainerRef, Injector } from '@angular/core'; import * as i6 from '@angular/cdk/overlay'; import { OverlayRef, OverlayContainer, Overlay, OverlayConfig } from '@angular/cdk/overlay'; import { Subject } from 'rxjs'; import * as i5 from '@angular/common'; import * as i7 from '@obliczeniowo/elementary/buttons'; import * as i8 from '@obliczeniowo/elementary/icons'; interface OverlayCloseEvent { type: 'backdropClick' | 'close'; data: R; } declare class DialogOverlayRef { overlay: OverlayRef; content: string | TemplateRef | Type; data: T | undefined; afterClosed: Subject>; constructor(overlay: OverlayRef, content: string | TemplateRef | Type, data: T | undefined); close(data?: R | undefined): void; private _close; } declare class DialogComponent implements OnInit { private readonly ref; private readonly overlayContainer; private static dialogsCount; private static onOpen; static onClose(overlayContainer: HTMLElement): void; closed: EventEmitter; afterClosed: Subject; contentType: 'template' | 'string' | 'component'; content: string | TemplateRef | Type; context: any; viewContainerRef: ViewContainerRef; protected component: any; constructor(ref: DialogOverlayRef, overlayContainer: OverlayContainer); close(): void; ngOnInit(): void; ngOnDestroy(): void; get template(): TemplateRef; private createComponent; private _close; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵcmp: i0.ɵɵComponentDeclaration; } declare class DialogHeaderComponent { closeAction: EventEmitter; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵcmp: i0.ɵɵComponentDeclaration; } declare class DialogService { private readonly overlay; private readonly injector; constructor(overlay: Overlay, injector: Injector); open(content: string | TemplateRef | Type, options?: { data?: T; config?: OverlayConfig; }): DialogOverlayRef; createInjector(ref: DialogOverlayRef, inj: Injector): Injector; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵprov: i0.ɵɵInjectableDeclaration; } interface OverlayConfigExt extends OverlayConfig { /** external option to add some own data to modal */ data?: any; } /** * A simple dialog wrapper to use with ng-content to make a job done * * @example * * *
Life or die make your choice
*
* * *
*
* * */ declare class DialogWrapperComponent implements OnInit { private readonly dialog; header: i0.InputSignal; closed: EventEmitter; cancel: EventEmitter; template: TemplateRef; data: any; protected opened: boolean; protected dialogRef: DialogOverlayRef | undefined; constructor(dialog: DialogService); ngOnInit(): void; ngOnDestroy(): void; open(config?: OverlayConfigExt): void; close(): void; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵcmp: i0.ɵɵComponentDeclaration; } /** * Just message dialog that you can use by HTML: * * @example * * * * Live or die make your choice * * * * * * * * */ declare class MessageDialogComponent { header: i0.InputSignal; protected dialog: DialogWrapperComponent; data: any; open(config?: OverlayConfigExt | undefined): void; close(): void; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵcmp: i0.ɵɵComponentDeclaration; } declare class DialogsModule { static ɵfac: i0.ɵɵFactoryDeclaration; static ɵmod: i0.ɵɵNgModuleDeclaration; static ɵinj: i0.ɵɵInjectorDeclaration; } export { DialogComponent, DialogHeaderComponent, DialogService, DialogWrapperComponent, DialogsModule, MessageDialogComponent }; export type { OverlayConfigExt };