Carousel (Slide Show or Image Rotator) Pattern

About This Pattern

A carousel presents a set of items, referred to as slides, by sequentially displaying a subset of one or more slides. Typically, one slide is displayed at a time, and users can activate a next or previous slide control that hides the current slide and "rotates" the next or previous slide into view. In some implementations, rotation automatically starts when the page loads, and it may also automatically stop once all the slides have been displayed. While a slide may contain any type of content, image carousels where each slide contains nothing more than a single image are common.

Ensuring all users can easily control and are not adversely affected by slide rotation is an essential aspect of making carousels accessible. For instance, the screen reader experience can be confusing and disorienting if slides that are not visible on screen are incorrectly hidden, e.g., displayed off-screen. Similarly, if slides rotate automatically and a screen reader user is not aware of the rotation, the user may read an element on slide one, execute the screen reader command for next element, and, instead of hearing the next element on slide one, hear an element from slide 2 without any knowledge that the element just announced is from an entirely new context.

Features needed to provide sufficient rotation control include:

Examples

Terms

The following terms are used to describe components of a carousel.

Slide
A single content container within a set of content containers that hold the content to be presented by the carousel.
Rotation Control
An interactive element that stops and starts automatic slide rotation.
Next Slide Control
An interactive element, often styled as an arrow, that displays the next slide in the rotation sequence.
Previous Slide Control
An interactive element, often styled as an arrow, that displays the previous slide in the rotation sequence.
Slide Picker Controls
A group of elements, often styled as small dots, that enable the user to pick a specific slide in the rotation sequence to display.

Keyboard Interaction

WAI-ARIA Roles, States, and Properties

This section describes the element composition for three styles of carousels:

Basic carousel elements

Tabbed Carousel Elements

The structure of a tabbed carousel is the same as a basic carousel except that:

Grouped Carousel Elements

A grouped carousel has the same structure as a basic carousel, but it also includes slide picker controls where: