From 5d0540ee2b4d3fe91f632ae7e23cf77e2b2eb6a3 Mon Sep 17 00:00:00 2001 From: Leendert de Borst Date: Fri, 28 Feb 2025 18:15:37 +0100 Subject: [PATCH] Autofill form directly after creating new credential (#622) --- browser-extensions/chrome/src/contentScript/Popup.ts | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/browser-extensions/chrome/src/contentScript/Popup.ts b/browser-extensions/chrome/src/contentScript/Popup.ts index a7cc8a843..86b509474 100644 --- a/browser-extensions/chrome/src/contentScript/Popup.ts +++ b/browser-extensions/chrome/src/contentScript/Popup.ts @@ -338,8 +338,11 @@ export function createAutofillPopup(input: HTMLInputElement, credentials: Creden }; chrome.runtime.sendMessage({ type: 'CREATE_IDENTITY', credential }, () => { - // Refresh the popup to show new identity. - openAutofillPopup(input); + // Close popup. + removeExistingPopup(); + + // Fill the form with the new identity immediately. + fillCredential(credential, input); }); } catch (error) { console.error('Error creating identity:', error);