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

How can I make Events accessible to keyboard only users #1753

Closed
SeandenDrijver98 opened this issue Sep 15, 2020 · 0 comments
Closed

How can I make Events accessible to keyboard only users #1753

SeandenDrijver98 opened this issue Sep 15, 2020 · 0 comments

Comments

@SeandenDrijver98
Copy link
Contributor

Hi there,

Do you want to request a feature or report a bug?

I would like to request a feature as I'm currently making my implementation of this component more accessible to keyboard only users and need to implement a function when the user presses the Enter key on an event, similar to the onSelectEvent.

What's the current behavior?

Currently Im unsure on how to implement this as the OnSelectEvent only fires for Click events.
I have tried using a custom component however the wrapper of the custom component with class rbc-event will first receive focus leading the user to believe they can select the event however the event is not selected when the user presses the Enter key.

What's the expected behavior?

I have Forked this Repo and implemented an onKeyPressEvent prop which can be passed to the Calendar.
The implementation works exactly the same as how the onDoubleClickEvent was implemented and this prop will provide functionality to pass a function which should fire when the focus is on an event and the user presses any key.

Im fairly new to working with this library so if there is another method to achieve this I will gladly give that a try.

I will create a PR with my code and attach it to this issue for review otherwise.

See screenshot of how this prop would be passed to the basic example.
Screenshot 2020-09-15 at 10 57 49

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

No branches or pull requests

1 participant