UNPKG

@nova-ui/bits

Version:

SolarWinds Nova Framework

35 lines (34 loc) 1.38 kB
import { ApplicationRef, ComponentFactoryResolver } from "@angular/core"; import { ToastInjector } from "./toast-injector"; import { OverlayContainerService } from "../overlay/overlay-container.service"; import * as i0 from "@angular/core"; /** * @ignore */ export declare class ToastContainerService { private componentFactoryResolver; private overlayService; private appRef; constructor(componentFactoryResolver: ComponentFactoryResolver, overlayService: OverlayContainerService, appRef: ApplicationRef); private static getComponentRootNode; private containers; private containerElement; /** * Creates container element for position, if container already exists - returns it * @return the container element */ getContainerElement(positionClass?: string): HTMLElement; /** * Dynamically compiles toast component and attaches it to the toast container * @return reference to attached toast */ attachToast(component: any, injector: ToastInjector, newestOnTop: boolean): any; /** * Destroys component using reference to it's factory * @return reference to attached toast */ detachToast(component: any): void; private createContainer; static ɵfac: i0.ɵɵFactoryDeclaration<ToastContainerService, never>; static ɵprov: i0.ɵɵInjectableDeclaration<ToastContainerService>; }