"use client" import { Button } from "@/components/ui/button" import { motion } from "framer-motion" import type React from "react" import { useState } from "react" interface CheckmarkProps { size?: number strokeWidth?: number className?: string color?: string } const draw = { hidden: { pathLength: 0, opacity: 0 }, visible: (i: number) => ({ pathLength: 1, opacity: 1, transition: { pathLength: { delay: i * 0.2, type: "spring", duration: 1.5, bounce: 0.2, ease: "easeInOut", }, opacity: { delay: i * 0.2, duration: 0.2 }, }, }), } export function Checkmark({ size = 100, strokeWidth = 2, color = "currentColor", className = "" }: CheckmarkProps) { return ( Animated Checkmark ) } export default function SubscriptionEmail() { const [email, setEmail] = useState("") const [isSubmitting, setIsSubmitting] = useState(false) const [isSubmitted, setIsSubmitted] = useState(false) const [isFocused, setIsFocused] = useState(false) const handleSubmit = async (e: React.FormEvent) => { e.preventDefault() if (!email || !/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(email)) return setIsSubmitting(true) await new Promise((resolve) => setTimeout(resolve, 1200)) setIsSubmitting(false) setIsSubmitted(true) } const containerVariants = { hidden: { opacity: 0, y: 20 }, visible: { opacity: 1, y: 0, transition: { duration: 0.6, ease: [0.25, 0.46, 0.45, 0.94], }, }, } return (
{!isSubmitted ? ( <>

Stay Updated

Get notified when we launch new features and updates.

setEmail(e.target.value)} onFocus={() => setIsFocused(true)} onBlur={() => setIsFocused(false)} placeholder="Enter your email" required className="w-full px-4 py-3.5 bg-zinc-50/80 dark:bg-zinc-800/50 border border-zinc-200 dark:border-zinc-700 rounded-xl text-zinc-900 dark:text-white placeholder-zinc-500 dark:placeholder-zinc-400 outline-none transition-colors duration-200 focus:bg-white dark:focus:bg-zinc-800 focus:border-zinc-300 dark:focus:border-zinc-600" />

We respect your privacy. Unsubscribe at any time.

) : (

You're all set!

Thanks for subscribing. We'll keep you updated with our latest news.

)}
) }