diff options
Diffstat (limited to 'usecaseui-portal/src/app/shared/components/description/descriptions-item.component.ts')
-rw-r--r-- | usecaseui-portal/src/app/shared/components/description/descriptions-item.component.ts | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/usecaseui-portal/src/app/shared/components/description/descriptions-item.component.ts b/usecaseui-portal/src/app/shared/components/description/descriptions-item.component.ts new file mode 100644 index 00000000..9f168f02 --- /dev/null +++ b/usecaseui-portal/src/app/shared/components/description/descriptions-item.component.ts @@ -0,0 +1,28 @@ + +import { Component, Input, OnInit, TemplateRef, ViewChild, OnDestroy } from '@angular/core'; +import { Subject } from 'rxjs'; + +@Component({ + selector: 'app-descriptions-item', + template: ` + <ng-template> + <ng-content></ng-content> + </ng-template> + `, +}) +export class DescriptionItemComponent implements OnDestroy { + @ViewChild(TemplateRef) content: TemplateRef<void>; + @Input() nzSpan: number = 1; + @Input() nzTitle: string = ''; + + readonly inputChange$ = new Subject<void>(); + + ngOnChanges(): void { + this.inputChange$.next(); + } + + ngOnDestroy(): void { + this.inputChange$.complete(); + } + +} |