feat(wallets): per-wallet directSigningSupport for V3 swap flow#17
Merged
feat(wallets): per-wallet directSigningSupport for V3 swap flow#17
Conversation
* Drop the duplicated local `core.ts` files and import `createWallet` /
`getWalletSupportedChains` from `@swapkit/wallet-core` (^4.2.0) so all
wallets share one canonical contract.
* Stamp `directSigningSupport: Partial<Record<Chain, boolean>>` on every
wallet so the SDK can decide V3 routing per (wallet, chain) without a
central map.
* Wire two real signers as part of the rollout:
- Xaman/Ripple — `submitXamanPayload` exposes the signed `hex` blob
and accepts `{ submit: false }`; new ChainSigner wraps
xumm.payload.createAndSubscribe and is passed to
`getRippleToolbox({ signer })`.
- Ledger/Cosmos Hub — pass the existing `CosmosLedger`
(already an OfflineAminoSigner) to `getCosmosToolbox(_, { signer })`.
* BitGet Cosmos: use `getOfflineSignerAuto` so V3 proto SignDocs sign
natively (Ledger via BitGet still falls back to amino).
* WalletConnect EVM: add Aurora + Berachain to the EVM `getToolbox`
switch and register `XLAYER_MAINNET_ID` so XLayer's namespace
negotiation works.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Moves V3 capability from a centralized `V3SwapFlowSupport` map (in `@swapkit/helpers`) to inline per-wallet declaration. Each wallet now owns the truth about which chains it can sign raw transactions for, and the SDK can gate V3 routing via `wallet.supportsDirectSigning` instead of a central lookup.
Changes
What's still pending
Each wallet's `directSigningSupport` map omits / leaves `false` for chains where the signer wrapper still needs work. Comments in the code point to the per-chain plans. Highlights:
Follow-up
Test plan
🤖 Generated with Claude Code