Skip to content

Menu elements proposal #11729

Open
Open

Description

@domfarolino

What problem are you trying to solve?

Some of us over in Open UI have been designing the new menu elements proposal (explainer), which is a suite of new HTML elements designed to fulfill the menu and menubar roles / pattern. Please see the APG pattern for more details, which served as some initial motivation and inspiration for our proposal.

Our goal is to produce a set of menu primitives with sensible built-in keyboard navigability, accessibility, and activation defaults, as we've observed this pattern widely across the web, with each instance varying slightly in all forms of behavior, and many of which have very poor accessibility characteristics. Our proposal builds off of recent primitives such as popovers and anchor positioning, and all of the design details to date have been collected in the explainer: https://open-ui.org/components/menu.explainer/. Please take a look!

Our goal is eventual inclusion in HTML, so we'd love to propose stage 1, and discuss this at the WHATNOT meeting scheduled for 2025-10-09.

/cc @mfreed7 @josepharhar

What solutions exist today?

No response

How would you solve it?

No response

Anything else?

No response

Activity

  1. added
    addition/proposal
    needs implementer interest
    on Sep 30, 2025
  2. self-assigned this
    on Sep 30, 2025
  3. added
    agenda+
    stage: 0
    on Sep 30, 2025
  4. emilio commented on Oct 9, 2025

    @emilio
    Contributor
  5. removed
    agenda+
    on Oct 9, 2025
  6. saschanaz commented on Oct 9, 2025

    @saschanaz
    Member

    FWIW the Gecko-only past iteration on menu elements that is removed: https://bugzilla.mozilla.org/show_bug.cgi?id=1372276

  7. added
    stage: 1
    and removed
    stage: 0
    on Nov 5, 2025
  8. annevk commented on Mar 15, 2026

    @annevk
    Member

    Drive-by comment: I noticed that tests are using :popover-open for <menulist>. I think it would be bad for that pseudo-element to match in this case (same as with ::picker(select). The pseudo-class for HTML elements is :open. We shouldn't leak the implementation like that.

  9. mfreed7 commented on Mar 16, 2026

    @mfreed7
    Contributor

    Drive-by comment: I noticed that tests are using :popover-open for <menulist>. I think it would be bad for that pseudo-element to match in this case (same as with ::picker(select). The pseudo-class for HTML elements is :open. We shouldn't leak the implementation like that.

    I don't think it's "leaking" the implementation, if the specification explicitly says it's a popover, right? The plan is similar for the menulist element. If the elements are explicitly popovers, it seems odd/confusing for them to only behave partly like a popover, with some popover features magically disabled.

  10. annevk commented on Mar 16, 2026

    @annevk
    Member

    I don't think it's actually defined at the moment? It says "select popover" but other than it being a div element it's not explained what that means. I would certainly object to it being defined in a way that would make it match :popover-open. But that's w3c/csswg-drafts#10775.

  11. mfreed7 commented on Mar 16, 2026

    @mfreed7
    Contributor

    The other algorithms (e.g. pick an option) treat it as a popover, e.g. by running the show popover and hide popover algorithms on it. It sets up an implicit anchor relationship like popovers. Most importantly though, the behavior is observable - if you open the select picker, it participates in the normal popover stacking process, e.g. closing other popover=auto popovers on the page. Again, because it is a popover.

    I'm kind of unclear what the downside of acknowledging it as a popover would be? The upside, for developers, is that they know what it means, how it behaves, and how to use it.

  12. annevk commented on Mar 16, 2026

    @annevk
    Member

    I don’t think we should have multiple APIs for the same thing. An open picker is select:open. I also think that participating in numerous popover things should be a case-by-case decision based on what makes sense for the element involved. For instance, we do events separately as well and I don’t think we should allow a button to target a menulist as a popover. That’s just rather strange API for a built-in element.

  13. 39 remaining items

  14. linked a pull request that will close this issueIntroduce the new menu elements #12011on Aug 26, 2026
  15. added
    agenda+
    on Sep 9, 2026
  16. removed
    agenda+
    on Sep 17, 2026
  17. added
    agenda+
    on Sep 22, 2026
  18. removed
    needs implementer interest
    agenda+
    on Sep 24, 2026
  19. added
    agenda+
    on Oct 6, 2026
  20. added
    stage: 3
    and removed
    agenda+
    stage: 2
    on Oct 8, 2026
  21. jstenback commented on Oct 8, 2026

    @jstenback
    Contributor

    Moved to stage3 per the discussion in today's WHATNOT meeting.

  22. annevk commented on Nov 3, 2026

    @annevk
    Member

    Why is the PR's OP not up-to-date? It also doesn't seem like the PR defines the orientation attribute?

    I'm also rather surprised this contains a whole section on the controversial interest invokers feature (including re-introducing the "invoker" word which we've largely managed to get rid of in the specification).

  23. dbaron commented on Nov 3, 2026

    @dbaron
    Member

    Why is the PR's OP not up-to-date? It also doesn't seem like the PR defines the orientation attribute?

    Oops. I think I've updated it now, although it's possible that a little more detail might be desirable. (Sorry for missing this -- I was making an effort to keep the explainer, spec PR, and Chromium implementation in sync with each other, and managed to forget about keeping the PR's OP up-to-date too!)

    I've also clarified the OP that the point it was making about orientation is that it's not included in the current PR, though I added a little explanation as to why that's still the case, and that we now intend not to include it as part of the initial version of menus.

    I'm also rather surprised this contains a whole section on the controversial interest invokers feature (including re-introducing the "invoker" word which we've largely managed to get rid of in the specification).

    My understanding of the core controversy around interest invokers is that it centers on the risks of authors creating content that can only be opened or activated via interest and not by a broader set of mechanisms that (combined) meet accessibility requirements better. The menu elements proposed here use the mechanisms of the interest invokers proposal for opening submenus in response to hover (in a way that roughly matches the way menus work across major desktop operating systems), but they do so in a way that avoids this core controversy because submenus also open on click/tap or on keyboard activation. (In other words, my understanding of the core of the controversy is that it's specific to the risks of exposing the mechanism to authors and does not apply to using it internally in other specification features, as long as those specification features themselves follow the correct practices.)

    I think it's valuable to use the internals of the specification proposal for interest invokers for a few reasons:

    • if we do find a way forward to make progress on the developer-exposed interest invokers API surface, we probably want menus to interact well with it, and building on top of it should do that
    • even if we don't, it's possible (although this point is definitely less concrete than the other two) we might add other features to HTML that also want to build on it in the same way, and those should interact well with menus
    • the internals of the interest invokers spec proposal are based on quite a bit of prototyping and testing, and I think if we tried to write a new (simpler?) proposal for just the parts that we think menus need, we might end up finding and re-fixing many of the same bugs that have already been fixed as part of the prototyping cycles that have gone in to the interest invokers work, and we may well end up back at a similar level of complexity.

    That said, I'm totally open to changing the names. I wasn't aware that "invoker" was a word we wanted to avoid and I'm happy to rename things as needed.

  24. added
    agenda+
    on Nov 10, 2026
  25. removed
    agenda+
    on Nov 20, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

addition/proposalstage: 3

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions