feat: add transport metadata to HardwareWalletAdapter and clean up exports#26503
Conversation
|
CLA Signature Action: All authors have signed the CLA. You may need to manually re-run the blocking PR check if it doesn't pass in a few minutes. |
🔍 Smart E2E Test Selection
click to see 🤖 AI reasoning detailsE2E Test Selection:
The changes are primarily internal refactoring and interface extensions. The removed SmokeAccounts is selected because it covers "adding QR-based hardware wallet accounts" according to its description, which is the most relevant test category for hardware wallet changes. While hardware wallet E2E tests typically require actual hardware devices, running SmokeAccounts provides some coverage for account-related flows that might interact with the hardware wallet layer. The risk is medium because:
Performance Test Selection: |
HardwareWalletAdapter and clean up exports
Description
Part "3.5" of the hardware wallet connection & error management overhaul. This does not introduce user facing changes.
Final implementation will look like this (Figma designs):

Reference feature branch: #25519
Changelog
CHANGELOG entry: null
Related issues
Fixes:
Manual testing steps
no manual testing steps
Screenshots/Recordings
Before
After
Pre-merge author checklist
Pre-merge reviewer checklist
Note
Medium Risk
Moderate risk due to an interface change affecting all adapter implementations and downstream imports/exports; runtime behavior change is limited to additional transport metadata on Ledger.
Overview
Extends the
HardwareWalletAdapterinterface withgetTransportDisabledErrorCode()andgetConnectionTips()so callers can surface transport-specific errors and UX guidance; implements these forLedgerBluetoothAdapter(BLE tips +BluetoothDisabled) and no-ops forNonHardwareAdapter, with tests updated accordingly.Removes the
requiresBluetoothhelper and tightens module exports by dropping default exports foruseDeviceEventHandlers/useHardwareWalletStateManagerand narrowing context exports, plus adds a top-levelapp/core/HardwareWalletindex exportinguseHardwareWalletandisUserCancellation.Written by Cursor Bugbot for commit 010da70. This will update automatically on new commits. Configure here.