BlockDex

Components

Registries

Free blocks

Method

BlockDex

Components

Registries

Free blocks

Method

Open API

BlockDex

Components

Registries

Free blocks

Method

Open API

Components/tripled/cta-banner-section-baseui

CTA Banner Section

tripled/cta-banner-section-baseui
FreeBlock

Animated call-to-action banner with gradient background and button animations (Base UI)

Live preview

live · rendered by the registry
Rendered by tripled on their own page — this is the component running, not a screenshot of it.

Install it

npx shadcn@latest add https://ui.tripled.work/r/cta-banner-section-baseui.json

Source

@uitripled/react-baseui/src/components/sections/cta-banner-section-baseui.tsxui.tripled.work/r/cta-banner-section-baseui.json · first 6 KB
1"use client";
2
3import { Button } from "@base-ui/react/button";
4import {
5 AnimatePresence,
6 motion,
7 MotionConfig,
8 useInView,
9 useReducedMotion,
10 type Variants,
11} from "framer-motion";
12import { ArrowRight, ChevronRight, Sparkles, Zap } from "lucide-react";
13import { useId, useMemo, useRef, useState } from "react";
14
15const motionPresets = {
16 smooth: { type: "spring" as const, bounce: 0.3, duration: 0.4 },
17 bounce: { type: "spring" as const, bounce: 0.5, duration: 0.35 },
18 fade: { type: "tween" as const, ease: [0.26, 0.08, 0.25, 1] as const, duration: 0.2 },
19};
20
21const highlights = [
22 { id: "highlight-free", label: "Free Forever", icon: Zap },
23 { id: "highlight-credit", label: "No Credit Card", icon: Sparkles },
24 { id: "highlight-oss", label: "Open Source", icon: ChevronRight },
25];
26
27interface CTABannerSectionBaseuiProps {
28 motionPreset?: keyof typeof motionPresets;
29 className?: string;
30}
31
32export function CTABannerSectionBaseui({
33 motionPreset = "smooth",
34 className = "",
35}: CTABannerSectionBaseuiProps) {
36 const ref = useRef<HTMLDivElement | null>(null);
37 const isInView = useInView(ref, { once: true, margin: "-10% 0px" });
38 const shouldReduceMotion = useReducedMotion();
39 const [hoveredButton, setHoveredButton] = useState<"primary" | "secondary" | null>(null);
40
41 const titleId = useId();
42 const descriptionId = useMemo(() => `${titleId}-description`, [titleId]);
43
44 const reducedMotionVariants: Variants = {
45 hidden: { opacity: 0 },
46 visible: { opacity: 1 },
47 };
48
49 const containerVariants: Variants = useMemo(
50 () =>
51 shouldReduceMotion
52 ? reducedMotionVariants
53 : {
54 hidden: { opacity: 0 },
55 visible: {
56 opacity: 1,
57 transition: {
58 staggerChildren: 0.1,
59 delayChildren: 0.2,
60 },
61 },
62 },
63 [shouldReduceMotion]
64 );
65
66 const itemVariants: Variants = useMemo(
67 () =>
68 shouldReduceMotion
69 ? reducedMotionVariants
70 : {
71 hidden: { opacity: 0, y: 20 },
72 visible: {
73 opacity: 1,
74 y: 0,
75 transition: { duration: 0.4 },
76 },
77 },
78 [shouldReduceMotion]
79 );
80
81 // Button micro-interaction variants
82 const buttonVariants: Variants = {
83 idle: { y: 0 },
84 hover: { y: -4 },
85 tap: { y: 0, scale: 0.98 },
86 };
87
88 return (
89 <MotionConfig
90// … truncated

What it pulls in

npm packages

  • framer-motion
  • react

Other registry items

  • button

Files it writes

  • @uitripled/react-baseui/src/components/sections/cta-banner-section-baseui.tsx

Facts

Registry
tripled
Type
registry:page
Access
Free
Files written
1
Licence
MIT
First indexed
2026-08-03
Last confirmed
yesterday

Go to the source

Docs on tripled ui.tripled.work moumen-soliman/uitripled on GitHub Raw registry item This item as JSON

More from tripled

All 282 items
Same registry, same kind — the ones you would have found next
ComponentRegistryKindAccessInstallsCommand
About Us Pageabout-us-page-shadcnuitripledBlocksFree2 deps
About Usabout-us-section-baseuitripledBlocksFree2 deps
About Usabout-us-section-shadcnuitripledBlocksFree2 deps
Auto-Revealing Headingauto-revealing-heading-shadcnuitripledBlocksFree2 deps
Bento Grid Blockbento-grid-block-baseuitripledBlocksFree2 deps
Bento Grid Blockbento-grid-block-shadcnuitripledBlocksFree2 deps
Blog Blockblog-block-baseuitripledBlocksFree2 deps
Blog Blockblog-block-shadcnuitripledBlocksFree2 deps
BlockDex

Built by

Kynth Studio

Index

Components
Registries
Method
Open API

Guides

shadcn component libraries
Best shadcn registries
Free shadcn blocks

Reference

Corpus counts
Crawl health
hello@kynth.studio
Privacy
Terms

BlockDex

BlockDex

Built by

Kynth Studio

Index

Components
Registries
Method
Open API

Guides

shadcn component libraries
Best shadcn registries
Free shadcn blocks

Reference

Corpus counts
Crawl health
hello@kynth.studio
Privacy
Terms

BlockDex

BlockDex

Built by

Kynth Studio

Index

Components
Registries
Method
Open API

Guides

shadcn component libraries
Best shadcn registries
Free shadcn blocks

Reference

Corpus counts
Crawl health
hello@kynth.studio
Privacy
Terms

BlockDex