Signed-off-by: Ricardo Marques <rimarques@suse.com>
-<button type="submit"
+<button [type]="type"
class="btn btn-sm btn-primary tc_submitButton"
[disabled]="loading"
(click)="submit()">
})
export class SubmitButtonComponent implements OnInit {
@Input() form: FormGroup;
+ @Input() type = 'submit';
@Output() submitAction = new EventEmitter();
loading = false;
focusButton() {
this.elRef.nativeElement.offsetParent.querySelector(
- 'button[type="submit"]'
+ `button[type="${this.type}"]`
).focus();
}