Skip to content

Menubar: Clicking parent of nested item closes the whole menu #8169

Description

@manuelpoelzl

Describe the bug

If there is a menu bar and one of its items has a sub-item, the entire menu closes when you click on the parent element—this only happens in the mobile view when the hamburger menu is displayed.

Reproducer

https://stackblitz.com/edit/vitejs-vite-kzp8ndex?file=src%2FApp.tsx

System Information

System:
    OS: Windows 11 10.0.26100
    CPU: (16) x64 AMD Ryzen 7 PRO 8840HS w/ Radeon 780M Graphics 
    Memory: 43.30 GB / 61.78 GB
  Binaries:
    Node: 22.12.0 - D:\Node\node.EXE
    npm: 10.9.0 - D:\Node\npm.CMD
  Browsers:
    Edge: Chromium (131.0.2903.112)

Steps to reproduce the behavior

  1. Shrink the screen so the hamburger menu appears in the menubar
  2. Click on the test2 item - the whole menu will get closed
  3. Open the menu again via the hamburger menu, you'll see that the menu is expanded now

Expected behavior

The menu should correctly expand and show the sub menu

Metadata

Metadata

Assignees

No one assigned

    Labels

    Resolution: DuplicateIssue has already been reported or a pull request related to same issue has already been submitted

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions