diff --git a/src/app/app.component.ts b/src/app/app.component.ts index 96a5744810..c85f4e4b62 100644 --- a/src/app/app.component.ts +++ b/src/app/app.component.ts @@ -217,6 +217,15 @@ export class AppComponent implements OnInit { this.openModal(PremiumComponent, this.premiumRef); } break; + case 'emailVerificationRequired': + const emailVerificationConfirmed = await this.platformUtilsService.showDialog( + this.i18nService.t('emailVerificationRequiredDesc'), + this.i18nService.t('emailVerificationRequired'), + this.i18nService.t('learnMore'), this.i18nService.t('cancel')); + if (emailVerificationConfirmed) { + this.platformUtilsService.launchUri('https://bitwarden.com/help/article/create-bitwarden-account/'); + } + break; case 'syncVault': try { await this.syncService.fullSync(true, true); diff --git a/src/app/send/add-edit.component.ts b/src/app/send/add-edit.component.ts index 6b38b73d98..4a8230925a 100644 --- a/src/app/send/add-edit.component.ts +++ b/src/app/send/add-edit.component.ts @@ -8,6 +8,7 @@ import { MessagingService } from 'jslib/abstractions/messaging.service'; import { PlatformUtilsService } from 'jslib/abstractions/platformUtils.service'; import { PolicyService } from 'jslib/abstractions/policy.service'; import { SendService } from 'jslib/abstractions/send.service'; +import { TokenService } from 'jslib/abstractions'; import { UserService } from 'jslib/abstractions/user.service'; import { AddEditComponent as BaseAddEditComponent } from 'jslib/angular/components/send/add-edit.component'; @@ -20,9 +21,9 @@ export class AddEditComponent extends BaseAddEditComponent { constructor(i18nService: I18nService, platformUtilsService: PlatformUtilsService, environmentService: EnvironmentService, datePipe: DatePipe, sendService: SendService, userService: UserService, - messagingService: MessagingService, policyService: PolicyService) { + messagingService: MessagingService, policyService: PolicyService, tokenService: TokenService) { super(i18nService, platformUtilsService, environmentService, - datePipe, sendService, userService, messagingService, policyService); + datePipe, sendService, userService, messagingService, policyService, tokenService); } async refresh() { diff --git a/src/locales/en/messages.json b/src/locales/en/messages.json index ead20bfbdc..c80c9d0400 100644 --- a/src/locales/en/messages.json +++ b/src/locales/en/messages.json @@ -1662,5 +1662,11 @@ }, "sendOptionsPolicyInEffect": { "message": "One or more organization policies are affecting your Send options." + }, + "emailVerificationRequired": { + "message": "Email Verification Required" + }, + "emailVerificationRequiredDesc": { + "message": "You must verify your email to use this feature." } }