1
0
mirror of https://github.com/bitwarden/browser.git synced 2024-11-23 11:56:00 +01:00

Merge branch 'master' into use-lock-guard

This commit is contained in:
Thomas Rittson 2021-06-09 07:39:45 +10:00
commit f4d792aa9d
3 changed files with 10 additions and 4 deletions

View File

@ -803,7 +803,10 @@
"message": "Insert your security key into your computer's USB port. If it has a button, touch it."
},
"webAuthnNewTab": {
"message": "Continue the WebAuthn 2FA verification in the new tab."
"message": "To start the WebAuthn 2FA verification. Click the button below to open a new tab and follow the instructions provided in the new tab."
},
"webAuthnNewTabOpen": {
"message": "Open new tab"
},
"webAuthnAuthenticate": {
"message": "Authenticate WebAuthn"

View File

@ -73,6 +73,7 @@
<ng-container *ngIf="selectedProviderType === providerType.WebAuthn && webAuthnNewTab">
<div class="content text-center" *ngIf="webAuthnNewTab">
<p class="text-center">{{'webAuthnNewTab' | i18n}}</p>
<button class="btn primary block" (click)="authWebAuthn()" appStopClick>{{'webAuthnNewTabOpen' | i18n}}</button>
</div>
</ng-container>
<ng-container *ngIf="selectedProviderType === providerType.Duo ||

View File

@ -67,12 +67,14 @@ function getBgService<T>(service: string) {
};
}
const isPrivateMode = BrowserApi.getBackgroundPage() == null;
const stateService = new StateService();
const messagingService = new BrowserMessagingService();
const searchService = new PopupSearchService(getBgService<SearchService>('searchService')(),
const searchService = isPrivateMode ? null : new PopupSearchService(getBgService<SearchService>('searchService')(),
getBgService<CipherService>('cipherService')(), getBgService<ConsoleLogService>('consoleLogService')(),
getBgService<I18nService>('i18nService')());
const passwordRepromptService = new PasswordRepromptService(getBgService<I18nService>('i18nService')(),
const passwordRepromptService = isPrivateMode ? null : new PasswordRepromptService(getBgService<I18nService>('i18nService')(),
getBgService<CryptoService>('cryptoService')(), getBgService<PlatformUtilsService>('platformUtilsService')());
export function initFactory(platformUtilsService: PlatformUtilsService, i18nService: I18nService, storageService: StorageService,
@ -86,7 +88,7 @@ export function initFactory(platformUtilsService: PlatformUtilsService, i18nServ
window.document.body.classList.add('body-sm');
}
if (BrowserApi.getBackgroundPage() != null) {
if (!isPrivateMode) {
await stateService.save(ConstantsService.disableFaviconKey,
await storageService.get<boolean>(ConstantsService.disableFaviconKey));