Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Accessibility: Toast notification don't get announced on screen reader #3382

Open
dsaw opened this issue Mar 9, 2025 · 2 comments
Open

Accessibility: Toast notification don't get announced on screen reader #3382

dsaw opened this issue Mar 9, 2025 · 2 comments
Labels

Comments

@dsaw
Copy link

dsaw commented Mar 9, 2025

p5.js version

No response

What is your operating system?

Windows

Web browser and version

Google Chrome 133.0.6943.143

Actual Behavior

The toast notification for some actions (like "sketch saved") doesn't get announced by the screen reader

Expected Behavior

Since a toast is a notification, it should be announced in a timely manner particularly since the toast will go away.
Sometimes a toast like "autosave enabled" does get announced.
I think there is an ARIA live region encapsulating the toast, but since the toast element would disappear from the DOM once visibility is switched off, the live region cannot be announced in due time.

Thoughts on approaching this and similar issues:
1).Set an announcement live region in the page, and update it whenever any status update sent in a toast happens.
2). Increase the duration of the toast might be helpful for giving enough time for the user to finish their action

Steps to reproduce

Steps:

  1. Open a sketch on editor.p5js.org
  2. Login with your credentials
  3. Open up a screen reader
  4. Edit and save a sketch
  5. The toast shows up "Sketch saved", however, it doesn't get announced by the screen reader.

Snippet:

// Paste your code here :)
@dsaw dsaw added the Bug label Mar 9, 2025
@Jatin24062005
Copy link
Contributor

Hey @dsaw, could you please provide a video or screenshot of the issue? I’m not very familiar with screen readers, and it would help me understand the problem better.

@Harshit-7373
Copy link
Contributor

Hi , @dsaw , I have found the issue and updated the toast duration. Now, the "Sketch saved" toast stays visible for a while. Could you provide any information regarding the announcement live region?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants