feat: Implement username/password authentication and registration features

This commit is contained in:
beilunyang
2025-01-15 16:00:06 +08:00
parent 969d0ce334
commit 126a4cb948
24 changed files with 2643 additions and 67 deletions
+3 -12
View File
@@ -1,9 +1,9 @@
"use client"
import { Button } from "@/components/ui/button"
import { Mail, Github } from "lucide-react"
import { Mail } from "lucide-react"
import { useRouter } from "next/navigation"
import { signIn } from "next-auth/react"
import { SignButton } from "../auth/sign-button"
interface ActionButtonProps {
isLoggedIn?: boolean
@@ -25,14 +25,5 @@ export function ActionButton({ isLoggedIn }: ActionButtonProps) {
)
}
return (
<Button
size="lg"
onClick={() => signIn("github", { callbackUrl: "/moe" })}
className="gap-2 bg-primary hover:bg-primary/90 text-white px-8"
>
<Github className="w-5 h-5" />
使 GitHub
</Button>
)
return <SignButton size="lg" />
}