import { firebaseLogin, firebaseLogout, User } from '../lib/firebase/users' import { Header } from '../components/header' import { useUser } from '../hooks/use-user' import { ContractsList } from '../components/contracts-list' import { Title } from '../components/title' import { Row } from '../components/layout/row' import { formatMoney } from '../lib/util/format' function UserCard(props: { user: User }) { const { user } = props return (
{user?.avatarUrl && ( )}

{user?.name}

{user?.email}

{formatMoney(user?.balance)}

) } function SignInCard() { return (

Welcome!

Sign in to get started

) } export default function Account() { const user = useUser() return (
{user ? (
<ContractsList /> </div> ) : ( <SignInCard /> )} </div> </div> ) }