import { Component, OnInit, Input, Output, EventEmitter } from '@angular/core'; @Component({ selector: 'app-custom-button', templateUrl: './custom-button.component.html', styleUrls: ['./custom-button.component.scss'] }) export class CustomButtonComponent implements OnInit { @Input() data: { label: string; type: string, class: string }; @Input() disabled: boolean; @Output() btnClicked = new EventEmitter(); /** * Emits the click event to the parent */ onBtnClicked() { this.btnClicked.emit(); } constructor() {} ngOnInit() {} }