-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
[docs] Small changes to standardize acessibility section for Data Grid and Tree View #13224
Changes from 8 commits
62eb110
b835802
6bdd326
3d0b3e8
201fe19
bc4f075
05c8546
2999b22
1b65e37
a1c320f
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
--- | ||
productId: x-date-pickers | ||
title: Date and Time Pickers - Date format and localization | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Did you intend to add this page on this PR? 🤔 There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Looks like I did something wrong 🙈 |
||
githubLabel: 'component: pickers' | ||
packageName: '@mui/x-date-pickers' | ||
--- | ||
|
||
# Date and Time Pickers - Accessibility | ||
|
||
<p class="description">The Date and Time Pickers have complete accessibility support, including built-in keyboard navigation that follows international standards.</p> | ||
|
||
## Guidelines | ||
|
||
The most commonly encountered conformance guidelines for accessibility are: | ||
|
||
- Globally accepted standard: [WCAG](https://www.w3.org/WAI/standards-guidelines/wcag/) | ||
- US: | ||
- [ADA](https://www.ada.gov/) - US Department of Justice | ||
- [Section 508](https://www.section508.gov/) - US federal agencies | ||
- Europe: [EAA](https://ec.europa.eu/social/main.jsp?catId=1202) (European Accessibility Act) | ||
|
||
WCAG 2.1 has three levels of conformance: A, AA, and AAA. | ||
Level AA meets the most commonly encountered conformance guidelines. | ||
This is the most common target for organizations so what we aims to support very well. | ||
|
||
<!-- Those examples do not cover the clock component --> | ||
The WAI-ARIA Authoring Practices includes examples on [Date Picker Dialog](https://www.w3.org/WAI/ARIA/apg/patterns/dialog-modal/examples/datepicker-dialog/) and [Date Picker Spin Button](https://www.w3.org/WAI/ARIA/apg/patterns/spinbutton/examples/datepicker-spinbuttons/) that provide valuable information on how to optimize the accessibility of the Date and Time Pickers. | ||
|
||
## Keyboard support | ||
|
||
The Date and Time Pickers consist on different associations of Field, Calendar, Time and Digital Clock components, each of which listens for keyboard interactions from the user and emits events in response to the pressed keys. | ||
|
||
:::info | ||
The following key assignments apply to Windows and Linux users. | ||
|
||
On macOS: | ||
|
||
- replace <kbd class="key">Ctrl</kbd> with <kbd class="key">⌘ Command</kbd> | ||
- replace <kbd class="key">Alt</kbd> with <kbd class="key">⌥ Option</kbd> | ||
|
||
::: | ||
|
||
### Field components | ||
|
||
| Keys | Description | | ||
| -----------------------------------------------------------------: | :---------------------------------------------------------- | | ||
| <kbd class="key">Arrow Left</kbd> | Moves focus among date/time sections | | ||
| <kbd class="key">Arrow Right</kbd> | Moves focus among date/time sections | | ||
| <kbd class="key">Arrow Up</kbd> | Increases focused section value by 1 | | ||
| <kbd class="key">Arrow Down</kbd> | Decreases focused section value section by 1 | | ||
| <kbd class="key">Page Up</kbd> | Increases focused section value section by 5 | | ||
| <kbd class="key">Page Down</kbd> | Decreases focused section value section by 5 | | ||
| <kbd class="key">Home</kbd> | Sets focused section to the first value | | ||
| <kbd class="key">End</kbd> | Sets focused section to the last value | | ||
|
||
### Calendar component | ||
|
||
| Keys | Description | | ||
| -----------------------------------------------------------------: | :---------------------------------------------------------- | | ||
| <kbd class="key">Arrow Left</kbd> | Moves focus among date/time sections | | ||
| <kbd class="key">Arrow Right</kbd> | Moves focus among date/time sections | | ||
| <kbd class="key">Arrow Up</kbd> | Increases focused section value by 1 | | ||
| <kbd class="key">Arrow Down</kbd> | Decreases focused section value section by 1 | | ||
| <kbd class="key">Page Up</kbd> | Increases focused section value section by 5 | | ||
| <kbd class="key">Page Down</kbd> | Decreases focused section value section by 5 | | ||
| <kbd class="key">Home</kbd> | Sets focused section to the first value | | ||
| <kbd class="key">End</kbd> | Sets focused section to the last value | | ||
|
||
## API | ||
|
||
- [DateTime](/x/api/date-pickers/) |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -31,8 +31,8 @@ The [WAI-ARIA Authoring Practices](https://www.w3.org/WAI/ARIA/apg/patterns/tree | |
:::info | ||
The following key assignments apply to Windows and Linux users. | ||
|
||
On macOS replace <kbd class="key">Ctrl</kbd> with <kbd class="key">⌘ Command</kbd>. | ||
|
||
On macOS replace: | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'm not sure how correct we are here. 🤔 There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Makes total sense for me, I confess I had the idea to add it based on my personal experience with the macbook and didn't consider other MacOS devices.
Anyways, we can split the PR: I will remove those mentions on this PR and let only the small corrections that don't rely on it, while we continue the discussion :) There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It makes sense, we can definitely put those additions as improvements that would have less emphasis than actually different buttons. 👍 |
||
- <kbd class="key">Ctrl</kbd> with <kbd class="key">⌘ Command</kbd>. | ||
::: | ||
|
||
| Keys | Description | | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
import * as React from 'react'; | ||
import MarkdownDocs from 'docs/src/modules/components/MarkdownDocs'; | ||
import * as pageProps from 'docsx/data/date-pickers/accessibility/accessibility.md?muiMarkdown'; | ||
|
||
export default function Page() { | ||
return <MarkdownDocs {...pageProps} />; | ||
} |
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.
The famous "Arrow Bottom" 😆