Why a new select control exists
Styling form controls consistently shows up among the top-10 missing capabilities in the 2020 State of CSS survey. Greg Whitworth's follow-up research found that <select> was the control developers struggled with most. The button portion is easy enough to restyle, but the options in the open popup are effectively out of reach — and adding content to that popup is not possible at all.
The consequence is that design systems and component libraries keep building their own selects from custom markup, CSS and substantial JavaScript. Getting the accessibility semantics, keyboard handling and popup positioning right is hard, and many of the resulting selects are inaccessible.
Open UI, a group of developers, designers and browser implementers, aims to make built-in UI controls styleable and extensible — not just <select> but dropdowns, checkboxes, radio buttons and more — by producing specifications along with the accessibility requirements those controls must meet.
The <selectmenu> control
Based on Open UI's <select> proposal, implementation of a new <selectmenu> control has begun in Chromium, carried out by the Microsoft Edge team with the Google Chrome team. It behaves like a <select>: a button displays the selected label, and clicking it opens a popup listing the options.
The name began as a working title and stuck. More significantly, <select> has been on the web so long that changing it in any substantial way would carry major compatibility risk. The plan, still experimental, is for <selectmenu> to be a separate control.
To try it, open a Canary build of a Chromium-based browser (Chrome or Edge), enable the "Experimental Web Platform features" flag on the about:flags page, restart, and swap <select> for <selectmenu> in a page. Feedback on bugs or design limitations goes through the Open UI GitHub repository.
Anatomy of the control
Styling depends on knowing the internal parts:
<selectmenu>— root element containing the button and listbox.<button>— toggles visibility of the listbox.<selected-value>— displays the current option's value; optional, and need not live inside the button.<listbox>— wraps the<option>s and<optgroup>s.<optgroup>— groups options with an optional label.<option>— a selectable value; one or more.
Default markup and behavior
Default behavior mirrors <select>, so minimal markup is enough. The default <button>, <selected-value> and <listbox> are generated for you.
Styling individual parts
The ::part() pseudo-element targets specific pieces of the control's anatomy. It works on the <button>, <selected-value> and <listbox> parts.
Replacing and extending the markup
Beyond part-based styling, <selectmenu> exposes named slots you can use to replace default parts, reorder them, or add new content. The two attributes that make this work are slot, which names the part being replaced, and behavior, which tells the browser that the element should inherit the corresponding interaction behavior.
To replace the default button, wrap your own <button> in an element carrying slot="button" and put behavior="button" on the button itself. The browser applies click and keyboard handling to it along with the appropriate accessibility semantics. Both attributes can sit on the same element.
For the popup, the element with behavior="listbox" must be a <div popup> — an element also proposed by Open UI and in implementation in Chromium. The attribute makes the element open on button click, with options selectable by mouse, arrow keys and touch.
Adding markup is equally possible: you can augment the button or listbox with extra information or new functionality by supplying custom markup around the options.
Full shadow DOM replacement
For complete control, call attachShadow() to replace the default shadow DOM. The custom markup is then fully encapsulated, so the <selectmenu> can be dropped into any page without risk of style interference from surrounding content.
Status
Because the control is built into the browser, accessibility and viewport-aware positioning are handled for you. Open UI publishes further documentation and demos. All of this is work in progress and will change in response to feedback; testing the control, reporting issues and getting involved all help move it toward stable specifications and interest from other browser engines.



