projects/ng-dynamic-forms/core/src/lib/directive/dynamic-template.directive.ts
Selector | ng-template[modelId],ng-template[modelType] |
Properties |
|
Inputs |
constructor(templateRef: TemplateRef
|
||||||
Parameters :
|
align | |
Type : string
|
|
Default value : DYNAMIC_TEMPLATE_DIRECTIVE_ALIGNMENT.End
|
|
as | |
Type : string | null
|
|
Default value : null
|
|
index | |
Type : number | undefined
|
|
modelId | |
Type : string
|
|
modelType | |
Type : string
|
|
Public templateRef |
Type : TemplateRef<any>
|
import { Directive, Input, TemplateRef } from "@angular/core";
export enum DYNAMIC_TEMPLATE_DIRECTIVE_ALIGNMENT {
Start = "START",
End = "END"
}
@Directive({
selector: "ng-template[modelId],ng-template[modelType]"
})
export class DynamicTemplateDirective {
@Input() align: string = DYNAMIC_TEMPLATE_DIRECTIVE_ALIGNMENT.End;
@Input() as: string | null = null;
@Input() index: number | undefined;
@Input() modelId: string;
@Input() modelType: string;
constructor(public templateRef: TemplateRef<any>) {
}
}