Curve Wall
A full-bleed wall of portrait media bowed into a soft lens, with drag momentum, a shared-wall hover lift, a spotlight vignette, and an in-place media viewer.
Installation#
pnpm dlx shadcn@latest add @davinciui/curve-wallUsage#
Tiles support images or muted, looping video. Clicking a tile expands it into an in-place viewer; an optional href appears as a secondary Visit button inside that viewer. The wall repeats the media across the viewport, so keep the item list focused and give every item meaningful alternative text.
API Reference#
| Prop | Type | Default |
|---|---|---|
itemsImages or videos repeated across the wall. | CurveWallItem[] | — |
columnsColumns used to size the grid. | number | 5 |
gapGap between cells in pixels. | number | 12 |
ratioTile width divided by height. | number | 0.8 |
tileScaleScale applied to tile size and grid pitch. | number | 0.86 |
fitHow wall media fits inside each tile. | "cover" | "contain" | "cover" |
radiusTile corner radius in pixels. | number | 6 |
driftHorizontal drift applied to media inside each tile. | number | 0.4 |
bowCurvature strength. Positive swells outward. | number | 0.16 |
lensCursor lens strength. | number | 0.22 |
reachCursor lens reach relative to the smaller cell side. | number | 1.4 |
dragSpeedMultiplier applied to drag movement. | number | 1 |
wheelSpeedMultiplier applied to wheel movement. | number | 1 |
settleGlide retained after a fling. | number | 0.92 |
wanderIdle drift in pixels per second. | number | 0 |
headingIdle drift angle in degrees. | number | 215 |
scatterShuffle the media order across cells. | boolean | true |
seedShuffle seed. | number | 7 |
spotlightRender the spotlight vignette. | boolean | true |
shadeVignette shade between 0 and 1. | number | 0.62 |
holeClear radius of the spotlight. | number | 0.9 |
featherSpotlight falloff. | number | 0.9 |
tintVignette and backdrop tint. | string | "#08080a" |
backgroundStage background. Follows the active theme by default. | string | "var(--background, #000000)" |
interactiveEnable drag, wheel, hover, keyboard, and the viewer. | boolean | true |
ariaLabelAccessible name for the gallery region. | string | "Curve media wall" |
classNameAdditional classes for the stage. | string | — |
styleAdditional styles for the stage. | CSSProperties | — |
Accessibility#
Every tile is a labeled button with aria-expanded, and the active tile is the only one reachable while its viewer is open because the rest become inert. Enter or Space opens and closes the viewer, Escape and outside clicks close it, focus returns to the tile, and ArrowLeft, ArrowRight, ArrowUp, and ArrowDown pan the closed wall.
Motion#
Each tile is projected from a shared bowed vertex grid through a homography every frame. Drag and wheel feed an inertial glide that settles at 0.92 per 60fps frame, while hover lifts a small surface bump through the same projection so neighbours stay attached. Clicking a tile animates its four corners into a flat viewer over 550ms; reduced motion removes the lift and makes the viewer transition instant.
View source
Keep in mind
Need a custom component?
I build bespoke UI components & websites tailored to your brand.

