28 lines
742 B
TypeScript
28 lines
742 B
TypeScript
type SectionIntroProps = {
|
|
eyebrow: string;
|
|
title: string;
|
|
description?: string;
|
|
align?: "left" | "center";
|
|
};
|
|
|
|
export function SectionIntro({
|
|
eyebrow,
|
|
title,
|
|
description,
|
|
align = "left",
|
|
}: SectionIntroProps) {
|
|
return (
|
|
<div className={align === "center" ? "mx-auto max-w-3xl text-center" : "max-w-3xl"}>
|
|
<p className="text-xs font-bold uppercase tracking-[0.24em] text-[var(--accent)]">
|
|
{eyebrow}
|
|
</p>
|
|
<h2 className="mt-4 font-heading text-3xl font-extrabold tracking-[-0.04em] text-[var(--ink)] md:text-5xl">
|
|
{title}
|
|
</h2>
|
|
{description ? (
|
|
<p className="mt-5 text-base leading-8 text-[var(--muted)] md:text-lg">{description}</p>
|
|
) : null}
|
|
</div>
|
|
);
|
|
}
|