|
|
|
|
|
by abtinf
584 days ago
|
|
> we want to turn off the animation and move the focus to the first link in the menu instead of focussing on the menu's parent Why not just always turn off the animations? Why not just always move the focus to the link? What is the benefit of the animation to the user? What is the benefit of focusing on the menu’s parent to the user? One rule of thumb with accessibility is that accessible products are usually better for everyone. |
|
Animations enhance experience by drawing attention to state changes and providing intuitive feedback to user actions.
If you don't find them engaging or useful, that's fine - and you can set prefers-reduced-motion to true on your client - , but many people do.
> What is the benefit of focusing on the menu’s parent to the user?
The first item was not interacted with nor navigated to, therefore it shouldn't be focused under normal circumstances. It would be unexpected behavior.
Focusing the first item in keyboard interactions is an accessibility hack recommended by W3C:
https://www.w3.org/WAI/ARIA/apg/patterns/menubar/