ユーザーが無効になっているアクションボタンをクリックしたときにダイアログが閉じないようにしたい。
<mat-dialog-actions>
<lib-button mat-dialog-close>{{ cancel }}</lib-button>
<lib-button [disabled]="isFormInvalid" [mat-dialog-close]="data.form">{{
confirm }}</lib-button>
</mat-dialog-actions>
図書館:
<button
mat-button
[type]="type"
[ngClass]="matType"
[color]="backgroundColor"
[fxFlex]="setFxFlex ? 'auto' : 'initial'"
[disabled]="disabled"
(click)="onClick.emit($event)"
[style.height]="size"
[style.width]="size"
>
<lib-icon *ngIf="materialIcon">
{{ materialIcon }}
</lib-icon>
<ng-content></ng-content>
</button>
これはコードであり、動作することを期待していましたが、動作しません。ボタンは無効として表示されますが、ユーザーがクリックするとダイアログが閉じます。
どんなリードでも大歓迎です、ありがとう。