summaryrefslogtreecommitdiffstats
path: root/src/features/names.js
Commit message (Collapse)AuthorAgeFilesLines
* Offer migration only for submitted unmigrated legacy namesAdam Soltys2026-09-111-19/+52
|
* Onboarding: fix the crash after a name claim/migration; keep a login-owned ↵Adam Soltys2026-09-101-1/+8
| | | | | | | | | | | | | | | | | | | name through signer resume. "Something broke" right after a coinos.io migration completed: the spend step advances past the avatar ask by calling nextAfterAvatar(), which was a const declared further down the same function — a temporal-dead-zone throw for any profile that already had a picture. Now a hoisted function. Also, the claimed-name ownership check only counted the LIVE login signer. A bunker/Google login resumes seconds after load, so for that window a name owned by the login identity (every migrated coinos.io name) looked foreign, was dropped, and the wallet key's npub-shaped default took its place — the address visibly flipped from [email protected] to npub…@coinos.io. The stored login pubkey now counts as ours too. Co-Authored-By: Claude Fable 5.1 <[email protected]> Claude-Session: https://claude.ai/code/session_01Nw1Dijik1tLVKRM1WkU7xE
* POS tools are merchant-only now: the tap-to-pay link and terminal-token ↵Adam Soltys2026-09-051-3/+11
| | | | | | | cards hide behind a merchant designation — a one-line "I'm a merchant — show point-of-sale tools" toggle at the foot of the payment-address card, swapping to "Hide point-of-sale tools" once on. The flag lives in the names feature state, so it follows the account to every device via wallet sync; regular users just see one quiet line instead of two cards of terminal plumbing Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01MGzU12QrAA4G6BYGzGVdXz
* The POS-link QR is itself a lightning: link — tapping it on the device ↵Adam Soltys2026-09-051-1/+7
| | | | | | | showing it hands the LNURL straight to whatever wallet owns the scheme, no scanning your own screen Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01MGzU12QrAA4G6BYGzGVdXz
* The POS-link card's LNURL copy button copies a lightning: URI (lowercase ↵Adam Soltys2026-09-051-1/+3
| | | | | | | bech32 with the prefix) — tappable and pasteable anywhere that registers the scheme, including our own Android app — while the QR keeps the bare uppercase form for alphanumeric-mode density Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01MGzU12QrAA4G6BYGzGVdXz
* Settings: lay the payment-address sections out as cards; zap settings under ↵Adam Soltys2026-09-051-57/+63
| | | | | | | | | | | | Nostr Custom name, point of sale, the terminal's tap-to-pay link, own node and own domain each get a card on Settings → Payments instead of hiding in collapsed sections. The one-tap zap amount and the CLINK zap code move to Settings → Nostr, where the other nostr settings are. Co-Authored-By: Claude Fable 5.1 <[email protected]> Claude-Session: https://claude.ai/code/session_01VMi2Y1oKPZ3TeeFmLej47y
* morph: leave <details open> to the user; key the names settings sectionsAdam Soltys2026-09-051-6/+6
| | | | | | | | | | | | Every background repaint stripped the browser-set `open` attribute (the fresh render never carries it), collapsing expanded sections, and the positional child match handed one section's open state to its neighbour whenever the conditional zap-code section came or went. `open` on a details is now user-owned unless a render sets it, and nodes carrying data-key only patch into the same key. Co-Authored-By: Claude Fable 5.1 <[email protected]> Claude-Session: https://claude.ai/code/session_01VMi2Y1oKPZ3TeeFmLej47y
* Point of sale: show the terminal's tap-to-pay LNURL, link and QRAdam Soltys2026-09-051-2/+18
| | | | | Co-Authored-By: Claude Fable 5.1 <[email protected]> Claude-Session: https://claude.ai/code/session_01VMi2Y1oKPZ3TeeFmLej47y
* Point of sale: a coinos-pos terminal works against a nameAdam Soltys2026-09-051-0/+25
| | | | | | | | | | | | | | | | | | Registrar: the owner mints a bearer POS token from Settings (NIP-98 POST /pos/token, DELETE revokes; /admin/pos/token for operators). With it the terminal gets /pos/me, rings up sales at /pos/invoice (fiat via coinos.io rates, or sats), reads /pos/payments, and holds a websocket at /pos/ws that gets a payment message when the sale settles. Sales are always minted on our node so the settle loop sees them and the ordinary forward path delivers the sats to the name's ark address. The name's lnurlp pins the newest unpaid sale under five minutes old — coinos.io's /p/<name> rule — so an NFC tap or a scan pays exactly that invoice. Wallet: a "Point of sale" section on the names card creates, copies and revokes tokens. Co-Authored-By: Claude Fable 5.1 <[email protected]> Claude-Session: https://claude.ai/code/session_01VMi2Y1oKPZ3TeeFmLej47y
* Lightning receives to a [email protected] address now wear the ⚡ instead of ↵Adam Soltys2026-09-041-0/+18
| | | | | | | the Ark mark: a faucet paying the LN address settles on the registrar's CLN and arrives as an anonymous arkoor from the float (the mailbox protocol carries no memo), so the wallet genuinely couldn't tell the rail. The registrar now records a receipt {sat, hash, ts} per LN settlement it forwards via the float (7-day ring per name) and serves them at GET /lnreceipts (NIP-98, owner/manager only — it's a feed of incoming amounts); the wallet fetches them through the names feature (which holds the signer) and fuzzy-matches receive movements by exact amount + delivery within ±3 min, stamping viaLn + the payment hash so a receipt can never claim a second row. History row and detail view show ⚡ for viaLn receives; the tag rides the sync snapshot to other devices via merge enrichment. viaClink deliveries need none of this — the wallet's own LN-receive flow already tags itself. Best-effort by design: an amount+time collision only mislabels an icon Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01MGzU12QrAA4G6BYGzGVdXz
* Two small trims: the payment detail's copy-preimage becomes a full-width ↵Adam Soltys2026-09-021-6/+2
| | | | | | | button matching the Back beneath it, and the receive page's lightning address drops its edit pencil — renaming lives in the profile editor's username field, and two doors was one too many Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01MrkLsNScXe9b6BviUSdmMr
* The migrate door opens from the username screen too: the same 'Migrate an ↵Adam Soltys2026-08-311-1/+12
| | | | | | | existing coinos account' link the wizard offers now sits under the claim form (mainnet only, address required) — a coinos.io veteran who skipped it during onboarding no longer needs a fresh account to find it Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01MrkLsNScXe9b6BviUSdmMr
* The username claim field forgets its draft when a wallet opens: a name typed ↵Adam Soltys2026-08-301-1/+7
| | | | | | | before logout used to greet whichever account opened next on the device (the field lives in global UI state and nothing ever reset it) Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01MrkLsNScXe9b6BviUSdmMr
* The migration round trip stops eating its own homework: the ?migrated= ↵Adam Soltys2026-08-301-0/+4
| | | | | | | return is stashed synchronously at boot and claimed whenever the wallet actually opens (the old 1.5s one-shot silently dropped it), the wizard's 'I'm done, continue' state survives the trip to coinos.io as a persisted step, the legacy page shows the claim in progress instead of re-asking, and a finished claim advances the wizard by itself. Fresh-seed polish riding along: the spending-setup ask stops waiting out registrar round trips that only exist for restored wallets, and the header punk paints synchronously instead of after an async identity fetch Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01MrkLsNScXe9b6BviUSdmMr
* Pasting your own coinos name (or ark address) opens the boarding panel at ↵Adam Soltys2026-08-301-0/+4
| | | | | | | paste time, not at review: the names resolver asks the ark feature before filling the send form, a raw address paste runs the same check, and the review path still carries a typed amount into the panel — one boardOwnAddress helper serves all three doors Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01MrkLsNScXe9b6BviUSdmMr
* A door where people will look for it: 'Deliver to your own node' gets its ↵Adam Soltys2026-08-291-4/+11
| | | | | | | own entry in the address's more-options menu and a section in the Settings names card — it no longer hides as an appendix behind the CLINK zap code, which returns to being just that Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_019WboeoetMF3MTmgT7Ew8yi
* The wallet learns to read BOLT 12 for itself: offers and invoices decode ↵Adam Soltys2026-08-291-39/+62
| | | | | | | client-side, and every invoice the ASP fetches over onion messages is verified here — payment hash read from the raw TLVs, offer terms mirrored byte-for-byte, the issuer's schnorr signature checked against LDK's exact merkle construction (proven against a live CLN-signed fixture) — so no server can hand back an invoice whose preimage it already holds. Paste an lno1 or resolve a name whose record carries one and the existing HTLC pay flow carries it (captaind's Invoice enum takes lni strings natively); a name's owner may now publish their OWN node's offer in their DNS record, retiring the registrar's stand-in — senders fetch invoices straight from their node and no coinos service ever touches the money. The /lnquote fallback prices blinded paths by entry node + advertised payinfo Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_019WboeoetMF3MTmgT7Ew8yi
* An address can point home: a name's owner may register their own CLINK offer ↵Adam Soltys2026-08-291-6/+60
| | | | | | | code and the registrar asks THEIR node for invoices — delivered there first, float as fallback, and no invoice is relayed or paid unless it demands exactly the sats owed on the right network. hal learns to pay pasted noffer1 codes through the zap flow (fixed, variable and payer-chosen pricing, amount verified before the HTLC locks). The depth advisory slims to one line — an uncooperative exit's price and a Manage link — and the new coins screen shows each vtxo's amount, expiry and arkoor depth beside what renewal costs and buys Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_019WboeoetMF3MTmgT7Ew8yi
* A name the registrar no longer grants is a costume: the wallet verifies its ↵Adam Soltys2026-08-281-0/+15
| | | | | | | cached name against the record's owner and manager keys each refresh, shedding stale ones (an evicted squat once lingered in the squatter's UI) — the /name endpoint now names the manager too Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_019eA8JRq9Wr7z2fRQk99HLi
* The address is fetched while the key still turns in the lock: sign-in races ↵Adam Soltys2026-08-281-0/+15
| | | | | | | a registrar lookup against the seed work and seeds the name before first paint, so the Receive pane opens straight onto its QR instead of "setting up your payment address" Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_019eA8JRq9Wr7z2fRQk99HLi
* The wallet arrives without ceremony: sign-in swaps screens instantly (a ↵Adam Soltys2026-08-271-0/+3
| | | | | | | one-shot no-anim flag on the handover), and the spending-setup ask holds its tongue until the name restore has settled instead of flashing while the answer is seconds away Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_019eA8JRq9Wr7z2fRQk99HLi
* The chosen name outranks the placeholder everywhere: a claim can no longer ↵Adam Soltys2026-08-271-1/+23
| | | | | | | release a custom name to make room for an npub default (the race that deleted passkeyguy), sign-in asks the registrar about the login identity before reaching for a placeholder, and the registrar answers /pubkey with the name the user picked rather than whichever record is younger Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_019eA8JRq9Wr7z2fRQk99HLi
* The app arrives in movements: real ESM chunks split the bundle (entry 333KB, ↵Adam Soltys2026-08-261-1/+1
| | | | | | | shared chunks alongside, 61KB of gifts/NWC/hats deferred past first paint into slots that keep their hook seniority), the lazy scripts wear IIFE coats so their names can't collide with the page's — which is what silently broke the remote-signer button — nip98 moves out of the login module so minimal builds stop hauling backup relays, and the smoke test learns the front door's new steps while the regtest stack rises from its IBD nap Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_019eA8JRq9Wr7z2fRQk99HLi
* A wallet keeps one name per domain, not one name total: staging and mainnet ↵Adam Soltys2026-08-181-3/+37
| | | | | | | claims stop clobbering each other, the registrar answers who-am-I per domain, and a custom name claimed on one device replaces the npub placeholder on every other Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01JtaatFfAbx91Nh3xqKVqKz
* The claim field greets you by name: your nostr username arrives pre-filled ↵Adam Soltys2026-08-171-0/+24
| | | | | | | when the registrar confirms it's free (or already yours) — editable, never auto-claimed Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01JtaatFfAbx91Nh3xqKVqKz
* Typed names take the instant rail too: a Send button outranks the Zap for ↵Adam Soltys2026-08-171-4/+18
| | | | | | | our domains, resolving to the ark address instead of an LNURL round-trip that needs the recipient awake Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01JtaatFfAbx91Nh3xqKVqKz
* Our names get a second answer: when DNS is late the registrar speaks for its ↵Adam Soltys2026-08-171-9/+26
| | | | | | | own records, and unknown staging names say so instead of zapping a webroot that only serves HTML Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01JtaatFfAbx91Nh3xqKVqKz
* Staging names its own: mutinynet claims land at @staging.coinos.io — play ↵Adam Soltys2026-08-171-15/+19
| | | | | | | personas and their testnet addresses stop squatting the real namespace Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01JtaatFfAbx91Nh3xqKVqKz
* Mutinynet gets the full name experience: the payment-address pane, the claim ↵Adam Soltys2026-08-171-1/+6
| | | | | | | card, the re-registration — staging stops showing raw ark addresses to people who just claimed a name Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01JtaatFfAbx91Nh3xqKVqKz
* Username and display name go their separate ways: the handle wears a frozen ↵Adam Soltys2026-08-151-5/+8
| | | | | | | @coinos.io so it reads as address and NIP-05, renames claim before the profile publishes, and nip05 rides along with lud16 Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_014tE4U5nEjGTQy8PwYqamfv
* A new name offers its hand to the address: saving a renamed profile proposes ↵Adam Soltys2026-08-151-0/+4
| | | | | | | the matching @coinos.io, and any rename repoints the kind-0 lightning address so zaps never chase a released name Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_014tE4U5nEjGTQy8PwYqamfv
* The wizard waits out a signer login; a picked recipient shows its work, and ↵Adam Soltys2026-08-081-0/+9
| | | | | | search answers from memory before the network Co-Authored-By: Claude Fable 5 <[email protected]>
* More options also points at Savings for a plain on-chain addressAdam Soltys2026-08-041-2/+7
| | | | | | | | | Not a pane of its own: a regular Bitcoin address means receiving to Savings, so the entry switches the account selector over and lets the savings receive view show its fresh address. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_015QwAtBSpKvECqp1rHLHjJk
* One More-options link replaces the BOLT 12 link on ReceiveAdam Soltys2026-08-041-14/+122
| | | | | | | | | Behind it: a one-time BOLT 11 invoice (minted by the ASP), the reusable BOLT 12 offer flow, the wallet's raw ark address, and the CLINK offer code — each on its own pane so only one scannable code shows at a time. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_015QwAtBSpKvECqp1rHLHjJk
* The npub default never displaces a custom nameAdam Soltys2026-08-041-1/+9
| | | | | | | | | | | adoptIdentity claimed the identity npub whenever the local name differed — and claim() releases the previous name, so a nostr login could delete the user's custom address from the registrar (it did). It now asks the registrar first and yields to any custom name. The registrar's /pubkey lookup also matches manager keys now and prefers real names over npub defaults, so restored wallets find their name again. Co-Authored-By: Claude Fable 5 <[email protected]>
* Copy joins the pencil inside the address boxAdam Soltys2026-08-041-8/+13
| | | | Co-Authored-By: Claude Fable 5 <[email protected]>
* Choosing a name gets a page of its ownAdam Soltys2026-08-041-5/+17
| | | | | | | The pencil opens a dedicated screen — no balances, no tabs — wired into the history stack like the other sub-pages. Co-Authored-By: Claude Fable 5 <[email protected]>
* Pencil in a boxAdam Soltys2026-08-041-1/+1
| | | | Co-Authored-By: Claude Fable 5 <[email protected]>
* A proper pencilAdam Soltys2026-08-041-1/+1
| | | | Co-Authored-By: Claude Fable 5 <[email protected]>
* A quieter pen inside the address box; the header avatar stops flashingAdam Soltys2026-08-041-5/+5
| | | | | | | | The avatar img was recreated on every render — boot's render bursts made it flash; there is exactly one header avatar, so the node is reused until the profile actually changes. Co-Authored-By: Claude Fable 5 <[email protected]>
* The name is edited where the name is — a pencil by the addressAdam Soltys2026-08-041-7/+12
| | | | Co-Authored-By: Claude Fable 5 <[email protected]>
* Offer the custom-name form right on the Receive paneAdam Soltys2026-08-041-0/+6
| | | | | | | Anyone still on the npub-shaped default sees their address here, not in the collapsed corner of Settings where the claim form lived. Co-Authored-By: Claude Fable 5 <[email protected]>
* Claim with the login identity, so a migrated name can come homeAdam Soltys2026-08-041-1/+5
| | | | | | | | | | The registrar now lets a migrated coinos user's nostr identity (re)take its own name — migration could land the claim in whatever wallet ran it, stranding the name there. The claim form signs with the (re)attached login identity when there is one; the wallet key alone could never prove the takeover. Co-Authored-By: Claude Fable 5 <[email protected]>
* Drop the BOLT 12 explainer blurbAdam Soltys2026-08-041-1/+0
| | | | Co-Authored-By: Claude Fable 5 <[email protected]>
* Receive: the BOLT 12 section takes over the cardAdam Soltys2026-08-031-2/+4
| | | | | | | | | Opening it hides the payment address and its QR — two payment codes on one screen is a good way to have someone scan the wrong one. "Hide" becomes "Back", which is what it now does. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01Wvj4aoeMZwA7VUGdJP9Swi
* Onboarding: a step for migrating a legacy coinos.io accountAdam Soltys2026-08-031-0/+2
| | | | | | | | | | | | | | | | | | | Between "do you have a nostr account" and claiming a username, new users are asked whether they already have an account on the original coinos. Yes hands off to coinos.io/migrate with their fresh v3 payment address and a return URL — they're already signed in there, so no password or key ever travels. That page sweeps the balance over Lightning and renames the old account, releasing the username. Coming back, coinos.io returns ?migrated=<username>; v3 claims that name on the registrar (retrying for a minute, since the registrar's "is this a legacy user?" guard caches), and their lightning address now resolves to the v3 wallet. The legacy page ships in coinos-ui and is NOT deployed yet. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01Wvj4aoeMZwA7VUGdJP9Swi
* BOLT 12 offers with a custom memo on the Spending receive pageAdam Soltys2026-08-031-3/+76
| | | | | | | | | | | | | | | | | | Mining pools (Ocean) and payroll pay to a reusable offer rather than a lightning address, and the memo is how the payer labels it. A disclosure under the payment address mints one: the registrar's new NIP-98'd /offer endpoint asks the ASP's CLN for an `amount: any` offer carrying the memo, keyed to the caller's name (issuer = their address, so two users' identical memos can't collapse onto one CLN offer). Up to ten each, identical memos reuse the existing offer, and GET lists them. Settled offer payments already had a home: the registrar's settle loop now resolves a custom offer id to its owner and hands it to the same forwarder the default offer uses — an instant, free arkoor send into the user's Spending balance. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01Wvj4aoeMZwA7VUGdJP9Swi
* First-run onboarding: a five-step wizard and a coach-mark tourAdam Soltys2026-08-021-0/+2
| | | | | | | | | | | | | | | | | | | Fresh devices land in a full-screen flow instead of the unlock screen: welcome → "do you have a nostr account?" (sign in brings wallet, name, and profile along; No mints a wallet on the spot) → claim a username (the background npub-default only surfaces a Keep button; a custom claim — or a restored login's recovered name — advances by itself) → pick a punk or upload a photo (nostr.build), published as the kind-0 name+picture → confetti. "Enter coinos" drops into a three-stop tour: the avatar menu, the Spending/Savings toggle, and the tabs with the swipe tip — each highlighted by a measured gold ring over a dimmed page. One time only (localStorage flag), with an "I already have a wallet" escape to the classic screen. New seams: names.namesClaimForm, messages.publishProfile. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01Wvj4aoeMZwA7VUGdJP9Swi
* Identity polish: 12-char npub default names, no ellipsis, copyable npubAdam Soltys2026-08-021-2/+2
| | | | | | | | | The registrar's auto-claimed username and every npub-fallback display name use the npub's first 12 characters, shown whole (no truncation dots), and the profile page's npub gets a copy button. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01Wvj4aoeMZwA7VUGdJP9Swi
* Profiles: view pages, editable own kind 0, zap recipients in historyAdam Soltys2026-08-021-0/+2
| | | | | | | | | | | | | | | | | | | Tapping any avatar or author name (chat rooms, DM threads, the chat home) opens a profile page: avatar, name, nip05, lightning address, about, npub, with Message and Pay actions (Pay runs the npub payment cascade). Your own profile — reachable from your avatar on the chat home — gets an editor for name, about, picture, and lightning address (prefilled with your coinos address); saving merges over the newest published kind 0 so fields we don't understand survive the round trip. Zaps now remember who they went to: the ark feature keys the recipient by what the movement already records (destination address or invoice) and history rows wear a clickable avatar chip that opens the profile. The messages feature exposes showProfile/profileChip seams so any feature can do the same. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01Wvj4aoeMZwA7VUGdJP9Swi