From 373566416e6a3ce8ff83aafcd6afc96147a01580 Mon Sep 17 00:00:00 2001 From: Adam Soltys Date: Mon, 17 Aug 2026 23:53:15 -0700 Subject: The avatar ask learns to recognize a face: an identity with a published picture skips the punk picker and lands straight on done Co-Authored-By: Claude Fable 5 Claude-Session: https://claude.ai/code/session_01JtaatFfAbx91Nh3xqKVqKz --- src/app.js | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'src/app.js') diff --git a/src/app.js b/src/app.js index 063da05..8f5c622 100644 --- a/src/app.js +++ b/src/app.js @@ -2696,7 +2696,14 @@ function onboardScreen() { if (o.enterAddr === undefined) o.enterAddr = addr || null; // Only a real (custom) name advances by itself — the background // auto-claim of the npub-shaped default doesn't count as setting up. - if (addr && addr !== o.enterAddr && !/^npub1/.test(addr)) o.step = 'avatar'; + if (addr && addr !== o.enterAddr && !/^npub1/.test(addr)) { + // The avatar ask is for brand-new profiles. An identity that already + // wears a face (a nostr login with a published picture) skips straight + // to done — the punk picker restyling a real profile helps nobody. + const me = (featureHook('nostrLoginIdentity') || {}).pubkey || (wallet.nostrPubkey && wallet.nostrPubkey()); + const prof = me ? featureHook('cachedProfile', me) : null; + o.step = prof && prof.picture ? 'success' : 'avatar'; + } } try { localStorage.setItem(ONB_STEP_KEY, o.step); } catch {} const page = (kids) => h('div', { class: 'col onb', style: 'gap:20px' }, ...kids); -- cgit v1.2.3