1
0
mirror of https://github.com/bitwarden/browser synced 2026-01-06 10:33:57 +00:00

Replace toaster library (#1322)

This commit is contained in:
Oscar Hinton
2021-12-07 19:41:45 +00:00
committed by GitHub
parent 35a7d6434a
commit d5c0783619
87 changed files with 336 additions and 508 deletions

View File

@@ -8,8 +8,6 @@ import {
} from '@angular/core';
import { Router } from '@angular/router';
import { ToasterService } from 'angular2-toaster';
import { ApiService } from 'jslib-common/abstractions/api.service';
import { CryptoService } from 'jslib-common/abstractions/crypto.service';
import { I18nService } from 'jslib-common/abstractions/i18n.service';
@@ -73,7 +71,7 @@ export class OrganizationPlansComponent implements OnInit {
plans: PlanResponse[];
constructor(private apiService: ApiService, private i18nService: I18nService,
private toasterService: ToasterService, platformUtilsService: PlatformUtilsService,
private platformUtilsService: PlatformUtilsService,
private cryptoService: CryptoService, private router: Router, private syncService: SyncService,
private policyService: PolicyService, private userService: UserService, private logService: LogService) {
this.selfHosted = platformUtilsService.isSelfHost();
@@ -271,10 +269,10 @@ export class OrganizationPlansComponent implements OnInit {
orgId = await this.createCloudHosted(key, collectionCt, orgKeys, shareKey[1]);
}
this.toasterService.popAsync('success', this.i18nService.t('organizationCreated'), this.i18nService.t('organizationReadyToGo'));
this.platformUtilsService.showToast('success', this.i18nService.t('organizationCreated'), this.i18nService.t('organizationReadyToGo'));
} else {
orgId = await this.updateOrganization(orgId);
this.toasterService.popAsync('success', null, this.i18nService.t('organizationUpgraded'));
this.platformUtilsService.showToast('success', null, this.i18nService.t('organizationUpgraded'));
}
await this.apiService.refreshIdentityToken();