crucıble

Casebook

B2B customer-stories section block: a strip of original customer wordmarks acts as a tablist with a sliding accent underline and auto-advance progress line; the featured story crossfades in with a word-staggered pull quote, seeded avatar attribution and a metric rail rolling on Tally digit drums; below, an industry-filtered (Detent) story grid re-flows with layout springs, each card carrying seeded procedural cover art, cursor tilt and a hover-revealed read link.

motionpro

Installation

CLI

npx shadcn@latest add @crucible/casebook

Manual — install dependencies, then copy the source

npm install motion

Props

PropTypeDefaultDescription
featuredCasebookStory[]six seeded sample storiesStories in the featured strip (4–6 reads best). Pass [] to hide the featured strip.
storiesCasebookStory[]eight seeded sample storiesStories in the filterable grid below. Pass [] to hide the grid.
industriesstring[]Industry filter tabs, in order. Omit to derive from stories. Pass [] to hide the filter.
autoplaybooleantrueAuto-advance the featured story (pauses on hover/focus, offscreen, hidden tab; off under reduced motion).
intervalnumber7000Milliseconds each featured story is shown while autoplaying.
indexnumberControlled featured index.
defaultIndexnumber0Initial featured index when uncontrolled.
onIndexChange(index: number) => voidFires whenever the featured index changes (click, keyboard, autoplay, goTo).
onSelect(story: CasebookStory, source: "featured" | "grid") => voidFires when a "Read story" link/button or grid card is activated.
eyebrowReact.ReactNode"Customer stories"Small label above the headline. null hides it.
titleReact.ReactNode"Results our customers can measure"Section headline (<h2>). null hides the header.
descriptionReact.ReactNodeSupporting copy under the headline. null hides it.
gridTitleReact.ReactNode"More stories"Heading above the story grid. null hides it.
readLabelstring"Read the story"Label of the featured "read" link.
allLabelstring"All"Label of the "show everything" filter tab.
accentColorstring"#f5d0a9"Signature accent hex: active underline, progress line, metric rules, focus rings.
coverTone"seeded" | "accent""seeded"Grid cover-art palette. "seeded" gives every card its own hue from the company name; "accent" keeps the seeded composition but draws both glows from accentColor's hue family so covers match the brand.
refReact.Ref<CasebookHandle>Imperative handle (replay(), goTo(i)). React 19 ref-as-prop.
classNamestringExtra classes for the <section> root.
Also accepts all props of Omit<React.ComponentPropsWithoutRef<"section">, "children" | "title" | "onSelect"> — they pass through to the underlying element.

Honors prefers-reduced-motion with a designed static fallback, and passes className through.