hero-1
fulldev-ui/hero-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/hero-1.jsonSource
1---2import type { ImageMetadata } from "astro"3import { Image } from "astro:assets"45import { cn } from "@/lib/utils"6import { Badge } from "@/components/ui/badge"7import { Button } from "@/components/ui/button"8import { Section, SectionContainer } from "@/components/ui/section"910type Props = {11 class?: string12 title: string13 description: string14 badge?: {15 label: string16 href: string17 }18 buttons: {19 label: string20 href: string21 variant?: "default" | "outline" | "secondary" | "ghost"22 }[]23 image: {24 src: ImageMetadata25 alt: string26 }27}2829const {30 class: className,31 title,32 description,33 badge,34 buttons,35 image,36} = Astro.props37---3839<Section class={cn("", className)}>40 <SectionContainer class="items-center gap-8 text-center">41 {42 badge && (43 <Badge as="a" href={badge.href} variant="secondary">44 {badge.label}45 </Badge>46 )47 }48 <h149 class="text-foreground max-w-4xl text-4xl leading-[1.1] font-semibold tracking-tight text-balance sm:text-5xl lg:text-6xl"50 >51 {title}52 </h1>53 <p54 class="text-muted-foreground max-w-2xl text-lg leading-relaxed text-balance"55 >56 {description}57 </p>58 <div class="flex flex-wrap justify-center gap-3">59 {60 buttons.map(({ href, label, ...button }, index) => (61 <Button62 as="a"63 href={href}64 size="lg"65 variant={button.variant ?? (index === 0 ? "default" : "secondary")}66 {...button}67 >68 {label}69 </Button>70 ))71 }72 </div>73 </SectionContainer>74 <SectionContainer>75 <Image76 src={image.src}77 alt={image.alt}78 class="aspect-video w-full rounded-xl border object-cover"79 widths={[640, 960, 1280, 1536]}80 sizes="(min-width: 80rem) 80rem, 100vw"81 loading="eager"82 />83 </SectionContainer>84</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 |
