From c2d42f286e7a3f708db80e032dc7ad9f3566677c Mon Sep 17 00:00:00 2001 From: Bernd Schoolmann Date: Wed, 7 Jan 2026 16:20:23 +0100 Subject: [PATCH] Add error toast for upgrade encryption step (#18161) --- .../prompt-migration-password.component.ts | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/libs/angular/src/key-management/encrypted-migration/prompt-migration-password.component.ts b/libs/angular/src/key-management/encrypted-migration/prompt-migration-password.component.ts index 59fec1a6f70..91e1ef56e13 100644 --- a/libs/angular/src/key-management/encrypted-migration/prompt-migration-password.component.ts +++ b/libs/angular/src/key-management/encrypted-migration/prompt-migration-password.component.ts @@ -6,6 +6,7 @@ import { filter, firstValueFrom, map } from "rxjs"; import { JslibModule } from "@bitwarden/angular/jslib.module"; import { AccountService } from "@bitwarden/common/auth/abstractions/account.service"; import { MasterPasswordUnlockService } from "@bitwarden/common/key-management/master-password/abstractions/master-password-unlock.service"; +import { I18nService } from "@bitwarden/common/platform/abstractions/i18n.service"; import { LinkModule, AsyncActionsModule, @@ -15,6 +16,7 @@ import { DialogService, FormFieldModule, IconButtonModule, + ToastService, } from "@bitwarden/components"; /** @@ -40,6 +42,8 @@ export class PromptMigrationPasswordComponent { private formBuilder = inject(FormBuilder); private masterPasswordUnlockService = inject(MasterPasswordUnlockService); private accountService = inject(AccountService); + private toastService = inject(ToastService); + private i18nService = inject(I18nService); migrationPasswordForm = this.formBuilder.group({ masterPassword: ["", [Validators.required]], @@ -73,6 +77,10 @@ export class PromptMigrationPasswordComponent { userId, )) ) { + this.toastService.showToast({ + variant: "error", + message: this.i18nService.t("incorrectPassword"), + }); return; }