Skip to content

Commit

Permalink
fix(Autocomplete): auto-select-first with disabled result (#18850)
Browse files Browse the repository at this point in the history
fixes #18839

Co-authored-by: John Leider <[email protected]>
  • Loading branch information
yuwu9145 and johnleider authored Dec 11, 2023
1 parent 27c3273 commit fc3af53
Showing 1 changed file with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -321,6 +321,8 @@ export const VAutocomplete = genericComponent<new <
const isSelecting = shallowRef(false)

function select (item: ListItem, add = true) {
if (item.props.disabled) return

if (props.multiple) {
const index = model.value.findIndex(selection => props.valueComparator(selection.value, item.value))

Expand Down

0 comments on commit fc3af53

Please sign in to comment.