rainbowkit
rainbowkit copied to clipboard
feat: chain modal v2
Changes
- Now you can choose any chains even if your wallet is not connected.
- Works with
siwe
. - During connection process, it automatically selects the chain you picked earlier. Or the one you set as your default
initialChain
instead. - If you've set
initialChain
, the option to change networks will be hidden to prevent accidental switches. - The current chain will show up only even if you have one chain unless you set
chainStatus
tonone
Screen recordings / screenshots
https://github.com/rainbow-me/rainbowkit/assets/53529533/fab003eb-5526-45ca-976d-f8a8afc2e702
What to test
- Checkbox the
chainModalOnConnect
in the example app - Try opening the chain modal and switch through your desired chain
- While connecting your wallet, confirm it connects to the chain you chose.
- Set
initialChain
and check if the chain button is no longer visible. - Make sure everything works well with
siwe
. Test this connecting to your wallet first and then you should see chain button dissapear. This prevents users from switching chains with their connected wallet when they are not signed in yet.