UNPKG

@c8y/ngx-components

Version:

Angular modules for Cumulocity IoT applications

55 lines 2.22 kB
import { ElementRef, Injector, Renderer2, TemplateRef, Type, ViewContainerRef } from '@angular/core'; import * as i0 from "@angular/core"; /** * Directive to set a DOM node, a TemplateRef or any Component to a container or any node. * ```html * <div *c8yOutlet="template"></div> * <div *c8yOutlet="DeviceStatusComponent; properties: { node }"></div> * <div *c8yOutlet="nodes"></div> * ``` * * Note: When passing a native `HTMLElement`, be aware that a single element instance can only exist in one * place in the DOM. If you need to render the same element in multiple locations, the passed element * should have a `createCopy` function that returns a new instance or a clone of the element. */ export declare class OutletDirective { private viewContainer; private injector; private renderer; private el; private properties; private _element; private _template; constructor(viewContainer: ViewContainerRef, injector: Injector, renderer: Renderer2, el: ElementRef); /** * Directive to set a `DOM node`, a `TemplateRef` or any `Component` to a container or any node. * ```html * <div *c8yOutlet="template"></div> * <div *c8yOutlet="DeviceStatusComponent; properties: { node }"></div> * <div *c8yOutlet="nodes"></div> * ``` */ set c8yOutlet(template: TemplateRef<any> | Type<any> | Element); /** * Additional properties that should be added to the component * instance. */ set c8yOutletProperties(value: any); /** * Allows to use a different injector. */ set c8yOutletInjector(value: Injector); /** * @ignore */ ngOnChanges(): void; /** * @ignore */ ngOnDestroy(): void; private render; private destroy; static ɵfac: i0.ɵɵFactoryDeclaration<OutletDirective, never>; static ɵdir: i0.ɵɵDirectiveDeclaration<OutletDirective, "[c8yOutlet]", never, { "c8yOutlet": { "alias": "c8yOutlet"; "required": false; }; "c8yOutletProperties": { "alias": "c8yOutletProperties"; "required": false; }; "c8yOutletInjector": { "alias": "c8yOutletInjector"; "required": false; }; }, {}, never, never, true, never>; } //# sourceMappingURL=outlet.directive.d.ts.map