26 lines
597 B
TypeScript
26 lines
597 B
TypeScript
|
|
import { Component, EventEmitter, Input, Output } from '@angular/core';
|
||
|
|
import { Button } from 'primeng/button';
|
||
|
|
|
||
|
|
@Component({
|
||
|
|
selector: 'app-form-footer-actions',
|
||
|
|
templateUrl: './form-footer-actions.component.html',
|
||
|
|
imports: [Button],
|
||
|
|
})
|
||
|
|
export class FormFooterActionsComponent {
|
||
|
|
@Input() submitLabel = 'تایید';
|
||
|
|
@Input() cancelLabel = 'لغو';
|
||
|
|
@Input() loading = false;
|
||
|
|
@Output() onSubmit = new EventEmitter<void>();
|
||
|
|
@Output() onCancel = new EventEmitter<void>();
|
||
|
|
|
||
|
|
constructor() {}
|
||
|
|
|
||
|
|
submit() {
|
||
|
|
this.onSubmit.emit();
|
||
|
|
}
|
||
|
|
|
||
|
|
cancel() {
|
||
|
|
this.onCancel.emit();
|
||
|
|
}
|
||
|
|
}
|