Skip to content

Conversation

@boldbitcoin
Copy link
Contributor

Summary

This PR covers critical bug fixes and improvements for v2.1.5 release, including address flickering fix, legacy wallet migration modal, and network state management improvements.

Changes

Added

  • Legacy Wallet Migration Modal: New modal appears for users with legacy wallets, advising migration to new wallet setup for better PSBT compatibility
    • Non-dismissible modal with friendly messaging
    • "Do not remind me again" checkbox option
    • Modal flag automatically resets on new wallet import (if wallet is legacy)
    • Standalone LegacyWalletModal component for reusability

Changed

  • Network Reset on Wallet Import: Network always resets to mainnet when importing a keyshare to ensure clean state
  • Balance Display Styling: Balance rows (BTC and USD) now have transparent background while maintaining tap-to-hide functionality
  • Button Alignment: Send and Receive buttons now vertically align with Device and Address Type buttons above for consistent spacing
  • QR Scanner Subtitle: Updated subtitle text to "Point camera to Sending Device QR" for clarity

Fixed

  • Address Flickering Issue: Fixed address changing/flickering after lock/unlock by making UserContext the single source of truth for addresses
    • UserContext now properly derives network-specific btcPub for both mainnet and testnet
    • WalletHome prioritizes userActiveAddress from UserContext over local state
    • Eliminated race conditions in address derivation
  • Network State Management: Improved network state consistency across the app
    • Network reset on import ensures proper address derivation
    • All contexts and providers properly synchronized with network changes
  • Cache Clearing: Comprehensive cache clearing on wallet setup and import screens
    • LocalCache cleared on ShowcaseScreen (import)
    • LocalCache cleared on MobilesPairing and MobileNostrPairing (setup mode only)
    • Stale btcPub removed from EncryptedStorage
    • WalletService cache cleared for fresh state

Technical Details

  • UserContext: Enhanced refresh() to derive separate btcPub values for mainnet and testnet
  • WalletHome: Updated to use UserContext as primary address source, with local state as fallback
  • ShowcaseScreen: Added network reset to mainnet on keyshare import using setActiveNetwork()
  • Cache Management: Added useEffect hooks to clear all cache on wallet setup/import screens
  • Styles: Updated balanceRowWithMargin to use transparent background
  • Button Layout: Applied flexOneMinWidthZero and partyGap styles to action buttons for consistent alignment

Files Changed

  • components/LegacyWalletModal.tsx (new)
  • components/Styles.tsx
  • context/UserContext.tsx
  • screens/MobileNostrPairing.tsx
  • screens/MobilesPairing.tsx
  • screens/ShowcaseScreen.tsx
  • screens/WalletHome.tsx
  • CHANGELOG.md

bbtc and others added 8 commits December 29, 2025 17:06
- Add hide/show balance user preference
- Document QR scanner refactoring and improvements
- Add PSBT sign filter feature
- Document QR scan shortcut for send (second device)
- Update wallet mode terminology (basic/flexi -> duo/trio)
- Document keyshare backup naming with xpub-based format
- Document SegWit Native as default address type
- Include all technical details and statistics
- Improved Nostr relay resilience for BTC sends (works even if some relays are down)
- Reduced pre-agreement timeout from 2 minutes to 16 seconds
- Fixed Android navigation bar overlap on WalletHome screen
- Enhanced message delivery reliability with retroactive event querying
- Added comprehensive logging for subscription debugging
v2.1.4 - Enhanced Nostr relay resilience and Android UI fixes
…k state management

- Fix address flickering by making UserContext single source of truth
- Add LegacyWalletModal with 'do not remind' checkbox
- Reset network to mainnet on keyshare import
- Clear cache on wallet setup/import screens
- Make balance rows transparent while keeping tap functionality
- Align Send/Receive buttons with Device/Address Type buttons
- Update QR scanner subtitle text
Copy link
Contributor

@HalFinneyIsMyHomeBoy HalFinneyIsMyHomeBoy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested manually, passed
Approved

@HalFinneyIsMyHomeBoy HalFinneyIsMyHomeBoy merged commit ce33d83 into main Dec 30, 2025
1 check passed
@boldbitcoin boldbitcoin deleted the v2.1.5 branch December 30, 2025 16:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants