Skip to content

Add "delimited" prop to EuiComboBox and support copy/paste #1357

@cjcenizal

Description

@cjcenizal

Per #1307 (comment):

I think the combo box could accept a prop with the character(s) that would trigger an entry creation. It is very common in those inputs to trigger with the , (comma).

The interface would look like this:

<EuiComboBox delimiter="," />

The supported behaviors would be:

  1. Entering a comma will behave as if the user has hit Enter, and a new option based on the user input will be created.
  2. Pasting any values into the combo box will be split on the delimiter, and valid values will be converted into options. Invalid values will be left as a string in the input.
  3. The user can click a "Copy" icon, which will copy a delimited string of the pill values to the clipboard. The user can highlight all and copy as a delimited string

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    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