Skip to content

jQuery menu does not de-select and collapse if exit right #2167

Open
@steve1346

Description

@steve1346

This bug is causing me problems, and can also clearly be seen on the demo at the bottom of https://api.jqueryui.com/menu/.

In a nutshell, a menu item with a submenu is not deselected, and the submenu remains open, if you exit over the submenu.

In the demo, if you hover Item 3 its submenu opens. If you then move the mouse right a submenu item is selected. Keep moving the mouse right beyond the submenu, and that submenu item is deselected. However the submenu remains open and the parent item remains selected.

This does not happen if you exit Item 3 up, down, or left, i.e. without highlighting a submenu item. It appears visually as if there is only one level of select being cleared.

In my own use, I have tried hiding on blur or mouse leave events but it is tricky as you also get these events when moving from the item to the sub-menu.

PS This is in Chrome 95.0.4638.54 on Ubuntu 16.04. Confirmed that it also occurs in Firefox on same platform.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions