Data

Collapsible

One region that shows and hides with an animated height, like "Show 3 more stops". For a list of sections use Accordion.
import { Collapsible, CollapsibleTrigger, CollapsibleContent } from "pleate/collapsible";

Show more stops

Lisbon to Porto

  • 09:10Santa Apolonia, depart

Props

open / defaultOpen / onOpenChange

Controlled or uncontrolled state (Radix).

CollapsibleTrigger asChild

Render your own Button or row as the trigger.

boolean

CollapsibleContent forceMount

Keep the content in the DOM while closed (Radix).

boolean

Accessibility

  • The trigger gets aria-expanded and aria-controls.
  • Space and Enter toggle it.
  • The height animation is skipped when the user prefers reduced motion.