Skip to content

[menu] Should menulist be a popover by default? #1226

Description

@dizhang168

We can define <menulist> elements to be popover by default. This would be more natural for developers, but I am not sure if it breaks any semantic. For example, there is no popover=none, so users wouldn't be able to opt out. Maybe we would need to add that as a valid value.

<menubar>
  <menuitem menulist=more>More commands</menuitem>
</menubar>
<menulist id="more">
 ...
</menulist>

<!-- OR -->

<menubar>
  <menuitem commandfor="more" command="toggle-menulist">More commands</menuitem>
</menubar>
<menulist id="more">
 ...
</menulist>

The second option would be to let the developer add the popover attribute and trigger the popover by using command/commandfor. This gives more flexibility to add more commands in the future and allow developers to turn it on/off by removing the attributes.

<menubar>
  <menuitem commandfor="more" command="toggle-popover">More commands</menuitem>
</menubar>
<menulist id="more" popover>
 ...
</menulist>

This is probably related to the openable issue (#1198). If we want to allow inline menulist, than going with command/commandfor would be better.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    menuMenu elements proposal

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions