-
Notifications
You must be signed in to change notification settings - Fork 5
Profile & Settings Redesign, Wallet Enhancements, UI/UX Improvements, NIP-46 Adaptations (WIP) #53
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
- Add connection mutex to prevent concurrent WebSocket connection attempts - Fix empty onDisconnect handler that caused hangs on Safari iOS - Add relay.status check to isNwcConnected() for accurate connection state - Add isNwcConnectedTo() helper to check connection to specific wallet URL - Use inlined connection check in connectNwc to avoid TDZ bundler errors
Also updates docs/WALLET_DEVELOPMENT.md with known issues and TDZ prevention guide
Move early relay.status check before const declarations to avoid referencing onConnect/onDisconnect before initialization
Also update WALLET_DEVELOPMENT.md to mark NWC restore as fixed
- Add fromTimestamp filter to listPayments to avoid stale transaction data - Initial load uses 30-day window, 'Load More' fetches all history - Add daysBack parameter to getPaymentHistory for flexibility
- Document fromTimestamp filter attempt and sync delay issue - Disable filter in code until SDK sync behavior is understood - Mark as deferred to future build
- Add @getalby/bitcoin-connect for unified payment modal - Create lightningService.ts singleton for external wallet payments - Remove WebLN code from zapManager.ts - Simplify ZapModal.svelte - launches Bitcoin Connect modal directly - Add Bitcoin Connect CSS theming variables to app.css - Payment detection via verify URL polling (1 second interval)
- Move Android docs to docs/android/ - Move dev docs to docs/dev/ - Move mobile docs to docs/mobile/
- Update login page styling - Redesign settings page layout - Update user profile page - Add Accordion component - Add Tabs component
- Redesign profile header: avatar left, name/bio center, buttons right-aligned - Constrain profile page to max-w-4xl for better readability - Fix profile navigation: CustomName and CustomAvatar now react to pubkey changes - Fix follow list bug: always fetch latest follow list before modifying - Standardize header button sizes (36px) for consistent alignment - Adjust Feed grid columns for profile view context - Remove photo edit overlay from avatar (moved to edit modal)
- Add lightweight external wallet support via Bitcoin Connect
- Only shown when no embedded wallets (NWC/Spark) exist
- Provides payment capability only (no balance, history, or header widget)
- Persists enabled state to localStorage
- Confirmation modal before removing
- Fix NWC payment failure after page refresh
- Add ensureWalletConnected() call in sendPayment() to auto-reconnect
- New files:
- src/lib/wallet/bitcoinConnect.ts - enabled/disabled state store
- src/components/icons/BitcoinConnectLogo.svelte - BC logo icon
- Update wallet page UI:
- Modal header changed to "Add Embedded Wallet"
- BC option with divider at bottom of wallet selection
- "External wallet connected" state with orange BC logo
- "Remove External Wallet" with confirmation
- Update docs/WALLET_DEVELOPMENT.md with BC documentation and testing checklist
- Add currency conversion for wallet balances using @getalby/lightning-tools
- New currencyStore.ts with 10 supported currencies (SATS, USD, EUR, etc.)
- New currencyConversion.ts with 5-minute rate caching
- FiatBalance.svelte shows fiat value below sats balance
- CurrencySelector.svelte dropdown for currency selection
- Add currency selector to wallet page (compact) next to balance display
- Add Currency settings section in Settings page (next to Wallet section)
- Add profile banner display on user profile page
- Shows user's banner image if set, falls back to gradient
- Avatar overlaps bottom of banner with ring separator
- Fix SaveButton dropdown icon spacing and hover state (now circular)
- Create unified encryptionService.ts for signer-agnostic encryption - Route encryption through NDK signer instead of window.nostr - Update NWC, Spark, and profile backup to use new service - Works with NIP-07 extensions, NIP-46 (Amber), and private keys
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR implements several major features and improvements to enhance mobile UX, wallet functionality, and NIP-46 remote signer support. The changes include Bitcoin Connect integration for external wallets, fiat currency conversion, a redesigned profile/settings UI, and a unified encryption service to support both NIP-07 and NIP-46 authentication methods.
Key Changes:
- Bitcoin Connect integration as an external wallet option with simplified payment flow
- Unified encryption service supporting NIP-07, NIP-46, and private key signers
- Profile page redesign with banner display and improved mobile layout
- Settings page redesign with accordion sections and relay connection status
- Fiat currency conversion and display alongside sats balances
Reviewed changes
Copilot reviewed 39 out of 44 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| svelte.config.js | Comment capitalization fix for consistency |
| src/routes/wallet/+page.svelte | Major refactor: Bitcoin Connect integration, NIP-46 warnings, fiat display, improved error messages |
| src/routes/user/[slug]/+page.svelte | Profile redesign with banner, improved follow logic with safeguards |
| src/routes/settings/+page.svelte | Complete redesign with accordions, relay status, currency selector |
| src/routes/login/+page.svelte | Theme-aware logo selection |
| src/lib/zapManager.ts | Removed WebLN code, added verify URL support |
| src/lib/wallet/walletManager.ts | Added connection check before payment |
| src/lib/wallet/nwcBackup.ts | Integrated unified encryption service |
| src/lib/wallet/index.ts | Exported Bitcoin Connect functions |
| src/lib/wallet/bitcoinConnect.ts | New external wallet state management |
| src/lib/spark/index.ts | Integrated unified encryption service |
| src/lib/profileBackup.ts | Integrated unified encryption service |
| src/lib/lightningService.ts | New Bitcoin Connect payment modal integration |
| src/lib/encryptionService.ts | New signer-agnostic encryption service |
| src/lib/currencyStore.ts | New currency preference store |
| src/lib/currencyConversion.ts | New fiat conversion utilities |
| src/lib/authManager.ts | Simplified nostrconnect URL for compatibility |
| src/components/icons/BitcoinConnectLogo.svelte | New Bitcoin Connect logo component |
| src/components/ZapModal.svelte | Refactored to use Bitcoin Connect for external payments |
| src/components/Tabs.svelte | New reusable tabs component |
| src/components/SaveButton.svelte | Fixed dropdown trigger margin |
| src/components/NotificationBell.svelte | Size adjustments for header consistency |
| src/components/Header.svelte | Size and alignment improvements |
| src/components/FiatBalance.svelte | New component for fiat balance display |
| src/components/Feed.svelte | Profile-specific grid layout |
| src/components/CustomName.svelte | Reactive pubkey handling fix |
| src/components/CustomAvatar.svelte | Reactive pubkey handling fix |
| src/components/CurrencySelector.svelte | New currency selector component |
| src/components/Accordion.svelte | New accordion component |
| src/app.css | Bitcoin Connect theming variables |
| package.json | Added Bitcoin Connect dependencies |
| docs/ | Reorganized into subdirectories with new documentation |
Files not reviewed (1)
- pnpm-lock.yaml: Language not supported
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Summary
This PR includes several major features and improvements:
Profile & Settings Redesign
Wallet Enhancements
NIP-46 Remote Signer Support (WIP)
UI/UX Improvements
Documentation
docs/android/,docs/mobile/,docs/dev/subdirectoriesTest Plan