shibro
Show the version of “Accordion headers are 48px headings over padded panels”

Display and media · SU-308

Accordion headers are 48px headings over padded panels

Flip between the version shibroUI flags and the one it ships. The marks and callouts show what changes.

  • Header row 34px tall
  • Panel padding 6px
  • Header row 52px · inside an h3
  • Nesting accordion inside a panel
  • Panel padding 20px · one level

What changes

Bad
A 34px header row, 6px of padding around the open panel’s text, and a second accordion nested inside it.
Good
Each header is a button alone in an h3, a full-width 52px row, over a panel with 20px of padding and no nesting.

The rules

  • SU-308

    Accordion headers are 48px headings over padded panels. Each header is a button that is the only child of a heading, spans the full row (SU-217) and is at least 48px tall, over a panel with 16-24px of padding. One level only: never put an accordion inside a panel. A URL hash opens its panel, and content everyone needs is not hidden. Add role="region" to panels only when about 6 or fewer can be open at once.