import { ConnectButton } from '@rainbow-me/rainbowkit'; import { AwesomeButton } from 'react-awesome-button'; export function Wallet() { return ( {({ account, chain, openAccountModal, openChainModal, openConnectModal, mounted, }) => { const ready = mounted; const connected = ready && account && chain; return (
{(() => { if (!connected) { return ( { openConnectModal(); release(); }}> Connect Wallet ); } if (chain.unsupported) { return ( { openChainModal(); release(); }}> Wrong network ); } return (
{ openChainModal(); release(); }}> {chain.hasIcon && (
{chain.iconUrl && ( {chain.name )}
)} {chain.name}
{ openAccountModal(); release(); }}> {account.displayName} {account.displayBalance ? ` (${account.displayBalance})` : ''}
); })()}
); }}
); };