AncientBeast icon indicating copy to clipboard operation
AncientBeast copied to clipboard

unit selection using Tab key [bounty: 16 XTR]

Open emna9 opened this issue 8 months ago β€’ 3 comments

When selecting units , navigation can only be done using the arrow keys (← ↑ ↓ β†’). The Tab key does not cycle through available units, which is expected behavior for accessibility and smoother keyboard navigation.

Steps to reproduce the behavior:

Launch the game

Go to unit selection screen

Press Tab or Shift + Tab

Nothing happens

Expected behavior Tab should move the focus to the next unit in the list Shift + Tab should move the focus backward

Desktop:

  • OS: Windows 11, Arch Linux
  • Browser: Firefox
  • Version: 135.0.1 (64-bit)

emna9 avatar Apr 24 '25 00:04 emna9

The current functionality is good enough in my opinion and might not require modification, as it aligns with both usability and accessibility best practices. Navigation between units using the arrow keys (← ↑ ↓ β†’) could be an intentional design choice. This prevents users from having to tab through a potentially large number of individual unit elements, which would be inefficient and cumbersome.

This behavior is similar to how radio button groups work in accessible UI design: users use arrow keys to move between options while the entire group is treated as a single tabbable element. This minimizes the number of Tab stops and makes keyboard navigation smoother and more predictable. https://www.w3.org/WAI/ARIA/apg/patterns/radio/

Do I get the bounty πŸ˜…? @DreadKnight

Hi @Venkata-Sai-Vishwanath-robo , Thanks for your thoughts! While arrow keys are useful, adding Tab navigation would enhance accessibility and improve the overall user experience. Tab is a standard in many user interfaces, not just in gaming, as it allows for quicker, more efficient navigation through different elements. In games, it’s commonly used to cycle through units or menus, allowing players to move faster between selectable items, which is crucial when managing multiple elements. Beyond gaming, in software applications like email clients or web forms, Tab helps users quickly switch between fields or sections without having to manually scroll or use the mouse. This addition would complement the arrow keys, not replace them, offering a more inclusive and streamlined experience for all players.

emna9 avatar May 10 '25 21:05 emna9

Hey @emna9 ! It would be great to have Tab and Shift + Tab cycle through units during selection. It’s a common behavior in most interfaces and would make keyboard navigation much smoother especially for accessibility. A small change that could really improve the UX.

yousefsassy avatar May 13 '25 23:05 yousefsassy

@yousefsassy Hi can I work on this?

Matt-Foo-SL avatar Jun 25 '25 09:06 Matt-Foo-SL

@MattFooshilong yeah sure !

yousefsassy avatar Jun 25 '25 09:06 yousefsassy

@MattFooshilong Heya! I've assigned you to it. 2 weeks soft deadline 🐻

DreadKnight avatar Jun 25 '25 10:06 DreadKnight

@MattFooshilong Note that ideally, focused units should be materializable ones if active unit is Dark Priest, similarly to how the mouse scroll wheel works. Could have this as a separate issue after if too much for you all at once. Don't forget to 🌟

DreadKnight avatar Jun 25 '25 10:06 DreadKnight