import { Component, OnInit, Input, EventEmitter, Output } from '@angular/core'; import { ActionOptions } from '../../model/componets'; @Component({ selector: 'ngx-action-item-view', templateUrl: './action-item-view.component.html', styleUrls: ['./action-item-view.component.scss'], }) export class ActionItemViewComponent implements OnInit { @Input() source: ActionOptions; @Input() item: any; @Input() actionType: any; @Output() actionTypeChange: EventEmitter = new EventEmitter(); public get type(): string { return this.actionType; } public set type(value: string) { this.actionType = value; this.actionTypeChange.emit(value); } constructor() { } ngOnInit() { // console.log(JSON.stringify(this.item)); } }