Themes

Fields/Components/es-list-creator
es-list-creator

A list creator input.

Props

Name
Description
Type
Default
addIcon

The icon to display next to the field

[namespace: string
or
symbol, name: string]
or
string
[ICON_NAMESPACE, plus]
deleteIcon

Icon for the delete button.

[namespace: string
or
symbol, name: string]
or
string
[ICON_NAMESPACE, trash]
disabled

If the field is disabled.

boolean
or
undefined
icon

The icon to display next to the field

[namespace: string
or
symbol, name: string]
or
string
or
undefined
label

The label of the field.

string
messages

The validation messages of the field

ValidationMessages
or
undefined
name

The name of the field.

string
options

A list of options to choose from.

TypeaheadOption[]
placeholder

The placeholder for the input.

string
renderItem

Render the list item.

(h: typeof h, option: TypeaheadOption) => string
or
VNode
or
VNode[]
or
null
(
        h,
        { name },
    ) => <input readonly class={input} value={name} tabindex={-1} />
value

The selected item ids

string[]

ValidationMessages

Name
Description
Type
children
Record<number, Record<Severity, ValidationMessage[]>>
error
ValidationMessage[]
info
ValidationMessage[]
warning
ValidationMessage[]

TypeaheadOption

An option to be selected.

Name
Description
Type
name

The display name of the option.

string
value

The string to be used as a value.

string

Events

Event
Detail
Description
fieldchange
FieldChange<string[]>

Emitted when the value of the field is changed.

CSS Variables

Name
Description
--field-grid-columns

The field layout.

Parts

Name
Description
value-list

Target the ul containing the list items.

value-list-item

Target the li containing the option,