Skip to content

update documentation for scroll button alt text in carousels#189

Merged
Samua11y merged 1 commit into
bbc:masterfrom
Nanbob:WCDS-597-carousel-alt-text
Jul 10, 2026
Merged

update documentation for scroll button alt text in carousels#189
Samua11y merged 1 commit into
bbc:masterfrom
Nanbob:WCDS-597-carousel-alt-text

Conversation

@Nanbob

@Nanbob Nanbob commented Jul 7, 2026

Copy link
Copy Markdown
Contributor

Ticket: https://bbc.atlassian.net/browse/WCDS-597

Changes

  • Added guidance around alt text labelling within the carousel documentation
  • This should align with the description/explanation in the ticket
  • Included a reference to alt text labelling

Impact
GEL documentation includes information on how best to approach alt text

Testing

Click here for the section on alt labelling ### Scroll button accessible labels

The previous and next buttons should provide alternative text[^3] that communicate what content will be brought into view when the button is activated. Rather than simply announcing "Previous" or "Next", the label should include the item or range of items that will become visible, along with the total number of items in the carousel.

Where multiple items will be visible after scrolling, the label should use the format "X to Y of Z", where X is the first visible item, Y is the last visible item, and Z is the total number of items in the carousel. For example:

  • Previous, 1 to 3 of 10
  • Next, 3 to 5 of 10

Where only a single item is visible at a time, the label should use the format "X of Z":

  • Previous, 1 of 10
  • Next, 3 of 10

These labels describe the destination state of the carousel; that is, the content that will be visible after the button has been activated, not the content that is currently visible. In the examples above, the carousel is assumed to be showing items 2–4 and scrolling one item at a time.

When the user is already at the beginning or end of the carousel, the respective disabled control may simply be labelled:

  • Previous
  • Next

The exact values will depend on the carousel's configuration, viewport size, and scrolling behaviour. Implementations that scroll multiple items at a time should follow the same pattern, calculating the appropriate destination range for each button.

Screenshot 2026-07-07 at 15 48 50

@Samua11y Samua11y self-requested a review July 8, 2026 08:29
@Nanbob Nanbob marked this pull request as ready for review July 8, 2026 09:56
@Samua11y Samua11y requested a review from andrew-nott July 9, 2026 08:41
@Samua11y Samua11y merged commit f14bec4 into bbc:master Jul 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants