Skip to content

Add subaccount import and spy mode#15

Open
VSBDev wants to merge 1 commit into
devfrom
feature/import-subaccount
Open

Add subaccount import and spy mode#15
VSBDev wants to merge 1 commit into
devfrom
feature/import-subaccount

Conversation

@VSBDev

@VSBDev VSBDev commented Apr 24, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Allow operators to inspect and manage non-contiguous EVC subaccounts without adding every intermediate account tab.
  • Add a minimal read-only spy mode so a wallet's subaccounts can be inspected locally from ?addr=... without connecting that wallet.
  • Declare the React Query dependency that the app imports directly.

Changes

  • Replace the contiguous numSubAccounts model with explicit subAccountIds, building sparse lens bitmasks from the loaded IDs.
  • Add + New for the next unused subaccount and Import for either a numeric ID or a derived subaccount address.
  • Add reverse subaccount derivation and validation for imported addresses.
  • Split inspected address state from connected wallet state with walletConnected, spyMode, and canWrite, then disable write actions while spying.
  • Preserve ?addr=... across primary nav links and show a spy-mode banner when viewing another address.
  • Update npm dependency metadata for the direct @tanstack/react-query import.

Test plan

  • npm run build
  • npm exec eslint -- src/Account.jsx src/App.jsx src/Utils.jsx
  • Open /account/?addr=0x416C6013260F0762C500F1F48dB5e403Bf293367 locally and import subaccount 15
  • Connect a wallet and verify + New still adds the next unused subaccount
  • In spy mode, verify install/edit/uninstall/approve/swap actions are disabled

@VSBDev VSBDev requested a review from kasperpawlowski April 24, 2026 22:26
@VSBDev VSBDev changed the base branch from master to dev April 24, 2026 22:29
@kasperpawlowski kasperpawlowski changed the base branch from dev to master April 24, 2026 22:30
@VSBDev VSBDev force-pushed the feature/import-subaccount branch from fe8247e to b06ee19 Compare April 24, 2026 22:33
@VSBDev VSBDev changed the base branch from master to dev April 24, 2026 22: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.

1 participant