Create a modal for crypto deposits, that says deposit, and its a multi step form which on the first it asks you which currency (and chain) (only stablecoins like USDC and USDT are supported), and also what wallet you are depositing from. When you click next it should come up with a QR code and wallet address that you can send funds to, then you can click "I have sent funds" and it comes up with a loading state while the backend confirms the transaction
I've created a multi-step modal for crypto deposits with the following features:
Step 1: Select Currency and Chain
Step 2: QR Code and Wallet Address
Step 3: Confirmation/Loading
The component uses shadcn/ui components for the UI elements and includes a step indicator at the top to show progress. It also handles form validation, copying the wallet address to clipboard, and simulating the backend confirmation process.
To use this component, you'll need to install the react-qr-code
package:
npm install react-qr-code
You can then import and use the CryptoDepositModal
component anywhere in your application.
I've updated the crypto deposit modal to change the selection order and limit the supported chains as requested. Now users will:
The key changes include:
This new flow provides a more logical selection process where users first choose the blockchain network they want to use, and then select which stablecoin they want to deposit on that network.