TradeWidgetDeloraAutoWalletManagementProviderfrom@deloraprotocol/widget-wallet-managementTradeWidgetWalletProvider
| Pattern | Use when | Notes |
|---|---|---|
TradeWidget | You want the full trading widget with the built-in wallet flow | Best default for standalone embeds |
TradeWidget + DeloraAutoWalletManagementProvider | Your app already uses Wagmi and/or Solana Wallet Adapter | Auto-detected adapter layer for common wallet stacks |
TradeWidget + TradeWidgetWalletProvider | Your app has custom wallet state or custom providers | Low-level adapter API from the core widget package |
1. TradeWidget
Use TradeWidget when you want the complete Delora trading experience, including token selection, network selection, quote loading, slippage control, wallet connection, and transaction execution.
2. TradeWidget with auto wallet management
Use this pattern when the host app already wraps the widget with Wagmi and/or Solana Wallet Adapter providers.
forceInternalWalletManagement when you want to ignore detected host wallet contexts and use only the widget’s built-in wallet flow.
The /auto import loads both the Wagmi and Solana Wallet Adapter adapters, so install both optional peer stacks when you use this pattern. Use the /wagmi or /solana subpath hooks for single-stack integrations.
3. TradeWidget with manual external wallet management
Use this pattern when the host app already manages wallet state and providers.
origin, destination, or both sides. If one side is omitted, that side falls back to the widget’s built-in wallet flow.
In the widget UI, origin maps to the sell-side wallet and destination maps to the receiver-side wallet.
Receiver handling
The widget also supports receiver-side selection at runtime:- reuse the origin wallet when the buy-side namespace matches
- connect a separate destination wallet
- paste a receiver address directly in the UI

