1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-21 10:43:35 +00:00

Merge branch 'master' into soft-delete

This commit is contained in:
Chad Scharf
2020-05-08 09:26:43 -04:00
11 changed files with 85 additions and 14 deletions

View File

@@ -684,6 +684,9 @@ export class VaultComponent implements OnInit, OnDestroy {
this.platformUtilsService.copyToClipboard(value);
this.toasterService.popAsync('info', null,
this.i18nService.t('valueCopied', this.i18nService.t(labelI18nKey)));
if (this.action === 'view') {
this.messagingService.send('minimizeOnCopy');
}
});
}

View File

@@ -12,7 +12,9 @@ import { CipherService } from 'jslib/abstractions/cipher.service';
import { CryptoService } from 'jslib/abstractions/crypto.service';
import { EventService } from 'jslib/abstractions/event.service';
import { I18nService } from 'jslib/abstractions/i18n.service';
import { MessagingService } from 'jslib/abstractions/messaging.service';
import { PlatformUtilsService } from 'jslib/abstractions/platformUtils.service';
import { StorageService } from 'jslib/abstractions/storage.service';
import { TokenService } from 'jslib/abstractions/token.service';
import { TotpService } from 'jslib/abstractions/totp.service';
import { UserService } from 'jslib/abstractions/user.service';
@@ -35,7 +37,8 @@ export class ViewComponent extends BaseViewComponent implements OnChanges {
cryptoService: CryptoService, platformUtilsService: PlatformUtilsService,
auditService: AuditService, broadcasterService: BroadcasterService,
ngZone: NgZone, changeDetectorRef: ChangeDetectorRef,
userService: UserService, eventService: EventService) {
userService: UserService, eventService: EventService,
private messagingService: MessagingService, private storageService: StorageService) {
super(cipherService, totpService, tokenService, i18nService, cryptoService, platformUtilsService,
auditService, window, broadcasterService, ngZone, changeDetectorRef, userService, eventService);
}
@@ -48,4 +51,9 @@ export class ViewComponent extends BaseViewComponent implements OnChanges {
this.platformUtilsService.eventTrack('View Password History');
this.onViewCipherPasswordHistory.emit(this.cipher);
}
copy(value: string, typeI18nKey: string, aType: string) {
super.copy(value, typeI18nKey, aType);
this.messagingService.send('minimizeOnCopy');
}
}