mirror of
https://github.com/bitwarden/browser.git
synced 2025-01-25 21:51:30 +01:00
Merge branch 'main' into autofill/pm-8518-autofill-scripts-do-not-inject-into-sub-frames-on-install
This commit is contained in:
commit
df3ee0a3d2
@ -18,7 +18,7 @@ import {
|
|||||||
} from "../../../autofill/spec/testing-utils";
|
} from "../../../autofill/spec/testing-utils";
|
||||||
import { BrowserApi } from "../../../platform/browser/browser-api";
|
import { BrowserApi } from "../../../platform/browser/browser-api";
|
||||||
import { BrowserScriptInjectorService } from "../../../platform/services/browser-script-injector.service";
|
import { BrowserScriptInjectorService } from "../../../platform/services/browser-script-injector.service";
|
||||||
import { AbortManager } from "../../background/abort-manager";
|
import { AbortManager } from "../../../vault/background/abort-manager";
|
||||||
import { Fido2ContentScript, Fido2ContentScriptId } from "../enums/fido2-content-script.enum";
|
import { Fido2ContentScript, Fido2ContentScriptId } from "../enums/fido2-content-script.enum";
|
||||||
import { Fido2PortName } from "../enums/fido2-port-name.enum";
|
import { Fido2PortName } from "../enums/fido2-port-name.enum";
|
||||||
|
|
@ -13,7 +13,7 @@ import { VaultSettingsService } from "@bitwarden/common/vault/abstractions/vault
|
|||||||
|
|
||||||
import { BrowserApi } from "../../../platform/browser/browser-api";
|
import { BrowserApi } from "../../../platform/browser/browser-api";
|
||||||
import { ScriptInjectorService } from "../../../platform/services/abstractions/script-injector.service";
|
import { ScriptInjectorService } from "../../../platform/services/abstractions/script-injector.service";
|
||||||
import { AbortManager } from "../../background/abort-manager";
|
import { AbortManager } from "../../../vault/background/abort-manager";
|
||||||
import { Fido2ContentScript, Fido2ContentScriptId } from "../enums/fido2-content-script.enum";
|
import { Fido2ContentScript, Fido2ContentScriptId } from "../enums/fido2-content-script.enum";
|
||||||
import { Fido2PortName } from "../enums/fido2-port-name.enum";
|
import { Fido2PortName } from "../enums/fido2-port-name.enum";
|
||||||
|
|
@ -60,7 +60,7 @@ describe("Fido2 Content Script", () => {
|
|||||||
chrome.runtime.connect = jest.fn(() => portSpy);
|
chrome.runtime.connect = jest.fn(() => portSpy);
|
||||||
|
|
||||||
it("destroys the messenger when the port is disconnected", () => {
|
it("destroys the messenger when the port is disconnected", () => {
|
||||||
require("./content-script");
|
require("./fido2-content-script");
|
||||||
|
|
||||||
triggerPortOnDisconnectEvent(portSpy);
|
triggerPortOnDisconnectEvent(portSpy);
|
||||||
|
|
||||||
@ -75,7 +75,7 @@ describe("Fido2 Content Script", () => {
|
|||||||
const mockResult = { credentialId: "mock" } as CreateCredentialResult;
|
const mockResult = { credentialId: "mock" } as CreateCredentialResult;
|
||||||
jest.spyOn(chrome.runtime, "sendMessage").mockResolvedValue(mockResult);
|
jest.spyOn(chrome.runtime, "sendMessage").mockResolvedValue(mockResult);
|
||||||
|
|
||||||
require("./content-script");
|
require("./fido2-content-script");
|
||||||
|
|
||||||
const response = await messenger.handler!(message, new AbortController());
|
const response = await messenger.handler!(message, new AbortController());
|
||||||
|
|
||||||
@ -99,7 +99,7 @@ describe("Fido2 Content Script", () => {
|
|||||||
data: mock<InsecureCreateCredentialParams>(),
|
data: mock<InsecureCreateCredentialParams>(),
|
||||||
});
|
});
|
||||||
|
|
||||||
require("./content-script");
|
require("./fido2-content-script");
|
||||||
|
|
||||||
await messenger.handler!(message, new AbortController());
|
await messenger.handler!(message, new AbortController());
|
||||||
|
|
||||||
@ -121,7 +121,7 @@ describe("Fido2 Content Script", () => {
|
|||||||
const abortController = new AbortController();
|
const abortController = new AbortController();
|
||||||
const abortSpy = jest.spyOn(abortController.signal, "removeEventListener");
|
const abortSpy = jest.spyOn(abortController.signal, "removeEventListener");
|
||||||
|
|
||||||
require("./content-script");
|
require("./fido2-content-script");
|
||||||
|
|
||||||
await messenger.handler!(message, abortController);
|
await messenger.handler!(message, abortController);
|
||||||
|
|
||||||
@ -141,7 +141,7 @@ describe("Fido2 Content Script", () => {
|
|||||||
abortController.abort();
|
abortController.abort();
|
||||||
});
|
});
|
||||||
|
|
||||||
require("./content-script");
|
require("./fido2-content-script");
|
||||||
|
|
||||||
await messenger.handler!(message, abortController);
|
await messenger.handler!(message, abortController);
|
||||||
|
|
||||||
@ -161,7 +161,7 @@ describe("Fido2 Content Script", () => {
|
|||||||
const abortController = new AbortController();
|
const abortController = new AbortController();
|
||||||
jest.spyOn(chrome.runtime, "sendMessage").mockResolvedValue({ error: errorMessage });
|
jest.spyOn(chrome.runtime, "sendMessage").mockResolvedValue({ error: errorMessage });
|
||||||
|
|
||||||
require("./content-script");
|
require("./fido2-content-script");
|
||||||
const result = messenger.handler!(message, abortController);
|
const result = messenger.handler!(message, abortController);
|
||||||
|
|
||||||
await expect(result).rejects.toEqual(errorMessage);
|
await expect(result).rejects.toEqual(errorMessage);
|
||||||
@ -175,7 +175,7 @@ describe("Fido2 Content Script", () => {
|
|||||||
contentType: "application/json",
|
contentType: "application/json",
|
||||||
}));
|
}));
|
||||||
|
|
||||||
require("./content-script");
|
require("./fido2-content-script");
|
||||||
|
|
||||||
expect(messengerForDOMCommunicationSpy).not.toHaveBeenCalled();
|
expect(messengerForDOMCommunicationSpy).not.toHaveBeenCalled();
|
||||||
});
|
});
|
||||||
@ -193,7 +193,7 @@ describe("Fido2 Content Script", () => {
|
|||||||
},
|
},
|
||||||
}));
|
}));
|
||||||
|
|
||||||
require("./content-script");
|
require("./fido2-content-script");
|
||||||
|
|
||||||
expect(messengerForDOMCommunicationSpy).not.toHaveBeenCalled();
|
expect(messengerForDOMCommunicationSpy).not.toHaveBeenCalled();
|
||||||
});
|
});
|
@ -13,7 +13,7 @@ describe("FIDO2 page-script for manifest v2", () => {
|
|||||||
it("skips appending the `page-script.js` file if the document contentType is not `text/html`", () => {
|
it("skips appending the `page-script.js` file if the document contentType is not `text/html`", () => {
|
||||||
Object.defineProperty(window.document, "contentType", { value: "text/plain", writable: true });
|
Object.defineProperty(window.document, "contentType", { value: "text/plain", writable: true });
|
||||||
|
|
||||||
require("./page-script-append.mv2");
|
require("./fido2-page-script-append.mv2");
|
||||||
|
|
||||||
expect(window.document.createElement).not.toHaveBeenCalled();
|
expect(window.document.createElement).not.toHaveBeenCalled();
|
||||||
});
|
});
|
||||||
@ -24,7 +24,7 @@ describe("FIDO2 page-script for manifest v2", () => {
|
|||||||
return node;
|
return node;
|
||||||
});
|
});
|
||||||
|
|
||||||
require("./page-script-append.mv2");
|
require("./fido2-page-script-append.mv2");
|
||||||
|
|
||||||
expect(window.document.createElement).toHaveBeenCalledWith("script");
|
expect(window.document.createElement).toHaveBeenCalledWith("script");
|
||||||
expect(chrome.runtime.getURL).toHaveBeenCalledWith(Fido2ContentScript.PageScript);
|
expect(chrome.runtime.getURL).toHaveBeenCalledWith(Fido2ContentScript.PageScript);
|
||||||
@ -42,7 +42,7 @@ describe("FIDO2 page-script for manifest v2", () => {
|
|||||||
return node;
|
return node;
|
||||||
});
|
});
|
||||||
|
|
||||||
require("./page-script-append.mv2");
|
require("./fido2-page-script-append.mv2");
|
||||||
|
|
||||||
expect(window.document.createElement).toHaveBeenCalledWith("script");
|
expect(window.document.createElement).toHaveBeenCalledWith("script");
|
||||||
expect(chrome.runtime.getURL).toHaveBeenCalledWith(Fido2ContentScript.PageScript);
|
expect(chrome.runtime.getURL).toHaveBeenCalledWith(Fido2ContentScript.PageScript);
|
||||||
@ -59,7 +59,7 @@ describe("FIDO2 page-script for manifest v2", () => {
|
|||||||
return createdScriptElement;
|
return createdScriptElement;
|
||||||
});
|
});
|
||||||
|
|
||||||
require("./page-script-append.mv2");
|
require("./fido2-page-script-append.mv2");
|
||||||
|
|
||||||
jest.spyOn(createdScriptElement, "remove");
|
jest.spyOn(createdScriptElement, "remove");
|
||||||
createdScriptElement.dispatchEvent(new Event("load"));
|
createdScriptElement.dispatchEvent(new Event("load"));
|
@ -1,6 +1,6 @@
|
|||||||
import { FallbackRequestedError } from "@bitwarden/common/platform/abstractions/fido2/fido2-client.service.abstraction";
|
import { FallbackRequestedError } from "@bitwarden/common/platform/abstractions/fido2/fido2-client.service.abstraction";
|
||||||
|
|
||||||
import { WebauthnUtils } from "../webauthn-utils";
|
import { WebauthnUtils } from "../../../vault/fido2/webauthn-utils";
|
||||||
|
|
||||||
import { MessageType } from "./messaging/message";
|
import { MessageType } from "./messaging/message";
|
||||||
import { Messenger } from "./messaging/messenger";
|
import { Messenger } from "./messaging/messenger";
|
@ -5,7 +5,7 @@ import {
|
|||||||
createCredentialRequestOptionsMock,
|
createCredentialRequestOptionsMock,
|
||||||
setupMockedWebAuthnSupport,
|
setupMockedWebAuthnSupport,
|
||||||
} from "../../../autofill/spec/fido2-testing-utils";
|
} from "../../../autofill/spec/fido2-testing-utils";
|
||||||
import { WebauthnUtils } from "../webauthn-utils";
|
import { WebauthnUtils } from "../../../vault/fido2/webauthn-utils";
|
||||||
|
|
||||||
import { MessageType } from "./messaging/message";
|
import { MessageType } from "./messaging/message";
|
||||||
import { Messenger } from "./messaging/messenger";
|
import { Messenger } from "./messaging/messenger";
|
||||||
@ -40,7 +40,7 @@ jest.mock("./messaging/messenger", () => {
|
|||||||
},
|
},
|
||||||
};
|
};
|
||||||
});
|
});
|
||||||
jest.mock("../webauthn-utils");
|
jest.mock("../../../vault/fido2/webauthn-utils");
|
||||||
|
|
||||||
describe("Fido2 page script with native WebAuthn support", () => {
|
describe("Fido2 page script with native WebAuthn support", () => {
|
||||||
(jest.spyOn(globalThis, "document", "get") as jest.Mock).mockImplementation(
|
(jest.spyOn(globalThis, "document", "get") as jest.Mock).mockImplementation(
|
||||||
@ -54,7 +54,7 @@ describe("Fido2 page script with native WebAuthn support", () => {
|
|||||||
setupMockedWebAuthnSupport();
|
setupMockedWebAuthnSupport();
|
||||||
|
|
||||||
beforeAll(() => {
|
beforeAll(() => {
|
||||||
require("./page-script");
|
require("./fido2-page-script");
|
||||||
});
|
});
|
||||||
|
|
||||||
afterEach(() => {
|
afterEach(() => {
|
||||||
@ -154,7 +154,7 @@ describe("Fido2 page script with native WebAuthn support", () => {
|
|||||||
contentType: "json/application",
|
contentType: "json/application",
|
||||||
}));
|
}));
|
||||||
|
|
||||||
require("./content-script");
|
require("./fido2-content-script");
|
||||||
|
|
||||||
expect(Messenger.forDOMCommunication).not.toHaveBeenCalled();
|
expect(Messenger.forDOMCommunication).not.toHaveBeenCalled();
|
||||||
});
|
});
|
||||||
@ -172,7 +172,7 @@ describe("Fido2 page script with native WebAuthn support", () => {
|
|||||||
},
|
},
|
||||||
}));
|
}));
|
||||||
|
|
||||||
require("./content-script");
|
require("./fido2-content-script");
|
||||||
|
|
||||||
expect(Messenger.forDOMCommunication).not.toHaveBeenCalled();
|
expect(Messenger.forDOMCommunication).not.toHaveBeenCalled();
|
||||||
});
|
});
|
@ -4,7 +4,7 @@ import {
|
|||||||
createCredentialCreationOptionsMock,
|
createCredentialCreationOptionsMock,
|
||||||
createCredentialRequestOptionsMock,
|
createCredentialRequestOptionsMock,
|
||||||
} from "../../../autofill/spec/fido2-testing-utils";
|
} from "../../../autofill/spec/fido2-testing-utils";
|
||||||
import { WebauthnUtils } from "../webauthn-utils";
|
import { WebauthnUtils } from "../../../vault/fido2/webauthn-utils";
|
||||||
|
|
||||||
import { MessageType } from "./messaging/message";
|
import { MessageType } from "./messaging/message";
|
||||||
import { Messenger } from "./messaging/messenger";
|
import { Messenger } from "./messaging/messenger";
|
||||||
@ -39,7 +39,7 @@ jest.mock("./messaging/messenger", () => {
|
|||||||
},
|
},
|
||||||
};
|
};
|
||||||
});
|
});
|
||||||
jest.mock("../webauthn-utils");
|
jest.mock("../../../vault/fido2/webauthn-utils");
|
||||||
|
|
||||||
describe("Fido2 page script without native WebAuthn support", () => {
|
describe("Fido2 page script without native WebAuthn support", () => {
|
||||||
(jest.spyOn(globalThis, "document", "get") as jest.Mock).mockImplementation(
|
(jest.spyOn(globalThis, "document", "get") as jest.Mock).mockImplementation(
|
||||||
@ -50,7 +50,7 @@ describe("Fido2 page script without native WebAuthn support", () => {
|
|||||||
const mockCreateCredentialsResult = createCreateCredentialResultMock();
|
const mockCreateCredentialsResult = createCreateCredentialResultMock();
|
||||||
const mockCredentialRequestOptions = createCredentialRequestOptionsMock();
|
const mockCredentialRequestOptions = createCredentialRequestOptionsMock();
|
||||||
const mockCredentialAssertResult = createAssertCredentialResultMock();
|
const mockCredentialAssertResult = createAssertCredentialResultMock();
|
||||||
require("./page-script");
|
require("./fido2-page-script");
|
||||||
|
|
||||||
afterEach(() => {
|
afterEach(() => {
|
||||||
jest.resetModules();
|
jest.resetModules();
|
@ -1,7 +1,7 @@
|
|||||||
export const Fido2ContentScript = {
|
export const Fido2ContentScript = {
|
||||||
PageScript: "content/fido2/page-script.js",
|
PageScript: "content/fido2-page-script.js",
|
||||||
PageScriptAppend: "content/fido2/page-script-append-mv2.js",
|
PageScriptAppend: "content/fido2-page-script-append-mv2.js",
|
||||||
ContentScript: "content/fido2/content-script.js",
|
ContentScript: "content/fido2-content-script.js",
|
||||||
} as const;
|
} as const;
|
||||||
|
|
||||||
export const Fido2ContentScriptId = {
|
export const Fido2ContentScriptId = {
|
@ -202,6 +202,8 @@ import WebRequestBackground from "../autofill/background/web-request.background"
|
|||||||
import { CipherContextMenuHandler } from "../autofill/browser/cipher-context-menu-handler";
|
import { CipherContextMenuHandler } from "../autofill/browser/cipher-context-menu-handler";
|
||||||
import { ContextMenuClickedHandler } from "../autofill/browser/context-menu-clicked-handler";
|
import { ContextMenuClickedHandler } from "../autofill/browser/context-menu-clicked-handler";
|
||||||
import { MainContextMenuHandler } from "../autofill/browser/main-context-menu-handler";
|
import { MainContextMenuHandler } from "../autofill/browser/main-context-menu-handler";
|
||||||
|
import { Fido2Background as Fido2BackgroundAbstraction } from "../autofill/fido2/background/abstractions/fido2.background";
|
||||||
|
import { Fido2Background } from "../autofill/fido2/background/fido2.background";
|
||||||
import { AutofillService as AutofillServiceAbstraction } from "../autofill/services/abstractions/autofill.service";
|
import { AutofillService as AutofillServiceAbstraction } from "../autofill/services/abstractions/autofill.service";
|
||||||
import AutofillService from "../autofill/services/autofill.service";
|
import AutofillService from "../autofill/services/autofill.service";
|
||||||
import { SafariApp } from "../browser/safariApp";
|
import { SafariApp } from "../browser/safariApp";
|
||||||
@ -233,8 +235,6 @@ import { SyncServiceListener } from "../platform/sync/sync-service.listener";
|
|||||||
import { fromChromeRuntimeMessaging } from "../platform/utils/from-chrome-runtime-messaging";
|
import { fromChromeRuntimeMessaging } from "../platform/utils/from-chrome-runtime-messaging";
|
||||||
import VaultTimeoutService from "../services/vault-timeout/vault-timeout.service";
|
import VaultTimeoutService from "../services/vault-timeout/vault-timeout.service";
|
||||||
import FilelessImporterBackground from "../tools/background/fileless-importer.background";
|
import FilelessImporterBackground from "../tools/background/fileless-importer.background";
|
||||||
import { Fido2Background as Fido2BackgroundAbstraction } from "../vault/fido2/background/abstractions/fido2.background";
|
|
||||||
import { Fido2Background } from "../vault/fido2/background/fido2.background";
|
|
||||||
import { BrowserFido2UserInterfaceService } from "../vault/fido2/browser-fido2-user-interface.service";
|
import { BrowserFido2UserInterfaceService } from "../vault/fido2/browser-fido2-user-interface.service";
|
||||||
import { VaultFilterService } from "../vault/services/vault-filter.service";
|
import { VaultFilterService } from "../vault/services/vault-filter.service";
|
||||||
|
|
||||||
|
@ -20,11 +20,11 @@ import {
|
|||||||
openTwoFactorAuthPopout,
|
openTwoFactorAuthPopout,
|
||||||
} from "../auth/popup/utils/auth-popout-window";
|
} from "../auth/popup/utils/auth-popout-window";
|
||||||
import { LockedVaultPendingNotificationsData } from "../autofill/background/abstractions/notification.background";
|
import { LockedVaultPendingNotificationsData } from "../autofill/background/abstractions/notification.background";
|
||||||
|
import { Fido2Background } from "../autofill/fido2/background/abstractions/fido2.background";
|
||||||
import { AutofillService } from "../autofill/services/abstractions/autofill.service";
|
import { AutofillService } from "../autofill/services/abstractions/autofill.service";
|
||||||
import { BrowserApi } from "../platform/browser/browser-api";
|
import { BrowserApi } from "../platform/browser/browser-api";
|
||||||
import { BrowserEnvironmentService } from "../platform/services/browser-environment.service";
|
import { BrowserEnvironmentService } from "../platform/services/browser-environment.service";
|
||||||
import { BrowserPlatformUtilsService } from "../platform/services/platform-utils/browser-platform-utils.service";
|
import { BrowserPlatformUtilsService } from "../platform/services/platform-utils/browser-platform-utils.service";
|
||||||
import { Fido2Background } from "../vault/fido2/background/abstractions/fido2.background";
|
|
||||||
|
|
||||||
import MainBackground from "./main.background";
|
import MainBackground from "./main.background";
|
||||||
|
|
||||||
|
@ -101,7 +101,7 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"web_accessible_resources": [
|
"web_accessible_resources": [
|
||||||
"content/fido2/page-script.js",
|
"content/fido2-page-script.js",
|
||||||
"content/lp-suppress-import-download.js",
|
"content/lp-suppress-import-download.js",
|
||||||
"notification/bar.html",
|
"notification/bar.html",
|
||||||
"images/icon38.png",
|
"images/icon38.png",
|
||||||
|
@ -108,7 +108,7 @@
|
|||||||
"web_accessible_resources": [
|
"web_accessible_resources": [
|
||||||
{
|
{
|
||||||
"resources": [
|
"resources": [
|
||||||
"content/fido2/page-script.js",
|
"content/fido2-page-script.js",
|
||||||
"notification/bar.html",
|
"notification/bar.html",
|
||||||
"images/icon38.png",
|
"images/icon38.png",
|
||||||
"images/icon38_locked.png",
|
"images/icon38_locked.png",
|
||||||
|
@ -40,6 +40,7 @@ import { AboutPageV2Component } from "../tools/popup/settings/about-page/about-p
|
|||||||
import { AboutPageComponent } from "../tools/popup/settings/about-page/about-page.component";
|
import { AboutPageComponent } from "../tools/popup/settings/about-page/about-page.component";
|
||||||
import { MoreFromBitwardenPageV2Component } from "../tools/popup/settings/about-page/more-from-bitwarden-page-v2.component";
|
import { MoreFromBitwardenPageV2Component } from "../tools/popup/settings/about-page/more-from-bitwarden-page-v2.component";
|
||||||
import { MoreFromBitwardenPageComponent } from "../tools/popup/settings/about-page/more-from-bitwarden-page.component";
|
import { MoreFromBitwardenPageComponent } from "../tools/popup/settings/about-page/more-from-bitwarden-page.component";
|
||||||
|
import { ExportBrowserV2Component } from "../tools/popup/settings/export/export-browser-v2.component";
|
||||||
import { ExportBrowserComponent } from "../tools/popup/settings/export/export-browser.component";
|
import { ExportBrowserComponent } from "../tools/popup/settings/export/export-browser.component";
|
||||||
import { ImportBrowserV2Component } from "../tools/popup/settings/import/import-browser-v2.component";
|
import { ImportBrowserV2Component } from "../tools/popup/settings/import/import-browser-v2.component";
|
||||||
import { ImportBrowserComponent } from "../tools/popup/settings/import/import-browser.component";
|
import { ImportBrowserComponent } from "../tools/popup/settings/import/import-browser.component";
|
||||||
@ -243,12 +244,11 @@ const routes: Routes = [
|
|||||||
canActivate: [AuthGuard],
|
canActivate: [AuthGuard],
|
||||||
data: { state: "import" },
|
data: { state: "import" },
|
||||||
}),
|
}),
|
||||||
{
|
...extensionRefreshSwap(ExportBrowserComponent, ExportBrowserV2Component, {
|
||||||
path: "export",
|
path: "export",
|
||||||
component: ExportBrowserComponent,
|
|
||||||
canActivate: [AuthGuard],
|
canActivate: [AuthGuard],
|
||||||
data: { state: "export" },
|
data: { state: "export" },
|
||||||
},
|
}),
|
||||||
{
|
{
|
||||||
path: "autofill",
|
path: "autofill",
|
||||||
component: AutofillComponent,
|
component: AutofillComponent,
|
||||||
|
@ -0,0 +1,27 @@
|
|||||||
|
<popup-page>
|
||||||
|
<popup-header slot="header" [pageTitle]="'exportVault' | i18n" showBackButton>
|
||||||
|
<ng-container slot="end">
|
||||||
|
<app-pop-out></app-pop-out>
|
||||||
|
</ng-container>
|
||||||
|
</popup-header>
|
||||||
|
|
||||||
|
<tools-export
|
||||||
|
(formDisabled)="this.disabled = $event"
|
||||||
|
(formLoading)="this.loading = $event"
|
||||||
|
(onSuccessfulExport)="this.onSuccessfulExport($event)"
|
||||||
|
></tools-export>
|
||||||
|
|
||||||
|
<popup-footer slot="footer">
|
||||||
|
<button
|
||||||
|
[disabled]="disabled"
|
||||||
|
[loading]="loading"
|
||||||
|
form="export_form_exportForm"
|
||||||
|
bitButton
|
||||||
|
type="submit"
|
||||||
|
bitFormButton
|
||||||
|
buttonType="primary"
|
||||||
|
>
|
||||||
|
{{ "exportVault" | i18n }}
|
||||||
|
</button>
|
||||||
|
</popup-footer>
|
||||||
|
</popup-page>
|
@ -0,0 +1,40 @@
|
|||||||
|
import { CommonModule } from "@angular/common";
|
||||||
|
import { Component } from "@angular/core";
|
||||||
|
import { Router, RouterLink } from "@angular/router";
|
||||||
|
|
||||||
|
import { JslibModule } from "@bitwarden/angular/jslib.module";
|
||||||
|
import { AsyncActionsModule, ButtonModule, DialogModule } from "@bitwarden/components";
|
||||||
|
import { ExportComponent } from "@bitwarden/vault-export-ui";
|
||||||
|
|
||||||
|
import { PopOutComponent } from "../../../../platform/popup/components/pop-out.component";
|
||||||
|
import { PopupFooterComponent } from "../../../../platform/popup/layout/popup-footer.component";
|
||||||
|
import { PopupHeaderComponent } from "../../../../platform/popup/layout/popup-header.component";
|
||||||
|
import { PopupPageComponent } from "../../../../platform/popup/layout/popup-page.component";
|
||||||
|
|
||||||
|
@Component({
|
||||||
|
templateUrl: "export-browser-v2.component.html",
|
||||||
|
standalone: true,
|
||||||
|
imports: [
|
||||||
|
CommonModule,
|
||||||
|
RouterLink,
|
||||||
|
JslibModule,
|
||||||
|
DialogModule,
|
||||||
|
AsyncActionsModule,
|
||||||
|
ButtonModule,
|
||||||
|
ExportComponent,
|
||||||
|
PopupPageComponent,
|
||||||
|
PopupFooterComponent,
|
||||||
|
PopupHeaderComponent,
|
||||||
|
PopOutComponent,
|
||||||
|
],
|
||||||
|
})
|
||||||
|
export class ExportBrowserV2Component {
|
||||||
|
protected disabled = false;
|
||||||
|
protected loading = false;
|
||||||
|
|
||||||
|
constructor(private router: Router) {}
|
||||||
|
|
||||||
|
protected async onSuccessfulExport(organizationId: string): Promise<void> {
|
||||||
|
await this.router.navigate(["/vault-settings"]);
|
||||||
|
}
|
||||||
|
}
|
@ -7,7 +7,7 @@ import { Fido2Utils } from "@bitwarden/common/platform/services/fido2/fido2-util
|
|||||||
import {
|
import {
|
||||||
InsecureAssertCredentialParams,
|
InsecureAssertCredentialParams,
|
||||||
InsecureCreateCredentialParams,
|
InsecureCreateCredentialParams,
|
||||||
} from "./content/messaging/message";
|
} from "../../autofill/fido2/content/messaging/message";
|
||||||
|
|
||||||
export class WebauthnUtils {
|
export class WebauthnUtils {
|
||||||
static mapCredentialCreationOptions(
|
static mapCredentialCreationOptions(
|
||||||
|
@ -165,8 +165,8 @@ const mainConfig = {
|
|||||||
"content/notificationBar": "./src/autofill/content/notification-bar.ts",
|
"content/notificationBar": "./src/autofill/content/notification-bar.ts",
|
||||||
"content/contextMenuHandler": "./src/autofill/content/context-menu-handler.ts",
|
"content/contextMenuHandler": "./src/autofill/content/context-menu-handler.ts",
|
||||||
"content/content-message-handler": "./src/autofill/content/content-message-handler.ts",
|
"content/content-message-handler": "./src/autofill/content/content-message-handler.ts",
|
||||||
"content/fido2/content-script": "./src/vault/fido2/content/content-script.ts",
|
"content/fido2-content-script": "./src/autofill/fido2/content/fido2-content-script.ts",
|
||||||
"content/fido2/page-script": "./src/vault/fido2/content/page-script.ts",
|
"content/fido2-page-script": "./src/autofill/fido2/content/fido2-page-script.ts",
|
||||||
"notification/bar": "./src/autofill/notification/bar.ts",
|
"notification/bar": "./src/autofill/notification/bar.ts",
|
||||||
"overlay/button": "./src/autofill/overlay/pages/button/bootstrap-autofill-overlay-button.ts",
|
"overlay/button": "./src/autofill/overlay/pages/button/bootstrap-autofill-overlay-button.ts",
|
||||||
"overlay/list": "./src/autofill/overlay/pages/list/bootstrap-autofill-overlay-list.ts",
|
"overlay/list": "./src/autofill/overlay/pages/list/bootstrap-autofill-overlay-list.ts",
|
||||||
@ -274,8 +274,8 @@ if (manifestVersion == 2) {
|
|||||||
mainConfig.entry.background = "./src/platform/background.ts";
|
mainConfig.entry.background = "./src/platform/background.ts";
|
||||||
mainConfig.entry["content/lp-suppress-import-download-script-append-mv2"] =
|
mainConfig.entry["content/lp-suppress-import-download-script-append-mv2"] =
|
||||||
"./src/tools/content/lp-suppress-import-download-script-append.mv2.ts";
|
"./src/tools/content/lp-suppress-import-download-script-append.mv2.ts";
|
||||||
mainConfig.entry["content/fido2/page-script-append-mv2"] =
|
mainConfig.entry["content/fido2-page-script-append-mv2"] =
|
||||||
"./src/vault/fido2/content/page-script-append.mv2.ts";
|
"./src/autofill/fido2/content/fido2-page-script-append.mv2.ts";
|
||||||
|
|
||||||
configs.push(mainConfig);
|
configs.push(mainConfig);
|
||||||
} else {
|
} else {
|
||||||
|
Loading…
Reference in New Issue
Block a user