Skip to content
This repository has been archived by the owner on Apr 28, 2023. It is now read-only.

Commit

Permalink
add aria label to describe how to use carousel
Browse files Browse the repository at this point in the history
  • Loading branch information
stephenhmarsh committed Dec 27, 2021
1 parent 618c229 commit a78356d
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions src/components/carousel/carousel.js
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,8 @@ const carousel = (options = {}) => {
carousel.addEventListener("image-loaded", handler, false);
carousel.addEventListener("image-errored", handler, false);
carousel.classList.add(SETTINGS.initializedClassName);
carousel.setAttribute("role", "region");
carousel.setAttribute("aria-label", "Interactive slide carousel. Use left and right arrows to change slides.");
});
};

Expand Down

0 comments on commit a78356d

Please sign in to comment.