Trên trang này

Trang này chưa có bản tiếng Việt, nội dung bên dưới là bản tiếng Anh. Xem trang tiếng Anh

Toggle group

What Toggle group gives you and what your team does.

Conformance

Toggle group meets WCAG 2.2 level AA when used as described on these pages.

Keyboard

  • Tab moves into the group.
  • Arrow keys move between items; Space or Enter turns one on or off.

What Toggle group gives you

  • aria-pressed on each item.
  • Roving focus: the group is one Tab stop.

What your team does

  • Name the group with aria-label.
  • Name icon-only items (a tooltip set as the label).

WCAG criteria

Criterion Level How
4.1.2 Name, Role, Value A On state is exposed
1.4.11 Non-text Contrast AA The on item has a border as well as a fill