Skip to main content Red Hat Design System logo Contribute on Github

Accordion

Overview Style Guidelines Code Demos Accessibility

Keyboard interactions

Each panel is a focus stop where Enter or Space expands or collapses each panel.

Accordion keyboard interactions; pressing Tab will focus the top panel, pressing Tab again will move focus to the next panel underneath, and pressing Enter or Space will expand the panel
Key Result
Tab Moves focus to the next panel
Shift+Tab Moves focus to the previous panel
Enter/Space Expands or collapses a panel

Focus order

A logical focus order helps keyboard users operate our websites. Elements need to receive focus in an order that preserves meaning, therefore the focus order should make sense and not jump around randomly. Interactive elements within expanded sections are automatically added to the focus order.

Accordion showing the order how focus moves through the element when pressing Tab continuously

Touch targets

Each panel is selectable instead of only title text or the chevrons.

Accordion showing touch target size examples for large and small sizes

ARIA Authoring Practices Guide (APG)

Learn to use the accessibility semantics defined by the Accessible Rich Internet Application (ARIA) specification to create accessible web experiences.

View APG resources

Web Content Accessibility Guidelines

Understanding documents provide detailed explanations for Web Content Accessibility Guidelines (WCAG) guidelines and success criteria.

© 2021-2024 Red Hat, Inc. Deploys by Netlify