62 lines
1.8 KiB
TypeScript
62 lines
1.8 KiB
TypeScript
"use client";
|
|
|
|
import { useState } from "react";
|
|
|
|
import { Button } from "@/components/ui/button";
|
|
import { Input } from "@/components/ui/input";
|
|
import { cn } from "@/lib/utils";
|
|
|
|
const OfferModal1 = () => {
|
|
const [isOpen, setIsOpen] = useState(true);
|
|
|
|
return (
|
|
<div
|
|
dir="rtl"
|
|
lang="fa"
|
|
className="relative flex min-h-[28rem] w-full items-center justify-center p-4 md:min-h-[32rem]"
|
|
>
|
|
{isOpen ? (
|
|
<div
|
|
role="dialog"
|
|
aria-modal="false"
|
|
aria-labelledby="offer-modal1-title"
|
|
className={cn(
|
|
"relative block h-fit w-full max-w-115 space-y-2.5 rounded-sm border bg-popover p-10 text-popover-foreground shadow-lg ring-1 ring-foreground/10",
|
|
)}
|
|
>
|
|
<div className="absolute end-1.5 top-1.5">
|
|
<Button
|
|
type="button"
|
|
variant="ghost"
|
|
className="text-xs text-muted-foreground"
|
|
size="sm"
|
|
onClick={() => setIsOpen(false)}
|
|
>
|
|
بستن
|
|
</Button>
|
|
</div>
|
|
<div className="space-y-2.5">
|
|
<h2
|
|
id="offer-modal1-title"
|
|
className="text-start font-serif text-xl leading-snug font-normal"
|
|
>
|
|
در خبرنامه محصول عضو شوید و ۳۵٪ تخفیف شروع اشتراک سالانه بگیرید
|
|
</h2>
|
|
<Input
|
|
type="email"
|
|
dir="rtl"
|
|
placeholder="ایمیل کاری خود را وارد کنید"
|
|
className="text-start"
|
|
/>
|
|
<Button type="button" className="w-full text-xs">
|
|
عضویت
|
|
</Button>
|
|
</div>
|
|
</div>
|
|
) : null}
|
|
</div>
|
|
);
|
|
};
|
|
|
|
export { OfferModal1 };
|