MultiStepForm
Wizard orchestration: a Stepper nav, the current step's header + content, and Back/Next/Submit.
Signature
Density
Viewport
Theme and light/dark are set in the top barWhen to use
Wizard orchestration: a Stepper nav, the current step's header + content, and Back/Next/Submit.
Accessibility
Always render a visible <label> (the label prop wires htmlFor/id for you). Errors set aria-invalid and are announced via aria-describedby. Required fields expose aria-required.
Install and import
npx shadcn@latest add @prism/multi-step-form
import { MultiStepForm } from '@/components/prism/MultiStepForm';
In a no-build prototype, read it from the bundle instead: const { MultiStepForm } = window.PrismDesignSystem_39d121;
Props
| Prop | Type | Required | Description |
|---|---|---|---|
steps | WizardStep[] | Yes | |
current | number | — | Controlled current index. Omit for uncontrolled. |
defaultCurrent | number | — | |
onStepChange | (index: number) => void | — | |
onComplete | () => void | — | |
canAdvance | (index: number) => boolean | — | Return false to block Next on the given step index. |
layout | "top" | "side" | — | |
labels | \{ step?: string; of?: string; back?: string; next?: string; submit?: string \} | — | |
actions | React.ReactNode | — | Replace the default Back/Next action bar. |