mirror of
https://github.com/element-plus/element-plus.git
synced 2025-02-23 11:59:34 +08:00
fix(components): [el-select] first item hover status error (#3880)
Co-authored-by: “Alanscut” <“wp_scut@163.com”>
This commit is contained in:
parent
9c74c8595a
commit
07353a13e1
@ -480,10 +480,7 @@ export const useSelect = (props, states: States, ctx) => {
|
||||
const valueKey = props.valueKey
|
||||
if (!props.multiple) {
|
||||
states.hoverIndex = optionsArray.value.findIndex((item) => {
|
||||
return (
|
||||
getValueByPath(item, valueKey) ===
|
||||
getValueByPath(states.selected, valueKey)
|
||||
)
|
||||
return getValueKey(item) === getValueKey(states.selected)
|
||||
})
|
||||
} else {
|
||||
if (states.selected.length > 0) {
|
||||
|
Loading…
Reference in New Issue
Block a user