From ee7b4c854586893ac4b95b9e9df5dc09e733a535 Mon Sep 17 00:00:00 2001 From: NicolasCantu Date: Thu, 23 Oct 2025 19:52:10 +0200 Subject: [PATCH] feat: Display 4 words immediately after credentials generation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit **Motivations :** - Show 4 words to user as soon as credentials are generated - Improve user experience by not waiting for full pairing process **Modifications :** - Moved generateWordsDisplay call to execute right after address is obtained - Removed duplicate call at end of pairing process - Users now see words immediately after WebAuthn authentication **Pages affectées :** - src/utils/sp-address.utils.ts - Early 4 words display --- src/utils/sp-address.utils.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/utils/sp-address.utils.ts b/src/utils/sp-address.utils.ts index 1cc4297..e990731 100755 --- a/src/utils/sp-address.utils.ts +++ b/src/utils/sp-address.utils.ts @@ -2743,6 +2743,10 @@ export async function prepareAndSendPairingTx(): Promise { // Update UI with creator address updateCreatorStatus(`Creator address: ${creatorAddress}`); + // Generate 4 words representation for the joiner immediately + console.log(`🔍 DEBUG: Generating 4 words representation for joiner...`); + await generateWordsDisplay(creatorAddress); + // Secure credentials already initialized in the click handler // Create pairing process with creator's address @@ -2762,10 +2766,6 @@ export async function prepareAndSendPairingTx(): Promise { await service.handleApiReturn(createPairingProcessReturn); - // Generate 4 words representation for the joiner - console.log(`🔍 DEBUG: Generating 4 words representation for joiner...`); - await generateWordsDisplay(creatorAddress); - console.log(`✅ DEBUG: Creator pairing process created and 4 words generated`); console.log(`⏳ DEBUG: Creator waiting for joiner to enter 4 words...`); } catch (err) {