diff --git a/src/app/(auth)/forgot-password/components/forgot-password-form-1.tsx b/src/app/(auth)/forgot-password/components/forgot-password-form-1.tsx index 055a05d..c1cdfce 100644 --- a/src/app/(auth)/forgot-password/components/forgot-password-form-1.tsx +++ b/src/app/(auth)/forgot-password/components/forgot-password-form-1.tsx @@ -1,57 +1,87 @@ -"use client" +"use client"; -import { cn } from "@/lib/utils" -import { Button } from "@/components/ui/button" -import { - Card, - CardContent, - CardDescription, - CardHeader, - CardTitle, -} from "@/components/ui/card" -import { Input } from "@/components/ui/input" -import { Label } from "@/components/ui/label" +import Link from "next/link"; +import { useActionState } from "react"; +import { ArrowLeft, Loader2, MailCheck } from "lucide-react"; + +import { Button } from "@/components/ui/button"; +import { Card, CardContent, CardDescription, CardHeader, CardTitle } from "@/components/ui/card"; +import { Input } from "@/components/ui/input"; +import { Label } from "@/components/ui/label"; +import { cn } from "@/lib/utils"; +import { forgotPasswordAction, initialAuthState } from "@/lib/appwrite/auth-actions"; + +export function ForgotPasswordForm1({ className, ...props }: React.ComponentProps<"div">) { + const [state, formAction, isPending] = useActionState(forgotPasswordAction, initialAuthState); -export function ForgotPasswordForm1({ - className, - ...props -}: React.ComponentProps<"div">) { return (
+ Hesabınıza giriş yaparak işletmenizi yönetmeye devam edin +
++ {state.error} +
+ )} + + + ++ Giriş yaparak{" "} + + Kullanım Şartları + {" "} + ve{" "} + + Gizlilik Politikası + + 'nı kabul etmiş olursunuz. +
++ Müşteriler, hizmetler, takvim, görevler ve finans — hepsi tek yerde, multi-tenant ve ekibinize özel. +
++ Birkaç saniye içinde hesabınız hazır +
+En az 8 karakter
++ {state.error} +
+ )} + + + ++ Hesap oluşturarak{" "} + + Kullanım Şartları + {" "} + ve{" "} + + Gizlilik Politikası + + 'nı kabul etmiş olursunuz. +
++ Hesap oluşturduktan sonra çalışma alanınızı kuruyor, ekibinizi davet ediyor ve hemen kullanmaya başlıyorsunuz. +
+