1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-22 11:13:46 +00:00

Bump jslib (#1776)

This commit is contained in:
Oscar Hinton
2021-04-07 20:43:07 +02:00
committed by GitHub
parent ae4c1b29d2
commit 97ac4a3267
5 changed files with 13 additions and 11 deletions

View File

@@ -1,12 +1,13 @@
import { CipherService } from 'jslib/abstractions/cipher.service';
import { I18nService } from 'jslib/abstractions/i18n.service';
import { ConsoleLogService } from 'jslib/services/consoleLog.service';
import { SearchService } from 'jslib/services/search.service';
export class PopupSearchService extends SearchService {
constructor(private mainSearchService: SearchService, cipherService: CipherService,
consoleLogService: ConsoleLogService) {
super(cipherService, consoleLogService);
consoleLogService: ConsoleLogService, i18nService: I18nService) {
super(cipherService, consoleLogService, i18nService);
}
clearIndex() {

View File

@@ -68,7 +68,8 @@ function getBgService<T>(service: string) {
export const stateService = new StateService();
export const messagingService = new BrowserMessagingService();
export const searchService = new PopupSearchService(getBgService<SearchService>('searchService')(),
getBgService<CipherService>('cipherService')(), getBgService<ConsoleLogService>('consoleLogService')());
getBgService<CipherService>('cipherService')(), getBgService<ConsoleLogService>('consoleLogService')(),
getBgService<I18nService>('i18nService')());
export function initFactory(platformUtilsService: PlatformUtilsService, i18nService: I18nService, storageService: StorageService,
popupUtilsService: PopupUtilsService): Function {
@@ -90,7 +91,7 @@ export function initFactory(platformUtilsService: PlatformUtilsService, i18nServ
let theme = await storageService.get<string>(ConstantsService.themeKey);
if (theme == null) {
theme = platformUtilsService.getDefaultSystemTheme();
theme = await platformUtilsService.getDefaultSystemTheme();
platformUtilsService.onDefaultSystemThemeChange(sysTheme => {
window.document.documentElement.classList.remove('theme_light', 'theme_dark');