Fold panel
An accordion whose sections are hinged to their headers. Opening turns a section down from edge-on to flat while its height opens, so you can see which header it belongs to and where it goes when it closes. It is the standard accordion underneath: header buttons, aria-expanded, regions named by their header.
- Address
- 2 Rosewood Lane, 1780 Halden
- Method
- Tracked, 2 days
- Cost
- $6.00
- Card
- Visa ending 4821
- Billing name
- Mira Solheim
- Charge date
- On dispatch
- Address
- Same as shipping
- VAT number
- NO 912 345 678
- For the courier
- Leave with the neighbour at number 4 if nobody answers
When to use
- Checkout, settings and order summaries where each section has a one-line summary worth showing while closed.
- Anywhere an accordion should feel attached to its header instead of sliding in from nowhere.
When not to use
- Long article text; a fold per paragraph is a lot of motion.
- Navigation; use the sidebar or tabs.
Installation
pnpm dlx shadcn@latest add @caliper/fold-panel
Adds its 4 files to components/ui/, each with its own stylesheet, and installs their packages. Pro installs with your access token, set up once per project. See Pro access. The first part also adds Caliper UI’s tokens; import them once as in Installation.
API reference
FoldPanel
11 props
Keyboard
- ↓
- Moves to the next item or value.
- ↑
- Moves to the previous item or value.
- Home
- Jumps to the first item or the minimum.
- End
- Jumps to the last item or the maximum.
Accessibility
It is built on native elements and keeps aria-expanded, aria-controls, aria-hidden and aria-labelledby in step with state.
Notes for AI
Give your coding assistant this page as Markdown instead of screenshots: the props, keyboard and examples in one file.
/docs/components/fold-panel.mdThe index of every part is at /llms.txt.