From 386ad854d2c305af25eeaa6c70c9430ae56084f6 Mon Sep 17 00:00:00 2001 From: thePR0M3TH3AN <53631862+PR0M3TH3AN@users.noreply.github.com> Date: Tue, 21 Oct 2025 19:25:26 -0400 Subject: [PATCH] Add client-first NIP-46 handshake flow --- components/login-modal.html | 97 +++-- docs/nip46-remote-signers.md | 45 +- js/nostr.js | 507 +++++++++++++++++++++-- js/services/authProviders/nip46.js | 76 +++- js/ui/loginModalController.js | 406 ++++++++++++++++-- js/utils/qrcode.js | 634 +++++++++++++++++++++++++++++ 6 files changed, 1671 insertions(+), 94 deletions(-) create mode 100644 js/utils/qrcode.js diff --git a/components/login-modal.html b/components/login-modal.html index 1af9e8b1..69cafce8 100644 --- a/components/login-modal.html +++ b/components/login-modal.html @@ -240,10 +240,10 @@ class="space-y-4 rounded-xl border border-border bg-overlay-panel-soft px-5 py-4" >
-

Connect remote signer

+

Pair a remote signer

- Paste the nostrconnect:// or bunker:// link - from your signer to establish a Nostr Connect session. + Scan the QR code with your signer or share the connect link to start a + Nostr Connect session.

+
+
+ +
+ + +
+ +
+ +
+
+
+ +
- - -

- We will connect to the relays embedded in the link and request signing - permissions on your behalf. -

+ +