@progress/kendo-angular-dialog
Version:
Dialog Package for Angular
66 lines (65 loc) • 2.21 kB
TypeScript
/**-----------------------------------------------------------------------------------------
* Copyright © 2025 Progress Software Corporation. All rights reserved.
* Licensed under commercial license. See LICENSE.md in the project root for more information
*-------------------------------------------------------------------------------------------*/
import { ComponentFactoryResolver } from '@angular/core';
import { WindowSettings } from './models/window-settings';
import { WindowContainerService } from '../window/window-container.service';
import { WindowRef } from './models/window-ref';
import * as i0 from "@angular/core";
/**
* A service for opening Windows dynamically
* ([see example]({% slug service_window %})).
*/
export declare class WindowService {
/**
* @hidden
*/
private resolver;
private containerService;
constructor(
/**
* @hidden
*/
resolver: ComponentFactoryResolver, containerService: WindowContainerService);
/**
* Opens a Window component.
*
* @param {WindowSettings} settings - The settings that define the Window.
* @returns {WindowRef} - A reference to the Window object.
*
* @example
*
* ```ts-no-run
* _@Component({
* selector: 'my-app',
* template: `
* <button kendoButton (click)="open()">Open window</button>
* <div kendoWindowContainer></div>
* `
* })
* export class AppComponent {
* constructor( private windowService: WindowService ) {}
*
* public open() {
* var window = this.windowService.open({
* title: "My window",
* content: "My content!"
* });
*
* window.result.subscribe((result) => {
* if (result instanceof WindowCloseResult) {
* console.log("Window was closed");
* }
* });
* }
* }
* ```
*
*/
open(settings: WindowSettings): WindowRef;
private applyOptions;
private contentFrom;
static ɵfac: i0.ɵɵFactoryDeclaration<WindowService, never>;
static ɵprov: i0.ɵɵInjectableDeclaration<WindowService>;
}