eBay / ebayui-core

Collection of Marko widgets; considered to be the core building blocks for all eBay components, pages & apps
https://ebay.github.io/ebayui-core/
Other
224 stars 104 forks source link

ebay-menu, ebay-filter-menu: arrow keydown event doesn't always fire #2294

Open cynthiahhc opened 1 month ago

cynthiahhc commented 1 month ago

Bug Report

eBayUI Version: 14.3.0

Description

https://github.com/eBay/ebayui-core/pull/2268

The arrow keydown event does not always fire. The event doest not fire the up arrow keydown event when it is the first index and does not fire the down arrow keydown event when it is the last index. Also the index emitted is using the roving tab index instead of the actual index when the keydown event happens, which is intentional, but it is not very clear. Maybe we should provide both actual index and the roving index.

Our use case is to move to the second menu while the user presses down arrow at the last index of the first menu, or press the up arrow at the first index of the second menu to move to the first menu.

Workaround

No work around

Screenshots

N/A

agliga commented 1 month ago

Could you share your usecase for this? Ideally if its at the end we wouldn't fire an on-keydown event since its not doing anything. If you have multiple menus, shouldn't you navigate to them with tab? Or maybe add a divider between each menu?

cynthiahhc commented 1 week ago

We are trying to traverse from the last option (5G) in Frequently selected section to the first option (2G) in All option section.

Screenshot 2024-11-20 at 10 25 46