Skip to content

Menu can't be modal #2874

@dannylin108

Description

@dannylin108

Description

Using Menu component can't make it modal, so when I open Menu, other screen elements still receive events.

Since closing Menu without choosing an menu item is done by clicking outside, current implementation provokes unintentional triggers of other elements and impairs UX. Also in other popular libraries (shadui, mui) Menu is modal.

So it'd be nice to have at least possibility to make it modal as it is in Popover element,

Link to Reproduction (or Detailed Explanation)

https://ark-ui.com/react/docs/components/menu

Steps to Reproduce

  1. Click button to open menu
  2. Click some link on the page
  3. Menu should close, without following the link
  4. Menu in fact closes, but link is followed

Ark UI Version

3.11

Framework

  • React
  • Solid
  • Vue

Browser

No response

Additional Information

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions