@c8y/ngx-components
Version:
Angular modules for Cumulocity IoT applications
57 lines • 2.3 kB
TypeScript
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: If template is instance of HTMLElement (for example, node compiled by angularJS) then there can be
* only single instance rendered, as only one instance of HTMLElement can exist in DOM.
* If there is need for displaying same element multiple times, please make sure to inject into
* this element createCopy function, which should return another instance of given 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, false, never>;
}
//# sourceMappingURL=outlet.directive.d.ts.map