Layer Stack

Hover, tap, or press Enter to explode the stack. Great for architecture diagrams.

Install it the shadcn way: copy the source file into your project. It uses CSS 3D, Tailwind CSS v4 and Framer Motion, no WebGL.

LayerStack props

PropTypeDefaultDescription
layersReactNode[]Layers from bottom to top.
sizenumber170Edge length of each square layer in px.
gapnumber6Z distance between layers when collapsed.
spreadnumber54Z distance between layers when exploded.
classNamestringExtra classes added to the outer element.
layerClassNamestringExtra classes added to each layer.

More components

Guides

Start

Cards

Scenes

Controls & text

Buttons

More cards

UI elements

Form controls

App components

Text & backgrounds

Showpieces

Blocks