Hero
The Hero component provides you with landing page hero sections and banners.
Live Examples
Live Example
View Code
import { Hero } from '@nostromo/ui-marketing' import { Button } from '@nostromo/ui-core' export default function HeroExample() { return ( <Hero title="Welcome to Nostromo UI" subtitle="A comprehensive UI library built with React, TypeScript and Tailwind CSS" cta={ <div className="flex gap-4"> <Button>Get Started</Button> <Button variant="outline">Learn More</Button> </div> } /> ) }
Live Example
View Code
import { Hero } from '@nostromo/ui-marketing' import { Button } from '@nostromo/ui-core' export default function HeroVariants() { return ( <div className="space-y-8"> <Hero title="Default Hero" subtitle="Standard hero section with center alignment" size="md" variant="default" cta={<Button>Get Started</Button>} /> <Hero title="Accent Hero" subtitle="Hero with accent variant styling" size="lg" variant="accent" contentAlign="left" cta={<Button variant="outline">Learn More</Button>} /> </div> ) }
Code Examples
Props
| Prop | Type | Default | Description |
|---|---|---|---|
title | string | - | Hero title |
subtitle | string | - | Hero subtitle |
cta | ReactNode | - | Call-to-action content |
size | "sm" | "md" | "lg" | "xl" | "md" | Hero size |
variant | "default" | "muted" | "accent" | "default" | Hero variant |
contentAlign | "left" | "center" | "right" | "center" | Content alignment |
backgroundImage | string | - | Background image URL |
overlay | boolean | false | Add overlay effect |