Hero: showcase
Headline over a framed slot for a real, working component.
Preview
The frame rises and scales into place after the headline, and lifts slightly on hover. With reduced motion turned on, it renders the plain layout.
See it working before you sign up
Put a real, working component under the headline. Sample copy.
Weekly active usersSample data
See it working before you sign up
Put a real, working component under the headline. Sample copy.
Weekly active usersSample data
Installation
Run this in a project that already uses shadcn/ui. It adds the component and anything it needs; the motion version also adds the plain one and the motion package.
Usage
import { HeroShowcase } from "@/components/custom/hero-showcase";
<HeroShowcase title="See it working" primaryAction={{ label: "Try it", href: "/try" }}>
<YourLiveComponent />
</HeroShowcase>import { HeroShowcaseMotion } from "@/components/custom/hero-showcase/hero-showcase-motion";
<HeroShowcaseMotion title="See it working">
<YourLiveComponent />
</HeroShowcaseMotion>Props
| Prop | Type | Default | Description |
|---|---|---|---|
| title* (required) | string | – | The headline, rendered as the page's h1. |
| eyebrow | string | – | Small badge above the title. |
| description | string | – | Supporting line under the title. |
| primaryAction | { label: string; href: string } | – | Filled button. |
| secondaryAction | { label: string; href: string } | – | Outline button. |
| children* (required) | ReactNode | – | The live component shown in the frame. |
| ...props | React.ComponentProps<"section"> | – | Any other section attribute (id, aria-*, data-*, ref) goes to the root element. |
| Prop | Type | Default | Description |
|---|---|---|---|
| title* (required) | string | – | The headline, rendered as the page's h1. |
| eyebrow | string | – | Small badge above the title. |
| description | string | – | Supporting line under the title. |
| primaryAction | { label: string; href: string } | – | Filled button. |
| secondaryAction | { label: string; href: string } | – | Outline button. |
| children* (required) | ReactNode | – | The live component shown in the frame. |
| ...props | React.ComponentProps<"section"> | – | Any other section attribute (id, aria-*, data-*, ref) goes to the root element. |
Accessibility
- Whatever you put in the frame keeps its own semantics; the frame adds none.
- The motion version follows the visitor's reduced-motion setting and never hides content before it animates.