Stacked cards shuffle
Swipeable team card deck beside a full roster.
Usage
import { TeamDeck } from '@/components/blocks/team-04'
<TeamDeck />
// Bring your own people
<TeamDeck
heading="Say hello to the team"
autoAdvance={7000}
members={[
{
name: 'Jane Doe',
role: 'Founder',
line: 'Started the company at her kitchen table.',
photo: { src: 'https://example.com/jane.jpg', alt: 'Jane Doe smiling' },
socials: [{ label: 'Website', href: 'https://example.com/janedoe' }],
},
{
name: 'Sam Lee',
role: 'Engineer',
line: 'Keeps the lights on and the builds fast.',
photo: { src: 'https://example.com/sam.jpg', alt: 'Sam Lee in a grey jumper' },
},
]}
onChange={(index, member) => console.log(index, member.name)}
/>
Install
pnpm dlx shadcn@latest add @pastaui-pro/team-04npx shadcn@latest add @pastaui-pro/team-04yarn dlx shadcn@latest add @pastaui-pro/team-04bunx --bun shadcn@latest add @pastaui-pro/team-04Source
Props
| Prop | Type | Default | Description |
|---|---|---|---|
| eyebrow | string | = 'The people' | Small label above the heading. |
| heading | string | = 'Meet the crew behind every release' | Section heading, rendered as an h2 and used as the carousel label. |
| description | string | = Sample description | Muted supporting text under the heading. |
| members | TeamDeckMember[] | = Eight sample people | Each member takes a name, role, a one-line line, a photo ({ src, alt }) and optional socials ({ label, href }[]). Names must be unique. |
| autoAdvance | number | false | = 5000 | Milliseconds each card stays on top before the deck shuffles, or false to turn auto-advance off. Always off under reduced motion. |
| initialIndex | number | = 0 | Which member starts on top. |
| onChange | (index: number, member: TeamDeckMember) => void | = undefined | Called whenever a new card comes to the top. |
| className | string | = undefined | Extra classes for the section. |
| style | CSSProperties | = — | Inline styles, handy for overriding the --pp-* theme variables. |