`<ActionList.Item>` doesn't correctly handle keyboard events
Description
<ActionList.Item> does not properly handle keyboard selection events when a modifier key is used.
Currently <ActionList.Item> registers a handler for the onKeyPress event. keypress events are fired when a key -or- key combination produces a character value. This works fine in most cases, but on Windows for example, Alt+Enter does not produce a character value and an event is not emitted.
Additionally, keypress is now considered an obsolete event and is no longer recommended for use.
Separately, on Mac, the key combination Option+Space results in a non-break space character value, which is different than typical Space resulting in the conditional check for ' ' on line 231 to fail.
Steps to reproduce
- Create a new GitHub Project
- Ensure there is a table view on the project
- Click the view's option button and then choose sort by
Mac:
Use the keyboard to select a secondary sort by using Option+Space and notice selection does not get made.
Windows
Use the keyboard to select a secondary sort by using Alt+Enter and notice selection does not get made.
Version
v36.6.0
Browser
Chrome
Hi there @tmelliottjr! Thanks for taking the time to make the issue 🙏
When going through this during issue triage, we could totally confirm the issue and we added it to our backlog. There isn't an ETA on when this will be picked up so feel free to submit a fix for this or reach out if this is something you'd want to pair on.
Hope this makes sense, let me know if you have any questions!
@joshblack thanks for the follow up, I'm happy to open a PR for this. :)
Hi! This issue has been marked as stale because it has been open with no activity for 180 days. You can comment on the issue or remove the stale label to keep it open. If you do nothing, this issue will be closed in 7 days.