microsoft / tabster

Web Application Keyboard Navigation Tools
https://tabster.io
MIT License
118 stars 36 forks source link

Mover: have symmetrical forwards/backwards tabbing behavior #309

Open smhigley opened 11 months ago

smhigley commented 11 months ago

Currently the behavior for mover is to have tab focus land on the first item when tabbing forwards, and the last item when shift+tabbing backwards (reproducible in the storybook: https://tabster.io/storybook/?path=/story/mover--circular, applicable to all stories apart from the Tabbable one).

One of the principles of good tab navigation is that it is symmetrical when moving both forwards and backwards, so we should ensure tabster doesn't break this by default. My guess would be that the first item in the group should be the default focus stop, unless overridden by an author.