feat: add policy pages
This commit is contained in:
@@ -16,6 +16,7 @@
|
||||
import { useState } from "react";
|
||||
import Link from "next/link";
|
||||
import { useAuth } from "@/components/auth/auth-provider";
|
||||
import { OAuthButtons } from "@/components/auth/oauth-buttons";
|
||||
import { AuthError } from "@/lib/auth";
|
||||
import { Button } from "@/components/ui/button";
|
||||
import { Input } from "@/components/ui/input";
|
||||
@@ -25,10 +26,13 @@ export function LoginForm({
|
||||
onSuccess,
|
||||
forgotPasswordHref = "/forgot-password",
|
||||
showForgotLink = true,
|
||||
oauthNext,
|
||||
}: {
|
||||
onSuccess?: () => void;
|
||||
forgotPasswordHref?: string;
|
||||
showForgotLink?: boolean;
|
||||
/** Post-OAuth redirect path on the frontend. */
|
||||
oauthNext?: string;
|
||||
}) {
|
||||
const { logIn } = useAuth();
|
||||
const [email, setEmail] = useState("");
|
||||
@@ -51,7 +55,9 @@ export function LoginForm({
|
||||
}
|
||||
|
||||
return (
|
||||
<form onSubmit={onSubmit} className="space-y-5">
|
||||
<div className="space-y-5">
|
||||
<OAuthButtons next={oauthNext} />
|
||||
<form onSubmit={onSubmit} className="space-y-5">
|
||||
<div className="space-y-1.5">
|
||||
<Label htmlFor="login-email">Email</Label>
|
||||
<Input
|
||||
@@ -88,6 +94,7 @@ export function LoginForm({
|
||||
<Button type="submit" disabled={submitting} className="w-full h-11 text-base">
|
||||
{submitting ? "Logging in…" : "Log in"}
|
||||
</Button>
|
||||
</form>
|
||||
</form>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user