diff --git a/src/2fa/2fa.ts b/src/2fa/2fa.ts index 7e7e9c074a..f57824978a 100644 --- a/src/2fa/2fa.ts +++ b/src/2fa/2fa.ts @@ -31,10 +31,17 @@ document.addEventListener('DOMContentLoaded', () => { sigValue: sigElement.value, }, }); - window.close(); } }, }); + } else if (msg.data.type === 'success') { + safari.self.tab.dispatchMessage('bitwarden', { + command: 'openPopup', + }); + + setTimeout(() => { + window.close(); + }, 500); } else { // TODO: others like u2f? } diff --git a/src/2fa/index.html b/src/2fa/index.html index b5c78a8730..85fc6fcc77 100644 --- a/src/2fa/index.html +++ b/src/2fa/index.html @@ -3,9 +3,29 @@