import { ArrowUpRight } from "lucide-react";
import { Button } from "@/components/ui/button";
interface Hero47Props {
heading?: string;
subheading?: string;
description?: string;
image?: {
src: string;
alt: string;
};
buttons?: {
primary?: {
text: string;
url: string;
};
secondary?: {
text: string;
url: string;
};
};
}
const Hero47 = ({
heading = "Epic Blocks",
subheading = " built with shadcn/ui & Tailwind",
description = "Finely crafted components built with React, Tailwind and Shadcn UI. Developers can copy and paste these blocks directly into their project.",
buttons = {
primary: {
text: "Get Started",
url: "#",
},
secondary: {
text: "Read the docs",
url: "#",
},
},
image = {
src: "https://shadcnblocks.com/images/block/placeholder-dark-7-tall.svg",
alt: "Placeholder",
},
}: Hero47Props) => {
return (
<section className="bg-background py-20 lg:py-32">
<div className="container flex flex-col items-center gap-10 lg:my-0 lg:flex-row">
<div className="flex flex-col gap-7 lg:w-2/3">
<h2 className="text-5xl font-semibold text-foreground md:text-5xl lg:text-8xl">
<span>{heading}</span>
<span className="text-muted-foreground">{subheading}</span>
</h2>
<p className="text-base text-muted-foreground md:text-lg lg:text-xl">
{description}
</p>
<div className="flex flex-wrap items-start gap-5 lg:gap-7">
<Button asChild>
<a href={buttons.primary?.url}>
<div className="flex items-center gap-2">
<ArrowUpRight className="size-4" />
</div>
<span className="whitespace-nowrap pl-4 pr-6 text-sm lg:pl-6 lg:pr-8 lg:text-base">
{buttons.primary?.text}
</span>
</a>
</Button>
<Button asChild variant="link" className="underline">
<a href={buttons.secondary?.url}>{buttons.secondary?.text}</a>
</Button>
</div>
</div>
<div className="relative z-10">
<div className="absolute !left-1/2 top-2.5 !h-[92%] !w-[69%] -translate-x-[52%] overflow-hidden rounded-[35px]">
<img
src={image.src}
alt={image.alt}
className="size-full object-cover object-[50%_0%]"
/>
</div>
<img
className="relative z-10"
src="https://shadcnblocks.com/images/block/mockups/phone-2.png"
width={450}
height={889}
alt="iphone"
/>
</div>
</div>
</section>
);
};
export { Hero47 };