Skip to content

New component: ListboxControl #65801

Open
@jameskoster

Description

A listbox widget presents a list of options and allows a user to select one or more of them. A listbox that allows a single option to be chosen is a single-select listbox; one that allows multiple options to be selected is a multi-select listbox.
w3.org

Listboxes can be used as controls in their own right, and also power more complex components like Comboboxes and Autocomplete inputs.

Listbox Item

Listbox Item

This is the atomic element that makes up the majority of the Listbox component. It can appear as either a checkbox for multi-select listboxes or a radio for single-select listboxes. In the multi-select variant the checkbox is not a checkbox input, merely an element styled to look like one.

Listbox

Listbox

Listbox is comprised of several elements; notably:

  • A scrollable container
  • Listbox Items
  • Listbox Item groups
  • Listbox group headers

ListboxControl

ListboxControl

ListboxControl is the consumable component. It follows the same format as similar components by providing layout and optional elements like a label and help text. Here's a video demonstration of the assembled component:

listbox.mp4

Activity

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

Metadata

Assignees

No one assigned

    Labels

    Design SystemIssues related to the system of combining components according to best practices.Needs Design FeedbackNeeds general design feedback.[Package] Components/packages/components[Type] EnhancementA suggestion for improvement.

    Projects

    • Status

      No status
    • Status

      🏗️ In Progress

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions