uiniverse

sections

CTASection

Centered call-to-action block with heading, description, and primary/secondary action buttons.

v1.0.0react >=18next >=14tailwind >=4motion >=12
ctacall-to-actionconversionsectionlanding

Preview

Loading preview...

Props

PropTypeDefaultDescription
heading*ReactNode—Primary heading content
descriptionReactNode—Supporting description text
primaryActionReactNode—Primary action element (button or link)
secondaryActionReactNode—Secondary action element (button or link)
classNamestring—Additional Tailwind classes for the outer section
idstring—HTML id attribute

Slots

SlotTypeRequiredDescription
headingReactNodeYesPrimary heading (h2 or styled text)
descriptionReactNodeNoSupporting description paragraph
primaryActionReactNodeNoPrimary action button (e.g., ShimmerButton)
secondaryActionReactNodeNoSecondary action button or link

Layout

Display: flex
Responsive: Yes

Centered CTA block with heading, description, and action buttons. Max-width constrained.

Examples

Basic CTA

<CTASection
  heading={<h2 className="text-4xl font-bold">Ready to get started?</h2>}
  description={<p className="text-lg text-neutral-400">Join thousands of developers building with ui-universe.</p>}
  primaryAction={<button className="rounded-full bg-white px-8 py-3 text-black">Start Free</button>}
  secondaryAction={<a href="/docs" className="text-neutral-400 underline">Read the docs</a>}
/>

With ShimmerButton

<CTASection
  heading={<h2 className="text-4xl font-bold">Ship faster today</h2>}
  description={<p className="text-lg text-neutral-400">Beautiful, animated UI in minutes.</p>}
  primaryAction={<ShimmerButton>Get Started</ShimmerButton>}
/>

Over background

<div className="relative">
  <GradientMesh className="absolute inset-0" />
  <CTASection
    heading={<h2 className="text-5xl font-bold">Build something beautiful</h2>}
    primaryAction={<button className="rounded-full bg-white px-8 py-3 text-black">Explore Components</button>}
  />
</div>

AI Usage Hint

Use CTASection as the final conversion section on a landing page. Pass heading, description, and action buttons. Pair primaryAction with ShimmerButton for emphasis. Place over a GradientMesh background for visual impact.

Works Well With

ShimmerButtonFadeUpGradientMesh