-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
[a11y] Popover accessibility docs #1408
Conversation
@sadiesaurus Let me know if you have a chance to look at this! Popover came up today on a question from the inventory team, so I'd love to get this in our next release. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great! Just had a couple take 'em or leave 'em suggestions/questions 😀
|
||
### Keyboard support | ||
|
||
- When a popover opens, focus moves to the popover container |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we mention the preventAutoFocus
prop at all? I'm thinking there's opportunity here to make it clear when it's okay to use, like when autoFocus would prevent merchants from completing the action that triggers the popover. For example, when a text field listening for certain characters is the activator and autofocusing focusable items inside the activated popover would remove focus from the text field while typing; additional focus management needs to be implemented in this case.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This came up in discussion about popovers today too, actually. Based on that and other questions about keyboard accessibility, I think I want to chunk out a separate page (probably under patterns and guides?) about keyboard interactions in general. Would love your thoughts on doing it that way, @chloe!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think that's a great idea, as it comes up in a lot of our components 👍
Co-Authored-By: dpersing <devon.persing@shopify.com>
WHY are these changes introduced?
Adds accessibility guidance for the popover component, to appear in
polaris-react
docs and in the style guide.See the draft Google doc for editing history for these changes and updates for other components and pages.
WHAT is this pull request doing?
UNRELEASED.md
How to 🎩
master
frompolaris-styleguide
polaris-react
and run the instructions for testing in a consuming project.polaris-styleguide
tab, rundev up && dev start
.Screenshots
Web
Android
iOS