mirror of
https://github.com/bitwarden/browser
synced 2025-12-16 00:03:56 +00:00
[PM-17564] Prompt Browser Extension (#13349)
* add browser extension prompt page with initial loading state * add browser extension icon * move browser extension prompt to state * add installation link for error state * automatically open extension when possible for browser-reprompt-page * refactor browser tabs query into a standalone method * add success message state for auto-opening browsers * Refactor `VaultOnboardingMessages` to `VaultMessages` to be more generic * add auto-open extension messages to `VaultMessages` enum * add bitwarden icon * Add manual error state for firefox users * add extension prompt routing * fix incorrect imports * add mobile screen for browser prompt * remove comment * fix typo in code comment * update key for `checkBwInstalled` method * add check for safari before attempting to send a message * break translation for manual opening into two parts
This commit is contained in:
@@ -1592,13 +1592,16 @@ export default class MainBackground {
|
||||
}
|
||||
|
||||
async openPopup() {
|
||||
// Chrome APIs cannot open popup
|
||||
const browserAction = BrowserApi.getBrowserAction();
|
||||
|
||||
// TODO: Do we need to open this popup?
|
||||
if (!this.isSafari) {
|
||||
if ("openPopup" in browserAction && typeof browserAction.openPopup === "function") {
|
||||
await browserAction.openPopup();
|
||||
return;
|
||||
}
|
||||
await SafariApp.sendMessageToApp("showPopover", null, true);
|
||||
|
||||
if (this.isSafari) {
|
||||
await SafariApp.sendMessageToApp("showPopover", null, true);
|
||||
}
|
||||
}
|
||||
|
||||
async reseedStorage() {
|
||||
|
||||
Reference in New Issue
Block a user