Skip to content

[EuiComboBox] Document the structure the options object #1981

@wylieconlon

Description

@wylieconlon

The only documentation of EuiComboBox options is derived from the public documentation site and from the Typescript definitions: https://elastic.github.io/eui/#/forms/combo-box

The typescript definitions indicate that each option is passed as HTML props to a button, which explains why the options are using HTML names like disabled instead of a name like isDisabled

{
  label: 'Titan',
  'data-test-subj': 'titanOption',
},
{
  label: 'Enceladus is disabled',
  disabled: true,
},
{
  label: 'Mimas',
},

Also, I see that groups are supported by structuring this as a nested array. It's unclear on how deep the grouping can go from the docs, but I assume it's up to one level.

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationIssues or PRs that only affect documentation - will not need changelog entriesgood first issue

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions