Accordion

Accordions are used to group similar content and hide or show it depending on user needs or preferences. Accordions give users more granular control over the interface and help digest content in stages, rather than all at once.

Specifications

Accordion design specifications
Accordion design specifications

States

The accordion header can get four different states based on user interaction. States: enabled, hover, focus and disabled.

Accordion states
Accordion states

Formatting

Anatomy

Accordion anatomy
  1. 1.
    Header
  2. 2.
    Custom icon (Optional)
  3. 3.
    Title
  4. 4.
    Helper text(Optional)
  5. 5.
    Caret icon (Expand/collapse)
  6. 6.
    Expanded panel

Design tokens

Color

Component tokenElementCore tokenValue
titleLabelFontColorTitlecolor-black#000000
disabledTitleLabelFontColorTitle:disabledcolor-grey-500#999999
arrowColorCaret iconcolor-purple-700#5f249f
disabledArrowColorTitle:disabledcolor-grey-500#999999
iconColorCustom iconcolor-purple-700#5f249f
disabledIconColorCustom icon:disabledcolor-grey-500#999999
assistiveTextFontColorHelper textcolor-grey-700#666666
disabledAssistiveTextFontColorHelper text:disabledcolor-grey-500#999999
hoverBackgroundColorHeader background:hovercolor-purple-100#f2eafa
focusBorderColorHeader outline:focuscolor-blue-600#0095ff
backgroundColorContainer backgroundcolor-white#ffffff
boxShadowColorContainer shadow-#0000001a
accordionGroupSeparatorBorderColorSeparator-#0000001a

Typography

Component tokenElementCore tokenValue
titleLabelFontFamilyTitlefont-family-sans'Open Sans', sans-serif;
titleLabelFontSizeTitlefont-scale-0316px
titleLabelFontWeightTitlefont-regular400
titleLabelFontStyleTitlefont-normalnormal
assistiveTextFontFamilyHelper textfont-sans'Open Sans', sans-serif;
assistiveTextFontSizeHelper textfont-scale-0316px
assistiveTextFontWeightHelper textfont-light300
assistiveTextFontStyleHelper textfont-regularitalic
assistiveTextLetterSpacingHelper textfont-tracking-wide-010.025em

Iconography

Component tokenElementCore tokenValue
iconSizeCustom icon/Caret icon-24x24px

Border

Component tokenElementCore tokenValue
focusBorderStyleHeader:focus borderborder-style-solidsolid
focusBorderThicknessHeader:focus borderborder-width-22px
borderRadiusAccordion containerborder-radius-medium0.25rem / 4px

Size

PropertyElementCore tokenValue
heightHeader-48px
min-widthAccordion container-280px

Spacing

Component tokenElementCore tokenValue
titleLabelPaddingRightTitlespacing-161rem / 16px
titleLabelPaddingLeftTitlespacing-0 0rem / 0px
titleLabelPaddingTopTitlespacing-0 0rem / 0px
titleLabelPaddingBottomTitlespacing-0 0rem / 0px
PropertyElementCore tokenValue
padding-leftHeaderspacing-1616px
padding-rightHeaderspacing-1616px
padding-rightHelper textspacing-2424px
paddingCaret iconspacing-1212px
margin-rightCustom iconspacing-1212px

Margin

Margin properties can be applied independently to top, right, bottom and left sides of the card container.

MarginValue
xxsmall6px
xsmall16px
small24px
medium36px
large48px
xlarge64px
xxlarge100px

Accessibility

WCAG 2.2

WAI-ARIA 1.2

Usability known issues

Printing

Accordions are often not well suited for printing documents and require people to print snippets of content at a time.