All components

CTA 2

CTA 2 is a React and Tailwind CSS button component from SmoothUI, licensed MIT. Copy it and paste it into your project.

SmoothUI MIT buttons

What it is

CTA 2 is a React and Tailwind CSS button component from SmoothUI, licensed MIT. Copy it and paste it into your project.

How to use it

Open it in the catalogue, press copy, and paste it into your project. The prompt you copy carries the code and the rules that tell your agent to reproduce it without changing anything.

Open in the catalogue

Five free copies a month. No card.

Needs

npm i motion

Licence

This component comes from SmoothUI and is redistributed under the MIT licence, which permits commercial use. The copyright notice travels with the code.

CTA 2

index.tsx
"use client";

import SmoothButton from "@/components/smoothui/smooth-button";
import { getImageKitUrl } from "@/lib/smoothui-data";
import { motion, useReducedMotion } from "motion/react";

const SPRING = {
  bounce: 0.1,
  duration: 0.25,
  type: "spring" as const,
};

export function CtaSplit() {
  const shouldReduceMotion = useReducedMotion();

  return (
    <section aria-labelledby="cta-split-heading">
      <div className="py-24 md:py-32">
        <div className="mx-auto grid max-w-6xl items-center gap-12 px-6 md:grid-cols-2">
          <motion.div
            initial={
              shouldReduceMotion ? { opacity: 1 } : { opacity: 0, x: -24 }
            }
            transition={shouldReduceMotion ? { duration: 0 } : SPRING}
            viewport={{ once: true }}
            whileInView={
              shouldReduceMotion ? { opacity: 1 } : { opacity: 1, x: 0 }
            }
          >
            <h2
              className="text-balance font-bold text-3xl tracking-tight md:text-4xl"
              id="cta-split-heading"
            >
              Ship faster with animated components
            </h2>
            <p className="mt-4 text-foreground/70 text-lg leading-relaxed">
              Stop building UI from scratch. Use production-ready, beautifully
              animated components that work with your existing design system.
            </p>
            <div className="mt-8 flex flex-wrap gap-4">
              <SmoothButton size="lg" variant="candy">
                Browse Components
              </SmoothButton>
              <SmoothButton size="lg" variant="outline">
                View on GitHub
              </SmoothButton>
            </div>
          </motion.div>

          <motion.div
            className="relative"
            initial={
              shouldReduceMotion ? { opacity: 1 } : { opacity: 0, x: 24 }
            }
            transition={shouldReduceMotion ? { duration: 0 } : SPRING}
            viewport={{ once: true }}
            whileInView={
              shouldReduceMotion ? { opacity: 1 } : { opacity: 1, x: 0 }
            }
          >
            <div className="overflow-hidden rounded-2xl border shadow-lg">
              <img
                alt="Product preview showing animated UI components"
                className="h-auto w-full object-cover"
                draggable={false}
                src={getImageKitUrl("/images/hero-smoothui.png", {
                  format: "auto",
                  quality: 85,
                  width: 800,
                })}
              />
            </div>
          </motion.div>
        </div>
      </div>
    </section>
  );
}

export default CtaSplit;

Similar components