Steps
Progress through a multi-step flow (done, current, upcoming).
Code
import * as React from 'react';
import { Steps } from '@fruit-labs/design';
export default function Demo() {
return (
<div
style={{
maxWidth: 480,
}}
>
<Steps steps={['Account', 'Workspace', 'Invite']} current={1} />
</div>
);
}Checkout
import { Steps } from '@fruit-labs/design';
export default function Example() {
return (
<div style={{ display: 'flex', flexDirection: 'column', gap: 12, maxWidth: 560 }}>
<Steps steps={['Cart', 'Address', 'Payment', 'Done']} current={2} />
</div>
);
}Install
From npm:
npm install @fruit-labs/design
import { Steps } from '@fruit-labs/design';Or copy the TypeScript source into your project:
npx shadcn@latest add https://design.fruitlabs.online/r/steps.jsonGuidelines
- 3–5 steps with short nouns.
Props
| Prop | Type | Required |
|---|---|---|
steps | React.ReactNode[] | Yes |
current | number | No |
className | string | No |