"use client"; import { signIn, signOut } from "next-auth/react"; import { SyntheticEvent } from "react"; import { Session } from "next-auth"; import { Button } from "@nextui-org/button"; interface SignInProps { session: Session | null; } export default function SignIn({ session }: SignInProps) { const handleSignIn = async (event: SyntheticEvent) => { event.preventDefault(); await signIn("github"); }; const handleSignOut = async (event: SyntheticEvent) => { event.preventDefault(); await signOut(); }; return session?.user ? (
) : (
); }