You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Nothing exposes the wallets discovery found, or which one is connected. #3's acceptance criterion
"useConnect/CantonConnectProvider reflect the discovered wallet list and current selection" was
left unmet in #47: the list reaches CantonConnectConfig.walletPicker and nowhere else.
Two things need it:
A themed in-page picker (companion issue) has to render the entries, so it cannot be built
without them.
Multi-account UI.useParty() returns the primary party only. A dApp showing a party switcher —
the vesting app already has one — has to call sdk.listAccounts() itself and map the results. feat: adopt the dapp-sdk facade in canton-connect #47
deliberately un-exported selectPrimaryAccount/toParty rather than make our internal mapping
public API, on the grounds that the right answer is a hook we own.
Proposed solution
useParties() returning every account mapped to Party, so a switcher needs no access to our
mapping helpers and the toParty precedence rule stays ours to change.
Expose the discovered entries and the current selection — most likely on the context value, since
the picker is chosen before a session exists. Shape to be decided with the picker issue, so the two
land coherently rather than inventing two overlapping surfaces.
Acceptance criteria
useParties() exists, returns all accounts as Party, and updates on accountsChanged
The discovered wallet entries and the current selection are readable from the public surface
The themed picker can be built against it without reaching into the SDK directly
selectPrimaryAccount and toParty stay internal — a consumer never needs them for this
User story / Problem statement
Nothing exposes the wallets discovery found, or which one is connected.
#3's acceptance criterion"
useConnect/CantonConnectProviderreflect the discovered wallet list and current selection" wasleft unmet in #47: the list reaches
CantonConnectConfig.walletPickerand nowhere else.Two things need it:
without them.
useParty()returns the primary party only. A dApp showing a party switcher —the vesting app already has one — has to call
sdk.listAccounts()itself and map the results. feat: adopt the dapp-sdk facade in canton-connect #47deliberately un-exported
selectPrimaryAccount/toPartyrather than make our internal mappingpublic API, on the grounds that the right answer is a hook we own.
Proposed solution
useParties()returning every account mapped toParty, so a switcher needs no access to ourmapping helpers and the
toPartyprecedence rule stays ours to change.the picker is chosen before a session exists. Shape to be decided with the picker issue, so the two
land coherently rather than inventing two overlapping surfaces.
Acceptance criteria
useParties()exists, returns all accounts asParty, and updates onaccountsChangedselectPrimaryAccountandtoPartystay internal — a consumer never needs them for thisCLAUDE.md