From b8ff224cdb3612e2ae45cc06ba415c275b9583f6 Mon Sep 17 00:00:00 2001 From: Adam Soltys Date: Sat, 15 Aug 2026 20:26:18 -0700 Subject: The logo learns the difference between fleeing and returning: mid-creation it backs out to the start page, and only a truly idle visitor gets pointed at the vault Co-Authored-By: Claude Fable 5 Claude-Session: https://claude.ai/code/session_014tE4U5nEjGTQy8PwYqamfv --- src/app.js | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'src/app.js') diff --git a/src/app.js b/src/app.js index 0b3312d..ccc3056 100644 --- a/src/app.js +++ b/src/app.js @@ -2152,6 +2152,22 @@ function goHome() { ui.sendResult = null; ui.sendError = ''; ui.fromWallet = false; + } else if ((ui.onb && ui.onb.step !== 'welcome') + || ui.draftMnemonic || ui.createStep !== 'gen' || ui.importText) { + // Mid-create with no wallet minted yet (wizard step, a generated seed on + // screen, the confirm quiz, a pasted import): the logo backs out to the + // start page this began from — not the vault prompt, which reads as a + // dead end when you were busy creating something new. + ui.onb = { step: 'welcome' }; + try { localStorage.removeItem(ONB_STEP_KEY); } catch {} + ui.nostrLoginOpen = false; + ui.screen = 'unlock'; + ui.unlockTab = 'create'; + ui.createStep = 'gen'; + ui.draftMnemonic = ''; + ui.importText = ''; + ui.confirm = []; + ui.unlockError = ''; } else if (hasVault()) { // Locked with saved wallets: home is the unlock prompt, not the // create-a-new-wallet flow — the logo must never read as "start over". -- cgit v1.2.3