Skip to content

Commit 62b29e0

Browse files
committed
chore: add ability to switch wallets and chains to demo app
1 parent 302a055 commit 62b29e0

3 files changed

Lines changed: 19 additions & 5 deletions

File tree

apps/customer/components/MoneriumConnect/MoneriumConnect.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ export const MoneriumConnect = () => {
7474
fullWidth
7575
size="large"
7676
variant="contained"
77-
onClick={() => authorize()}
77+
onClick={() => authorize({ skipKyc: true })}
7878
sx={{
7979
py: 1.75,
8080
fontSize: '1rem',

apps/customer/components/Navigation/TopBar.tsx

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,12 +7,13 @@ import Toolbar from '@mui/material/Toolbar';
77
import Typography from '@mui/material/Typography';
88

99
import { ThemeModeToggle } from 'components/ThemeModeToggle/ThemeModeToggle';
10+
import { ConnectButton } from '@rainbow-me/rainbowkit';
1011

1112
export const TopBar = () => {
1213
const router = useRouter();
1314
return (
1415
<AppBar position="fixed" elevation={0}>
15-
<Toolbar>
16+
<Toolbar sx={{ gap: '16px' }}>
1617
<Typography
1718
variant="subtitle1"
1819
component="div"
@@ -25,7 +26,10 @@ export const TopBar = () => {
2526
>
2627
Monerium
2728
</Typography>
28-
<ThemeModeToggle />
29+
<ConnectButton chainStatus="icon" />
30+
<IconButton>
31+
<ThemeModeToggle />
32+
</IconButton>
2933
<IconButton
3034
onClick={() => router.push('/profile')}
3135
aria-label="Profile"

apps/customer/config/wagmi.config.ts

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
import { createConfig, http } from 'wagmi';
2-
import { sepolia } from 'wagmi/chains';
2+
import {
3+
sepolia,
4+
arbitrumSepolia,
5+
polygonAmoy,
6+
lineaSepolia,
7+
baseSepolia,
8+
} from 'wagmi/chains';
39
import { connectorsForWallets } from '@rainbow-me/rainbowkit';
410
import {
511
metaMaskWallet,
@@ -37,11 +43,15 @@ const getConnectors = () => {
3743
};
3844

3945
export const config = createConfig({
40-
chains: [sepolia],
46+
chains: [sepolia, arbitrumSepolia, polygonAmoy, lineaSepolia, baseSepolia],
4147
connectors: getConnectors(),
4248
ssr: true,
4349
transports: {
4450
[sepolia.id]: http(),
51+
[arbitrumSepolia.id]: http(),
52+
[polygonAmoy.id]: http(),
53+
[lineaSepolia.id]: http(),
54+
[baseSepolia.id]: http(),
4555
},
4656
});
4757

0 commit comments

Comments
 (0)