Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.cognite.com/llms.txt

Use this file to discover all available pages before exploring further.

Collapsible

v1.0.0 | View in Storybook

When to use

  • A mutually exclusive optional or secondary block of content on a page (e.g. AI reasoning, advanced settings, an explanation, a preview).
  • When the content is useful but not essential to the primary task.

When to use something else

  • Multiple stacked expandable sections: use Accordion instead.
  • Navigation or filtering: use Tabs or filter controls (Combobox, Select, etc.).
  • Content the user almost always needs: show it by default—don’t hide it in a collapsible.

Dos and don’ts

  • Do default to collapsed unless the collapsible content is the main purpose of the view.
  • Do keep the trigger label descriptive — it should communicate what’s inside, not just say “more”.
  • Don’t nest Collapsibles — if you need layered disclosure, reconsider the information architecture.
  • Don’t use it to hide errors or required information.

Behavior

  • One trigger expands or collapses a single associated region; animation is optional but state (expanded/collapsed) must be exposed to assistive tech when it conveys meaning.
  • Do not nest collapsibles; use Accordion for multiple independent sections.

Often used with

  • Clear trigger (button or link styled per system); Separator when stacking multiple collapsible regions on one page.
Last modified on May 11, 2026