mirror of
https://github.com/bitwarden/browser
synced 2026-02-15 07:54:55 +00:00
replace click event with bitDialogClose
This commit is contained in:
@@ -42,7 +42,7 @@
|
||||
</div>
|
||||
</span>
|
||||
<ng-container bitDialogFooter>
|
||||
<button bitButton buttonType="primary" type="button" (click)="runReport()">
|
||||
<button bitButton buttonType="primary" type="button" [bitDialogClose]="true">
|
||||
{{ "riskInsightsInitPromptRunReport" | i18n }}
|
||||
</button>
|
||||
</ng-container>
|
||||
|
||||
@@ -1,12 +1,6 @@
|
||||
import { Component, inject } from "@angular/core";
|
||||
import { Component } from "@angular/core";
|
||||
|
||||
import {
|
||||
ButtonModule,
|
||||
DialogModule,
|
||||
DialogRef,
|
||||
DialogService,
|
||||
TypographyModule,
|
||||
} from "@bitwarden/components";
|
||||
import { ButtonModule, DialogModule, DialogService, TypographyModule } from "@bitwarden/components";
|
||||
import { I18nPipe } from "@bitwarden/ui-common";
|
||||
|
||||
@Component({
|
||||
@@ -14,14 +8,7 @@ import { I18nPipe } from "@bitwarden/ui-common";
|
||||
imports: [ButtonModule, DialogModule, TypographyModule, I18nPipe],
|
||||
})
|
||||
export class FirstReportPromptDialogComponent {
|
||||
private dialogRef = inject(DialogRef);
|
||||
|
||||
static open(dialogService: DialogService) {
|
||||
return dialogService.open<boolean>(FirstReportPromptDialogComponent);
|
||||
}
|
||||
|
||||
runReport(): void {
|
||||
// Simply close the dialog with 'true' to indicate user wants to run report
|
||||
this.dialogRef.close(true);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user