Skip to main content
  1. Docs
  2. Components
  3. Navigation

Tabs

Views of the same thing, one at a time. One Tab stop; the arrow keys move between them.

Import
@qeetrix/react
Status
StableSince 0.0.2
Renders
<div role="tablist">Server-rendered
Tested
WCAG 2.2 AAaxe on every pull request

01

Keyboard

KeysWhat happens
TabTabTo the selected tab, then on to its panel.
←→The previous or next tab, selected as it's reached. Up and Down when vertical.
HomeHomeEndEndThe first or last tab.
EnterSpaceSelects the focused tab, when activateOnFocus is off.

02

Behaviour

Roles
tablist, tab with aria-selected, and tabpanel, each panel labelled by its tab.
Name
The list is named by its aria-label.
Right to left
The arrow keys follow the reading way.
Forced colours
The bar is drawn in Highlight, the line in CanvasText.

03

Tested

On every change, before it ships.

  • axe, WCAG 2.2 A and AA, in Chromium on every pull request
  • Firefox and WebKit every night
  • Keyboard: every key in the table, in a test
  • Forced colours, reduced motion and right to left
Next — TabsChangelog