As part of T327499, we discussed two potential improvements of the highlight behavior of the MenuItem component:
- Do not highlight a menu item if the cursor is below the menu when it opens and happens to be on top of a MenuItem. Instead, wait until the user intentionally moves the cursor.
- Do not allow double highlighting: currently, you can highlight a MenuItem via the mouse, then use the arrow keys to highlight a second MenuItem. Instead, only a single MenuItem should be highlighted at a time, and it should be the one that the user last interacted with.
This task covers implementing these improvements.
Acceptance criteria
- MenuItem is no longer highlighted on menu expansion when the cursor happens to be on top of that MenuItem
- Only one MenuItem is ever highlighted at a time, and that item is the one the user last interacted with (either via the mouse or the keyboard)