import { Content } from './Content';
import { useAppContext } from './AppContext';

export function Main() {
  const { user } = useAppContext();
  return (
    <main className="py-8">
      <h1 className="text-3xl text-center font-bold underline">Witaj</h1>
      <p className="mt-8 text-xl text-center">{user ? `Cześć ${user.name}!` : 'Proszę, zaloguj się'}</p>
      <Content />
    </main>
  );
}
