import { useAppKit } from '@reown/appkit/react' import { useAccount } from 'wagmi' import { Button, GardenFullLogo, Typography } from '@gardenfi/garden-book' import { routes } from '../constants/constants'; import { isCurrentRoute, trimAddress } from '../utils/utils'; function Navbar() { const { open } = useAppKit(); const { isConnected, address } = useAccount(); return (
{routes.map(([, route]) => { const paths = route.path; const isActive = paths.some(isCurrentRoute); const primaryPath = paths[0]; return ( {route.name} ); })}
{isConnected && address ? (
Connected: {trimAddress(address)}
) : ( )}
); } export default Navbar