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

[Feature request] a11y | Datepicker items are not accessible from the keyboard #684

Open
mrOrlando opened this issue Jan 26, 2022 · 3 comments
Labels

Comments

@mrOrlando
Copy link

What problem does this feature solve?

Allows users to use the datapicker only using the keyboard.

It is not convenient for all Internet users to work only with a mouse. Some of them unfortunately have physical disabilities that make it inconvenient or impossible to work with the mouse.

Some users have vision problems and they are forced to use special tools - screen readers that tell them what is happening on the screen.

WAI-ARIA Example of an accessible datapicker Date Picker Dialog

You can find out more about the accessibility of interfaces here: A11ycasts with Rob Dodson

What does the proposed API look like?

Probably it should be implemented out of the box.

@daren-k
Copy link

daren-k commented Feb 9, 2022

@mengxiong10 is the feature already open? how can I collaborate?

@mengxiong10
Copy link
Owner

@daren-k PR Welcome

@mst101
Copy link

mst101 commented May 4, 2022

I've just implemented keyboard navigation on another open source Vue2 datepicker project: https://sumcumo.github.io/vue-datepicker - and it was quite a challenge!

The datepicker I worked on is a pure date picker (i.e. you can't also pick a time), but you can now interact with the component using spacebar, tab, enter, escape, backspace, delete as well as the arrow keys.

We tried to emulate the way Chrome implements <input type="date"> (see example) i.e. by 'focus-trapping' certain elements (which you can tab through) when the calendar is open.

You even get a nice slide transition when changing month/year/decade - and the functionality is backed up by a suite of e2e tests in Cypress / cucumber.

If anyone here is thinking of implementing a similar thing for this project, you might like to have a look (and do please feel free to make any suggestions for improvement at the sum.cumo repo!).

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

4 participants