crucıble

Plenum

R3F z-axis gallery fly-through: frames mounted on fresnel-edged glass panes float down a corridor in an alternating left/right rhythm; wheel, drag or arrow keys fly the camera through with eased banking while passing panes dissolve and fog swallows the distance. Click or Enter glides square-on to a pane, Escape returns. Idle drift loops seamlessly via recycled panes; offscreen-paused, reduced-motion-safe, CSS fallback.

r3fpro

Installation

CLI

npx shadcn@latest add @crucible/plenum

Manual — install dependencies, then copy the source

npm install three @react-three/fiber

Props

PropTypeDefaultDescription
itemsPlenumItem[]eight seeded procedural plates. Loops seamlesslyFrames hung along the corridor.
speednumber1Multiplier for the idle drift and for scroll / drag fly-through speed.
spacingnumber1.15Distance between consecutive panes along the corridor, in pane widths (≈1.7 units each).
fognumber0.45Depth fog, 0 (clear to the end of the corridor) → 1 (dense haze).
interactivebooleantrueWheel / drag to fly, click a pane to focus it. Keyboard always works.
pausedbooleanfalseFreeze the idle drift and the intro; steps and focus still ease on demand.
labelstring"Gallery"Accessible name for the gallery.
childrenReact.ReactNodeOverlay content laid over the stage (pointer events pass through to the corridor).
classNamestringExtra classes for the root element.
refReact.Ref<PlenumHandle>Imperative handle: next(), prev(), focus(i), release().

Honors prefers-reduced-motion with a designed static fallback, pauses offscreen and on hidden tabs, and passes className through.