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

Aria notify updates #943

Merged
merged 6 commits into from
Jan 24, 2025
Merged

Conversation

aluhrs13
Copy link
Contributor

Sweeping changes based on ARIA WG discussions:

  • Renamed priority values - none to normal and important to high.
  • Renamed notificationId to type (doesn't seem like there was consensus here, but that type was a step in the right direction).
  • Made sandbox property name more clear.
  • Moved interrupt to future considerations.
  • Moved type to future considerations.
  • Adjusted all examples and references to make sense based on everything above.
  • Added myself as an author.

I noticed a bit too late that this file had linebreaks at 120 characters. I inadvertently removed some of those and didn't try to keep consistent with that (it's markdown not C++ 😅), so sorry for any review pain that causes. It's probably worth looking at the individual commit diffs for review to remove the noise of the unrelated parts, specifically the "Move interrupt and type to future options." commit has the most major changes.

One lingering note I think we might need to fix - Moving interrupt to the future means we probably need to expand the ARIA live region fallback for that to handle the three cases - no ariaNotify, ariaNotify without interrupt, and ariaNotify with interrupt.

not able to silence or flush existing notifications, as that behavior is not supported in ARIA live regions. In the
case that the web browser does not yet support `ariaNotify`, it is the responsibility of the web author to detect and
fallback to ARIA live regions. The above conversion may serve as a guide on how to do so. One can detect whether or not
`ariaNotify` is supported by checking if the method exists on the document or element in question:

```
```js
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does this need to handle three cases now? No ariaNotify, ariaNotify without interrupt, and ariaNotify with interrupt.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah actually that is probably a good point. Although for browsers that don't support it, it wouldn't probably parse anyways.

I think if we do add interrupt later, we will need to add some way to do feature detection to the ariaNotify API itself. Which reminds me, Alex had pointed me to https://developer.mozilla.org/en-US/docs/Web/API/ClipboardItem/supports_static which is something we should potentially consider adding to our proposal for interrupt to provide authors a way to detect if a browser supports that property yet

Copy link

@alisonmaher alisonmaher left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Only a couple of minor comments, but otherwise, this looks really great. Thanks for helping with all of these updates!

Accessibility/AriaNotify/explainer.md Show resolved Hide resolved
Accessibility/AriaNotify/explainer.md Outdated Show resolved Hide resolved
pointless given no matter the list, it will always fall short.

Possible examples of predefined `notificationId` could be something like:
Possible examples of predefined `type` could be something like:

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wonder if we should include some of the possible type categories that the Github team helped put together in https://docs.google.com/document/d/1kNtM_tguuaYKPrhd8cAWfwxj8CJVnWONSZLQp99dtlU/edit?usp=sharing

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't have access, Just requested it, can add more in a future PR.

@aluhrs13 aluhrs13 merged commit ab5d340 into MicrosoftEdge:main Jan 24, 2025
1 check passed
@aluhrs13 aluhrs13 deleted the aria-notify-updates branch January 24, 2025 17:18
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.

2 participants