Closed BethedenMinistries closed 7 months ago
Yep, we can totally port over those over as we get more functionality. I think of the functionality that's already built we're just missing the navigation shortcuts. I'll try to remember to add the other shortcuts as we build those features.
@arrocke Are there any libraries/tools in React that you'd recommend using to implement the shortcuts?
I think we just need to attach a keydown event to the window while the translation view is loaded, and then use the key
field on the event to decide what to do.
Our input fields are causing issues. They seem to swallow up all the ArrowUp
, ArrowDown
, home
, and end
keydown events. I'll try to figure out if there's a workaround.
It would be great if the combobox supported a way to add more keyboard shortcuts, or even just enable/disable their default keyboard shortcuts, but I don't see any options for that.
I found a workaround, https://github.com/tailwindlabs/headlessui/discussions/820#discussioncomment-5878478, by adding an onKeyDown
property to the inner input.
@BethedenMinistries Control + Arrow keys conflicts with OS shortcuts for macs. Addison has the navigation shortcuts working with Control, but we need to do some research into how to build shortcuts that are compatible in multiple OSes.
Going to keep this open until we have a solution for mac controls, and to make sure the other features we are in the process of adding get keyboard controls
Going to close this now that we have other issues open for the remaining shortcuts
BART has a good system of shortcut keys I'd like to keep. People are already used to them, so if we're going to get people to switch over, they'll need to have the shortcuts they're used to.