Idles on its own. Grab it and spin it.
Install it the shadcn way: copy the source file into your project. It uses CSS 3D, Tailwind CSS v4 and Framer Motion, no WebGL.
| Prop | Type | Default | Description |
|---|---|---|---|
| faces | ReactNode[] | Faces in order: front, right, back, left, top, bottom. | |
| size | number | 180 | Edge length in px. |
| speed | number | 18 | Degrees per second of idle rotation on Y. 0 disables. |
| perspective | number | 900 | Perspective distance in px. Lower values look more dramatic. |
| className | string | Extra classes added to the outer element. | |
| faceClassName | string | Extra classes added to each face. |
CSS 3D Transforms Without WebGL: Perspective, preserve-3d and the Gotchas