Skip to content
Theme:

Ui3nAutocomplete

Props

NameTypeDefault valueDescription
chipsboolean | undefinedWhether to show chips
clearOnSelectboolean | undefinedfalseWhether to clear input on select
customFilter((value: T, query: string) => boolean) | undefinedCustom filter function
disabledboolean | undefinedWhether autocomplete is disabled
filterKeysstring[] | undefined[]Filter keys
hideSelectedboolean | undefinedfalseWhether to hide selected items
items * T[][]Items to display
itemTitlekeyof T | undefined"name"Property to use as title
itemValuekeyof T | undefined"id"Property to use as value
modelValue * T[] | T[keyof T][]Current autocomplete value
addNewValueboolean | undefinedWhether to allow adding new values
newValueValidator((value: string) => boolean) | undefinedNew value validator function
multipleboolean | undefinedWhether to allow multiple selection
noDataTextstring | undefinedText to show when no data
placeholderstring | undefinedPlaceholder text
returnObjectboolean | undefinedWhether to return the whole object or just the value

Events

EventValue typeDescription
update:modelValueT[] | T[keyof T][]Emitted when model value updates
update:searchstringEmitted when search value updates
update:focusedbooleanEmitted when focused state updates
valid:new-valuebooleanEmitted when new value validation status updates

Slots

NamePropsDescription
item{ item: T; index: number; query?: string | undefined; }Item slot
chip{ item: T | T[keyof T]; index: number; }Chip slot
noDataTextNo data text slot
selection{ value: T[] | T[keyof T][]; }Selection slot