import { Type } from '@vendure/common/lib/shared-types';
import { Observable } from 'rxjs';
import { OverlayHostService } from '../overlay-host/overlay-host.service';
import { Dialog, DialogConfig, ModalOptions } from './modal.types';
import * as i0 from "@angular/core";
/**
* @description
* This service is responsible for instantiating a ModalDialog component and
* embedding the specified component within.
*
* @docsCategory services
* @docsPage ModalService
* @docsWeight 0
*/
export declare class ModalService {
private overlayHostService;
constructor(overlayHostService: OverlayHostService);
/**
* @description
* Create a modal from a component. The component must implement the {@link Dialog} interface.
* Additionally, the component should include templates for the title and the buttons to be
* displayed in the modal dialog. See example:
*
* @example
* ```ts
* class MyDialog implements Dialog {
* resolveWith: (result?: any) => void;
*
* okay() {
* doSomeWork().subscribe(result => {
* this.resolveWith(result);
* })
* }
*
* cancel() {
* this.resolveWith(false);
* }
* }
* ```
*
* @example
* ```html
*
* My Content *
* *