Hero
Depth Drift Hero
Photo cards drift out of the dark towards you, sharpening as they pass the headline.
npx motionsnack add depth-drift-heroCustomize
Background
<DepthDriftHero />Props
17 properties
| Property | Type | Default | Description |
|---|---|---|---|
| primaryCta | { label: string; href?: string } | { label: 'Explore the library', href: '#' } | Filled button. An empty label hides it. |
| secondaryCta | { label: string; href?: string } | { label: 'Contact us', href: '#' } | Glass button. An empty label hides it. |
| buttonColor | string | light/dark class | Colour of the filled button. |
| buttonTextColor | string | light/dark class | Text colour of the filled button. |
| buttonRadius | number | light/dark class | Corner radius of the buttons in px (fully round by default). |
| photos | { src: string; alt: string }[] | 3 demo photos | Photos for the cards. They repeat across the field; an empty list shows no cards. |
| badgeTag | string | 'New' | One short word in the chip of the badge. Leave empty for no chip. |
| badgeIcon | boolean | true | Small spark icon at the start of the badge. |
| title | string | 'Step inside
the moments that move' | Headline. Use \n for line breaks. |
| Button | ComponentType | built-in | Button component from the library for the filled button. Without one the section draws its own. |
| background | string | '#000000' | Base colour of the section. Default: white, black in dark mode. |
| cards | number | 46 | Number of floating cards. |
| speed | number | 1 | How fast the cards fly towards you. 0 stops them. |
| cardSize | number | 110 | Size of a card when it is closest. |
| depthBlur | number | 6 | Blur of the most distant cards. |
| clearRadius | number | 0.55 | Radius of the calm area around the copy. |
| showBadge | boolean | true | Show the pill above the headline. |
About Depth Drift Hero
Dozens of photo cards float in depth. Distant ones are small, blurred and faint; as they fly towards the camera they grow, sharpen and slide out to the edges, then respawn far away — an endless, calm fly-through. The area around the copy stays clear.
What's included
- Endless depth fly-through
- Depth-of-field blur
- Clear zone around the copy
- Silver and glass buttons
- Reduced-motion still field
- Type
- Animated hero section for Next.js
- Library
- Sections · Hero
- Stack
- Next.js, React, Tailwind CSS
- Added
- 2026-09-20
- Install
npx motionsnack add depth-drift-hero