import { useEffect, useState } from 'react' import { ExclamationTriangleIcon } from '@heroicons/react/20/solid' import { useWallet } from '@solana/wallet-adapter-react' import ConnectedMenu from './wallet/ConnectedMenu' import ConnectWalletButton from './wallet/ConnectWalletButton' import useOnlineStatus from 'hooks/useOnlineStatus' import ThemeToggle from './ThemeToggle' import Link from 'next/link' import { useRouter } from 'next/router' import BoostLogo from './BoostLogo' const TopBar = () => { const { connected } = useWallet() const [copied, setCopied] = useState('') const isOnline = useOnlineStatus() const router = useRouter() const { pathname } = router useEffect(() => { setTimeout(() => setCopied(''), 2000) }, [copied]) return (
Boost!
{connected ? : }
{!isOnline ? (

Your connection appears to be offline

) : null}
) } export default TopBar const NavLink = ({ active, path, text, }: { active: boolean path: string text: string }) => { return ( {text} ) }