cta-1
fulldev-ui/cta-1FreeBlock
fulldev/ui publishes no description for this item.
Live preview
live · rendered by the registry
Rendered by fulldev/ui on their own page — this is the component running, not a screenshot of it.Install it
npx shadcn@latest add https://ui.full.dev/r/cta-1.jsonSource
1---2import type { ImageMetadata } from "astro"34import { cn } from "@/lib/utils"5import {6 Avatar,7 AvatarFallback,8 AvatarGroup,9 AvatarImage,10} from "@/components/ui/avatar"11import { Button } from "@/components/ui/button"12import { Rating } from "@/components/ui/rating"13import { Section, SectionContainer } from "@/components/ui/section"1415type Props = {16 class?: string17 title: string18 description: string19 buttons?: {20 label: string21 href: string22 variant?: "default" | "outline" | "secondary" | "ghost"23 }[]24 socialProof?: {25 avatars: {26 image?: ImageMetadata27 initials: string28 name?: string29 }[]30 rating: number31 text: string32 }33}3435const {36 class: className,37 title,38 description,39 buttons,40 socialProof,41} = Astro.props42---4344<Section variant="floating" class={cn("", className)}>45 <SectionContainer class="items-center text-center">46 {47 socialProof && (48 <div class="flex flex-col items-center gap-3">49 <AvatarGroup>50 {socialProof.avatars.map((avatar) => (51 <Avatar class="ring-background size-11 ring">52 <AvatarImage53 src={avatar.image}54 alt={avatar.name ?? avatar.initials}55 />56 <AvatarFallback>{avatar.initials}</AvatarFallback>57 </Avatar>58 ))}59 </AvatarGroup>60 <div class="flex items-center gap-2">61 <Rating value={socialProof.rating} />62 <span class="text-muted-foreground text-sm">63 {socialProof.text}64 </span>65 </div>66 </div>67 )68 }69 <div class="flex max-w-2xl flex-col items-center gap-5">70 <h271 class="text-foreground text-3xl leading-[1.1] font-semibold tracking-tight text-balance sm:text-4xl"72 >73 {title}74 </h2>75 <p class="text-muted-foreground text-lg leading-relaxed text-balance">76 {description}77 </p>78 </div>79 {80 buttons?.length && (81 <div class="flex flex-wrap justify-center gap-3">82 {buttons.map(({ href, label, ...button }, index) => (83 <Button84 as="a"85 href={href}86 size="lg"87 variant={88 button.variant ?? (index === 0 ? "default" : "secondary")89 }90 {...button}91 >92 {label}93 </Button>94 ))}95 </div>96 )97 }98 </SectionContainer>99</Section>
What it pulls in
Other registry items
Files it writes
More from fulldev/ui
All 144 items| Component | Registry | Kind | Access | Installs | Command |
|---|---|---|---|---|---|
| article-1article-1 | fulldev/ui | Blocks | Free | no deps | |
| article-2article-2 | fulldev/ui | Blocks | Free | no deps | |
| articles-1articles-1 | fulldev/ui | Blocks | Free | no deps | |
| articles-2articles-2 | fulldev/ui | Blocks | Free | no deps | |
| articles-3articles-3 | fulldev/ui | Blocks | Free | no deps | |
| articles-4articles-4 | fulldev/ui | Blocks | Free | no deps | |
| banner-1banner-1 | fulldev/ui | Blocks | Free | no deps | |
| banner-2banner-2 | fulldev/ui | Blocks | Free | no deps |
