Open jpzwarte opened 1 year ago
I believe this to be the most important resources on an accessible Toast:
This quote regarding accessibility is worth noting:
Few (none that I have found so far) of the existing toast or toast-like notification patterns in the wild will pass a WCAG audit. Instead of reviewing each of the ~50 examples, I am going to break down some of the broader concepts and risks that you can bear in mind when writing your own toast-like notification or reviewing one to use in your project.
And 2.2.1: Timing adjustable is the reason itslearning we stopped suggesting to have a Toast component in our Component Library.
Thanks for these links @furstenberg Really interesting!
https://adamsilver.io/blog/the-problem-with-snackbars-and-toast-messages/
I have many more related to the other components that are going to be made, so let me know if they are of interest.
Itslearning have spent quite some time on accessible components.
@furstenberg Of course we're interested in your expertise! Feel free to keep commenting on issues and certainly join in the discussions: https://github.com/sanomalearning/design-system/discussions
We will keep doing our research before each component we make so if we have specific questions regarding an interaction we'll get in touch!
📝 put back on backlog until we've figured out how (if) we should make this in an accessible way
Research done:
If you find yourself saying, Hey, if my screen reader, zoom, or keyboard-only users miss some of these messages, it’s not a big deal then you have a larger question to ask — do you even need those messages?
Researching how to build an accessible snack bar/ toast component we found rather a lot of comments and articles about the problems of making it accessible. Some of the recommendations also seemed to contradict each other.
Biggest downsides
aria-role = alert
and aria-live = assertive
will help to notify people using a screen reader that there is a message, but making these messages both non interrupting and easy to dismiss (or reread) is a difficult balancing act.Possible alternatives to toast messages
Challenge This discussion is an attempt to find accessible solutions for all scenarios in which we would (without thinking about accessibility) use a toast message.
Articles and resources
Create a new snack bar web component.
This component is for displaying "notifications" inside the web application. Some examples:
Other implementations:
Requirements:
<sl-snack-bar-controller>
)aria-live
?)message: string
andautoClose: boolean
,type: 'info' | 'success' | 'error'