fix(select): mergedValue shouldn't modified by outValue (#4670)

2.x
叡山电车 2021-09-19 09:14:54 +08:00 committed by GitHub
parent 2e5e146f0c
commit 2e22b221c9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 1 deletions

View File

@ -629,7 +629,10 @@ export default function generateSelector<
props.onChange(outValue, isMultiple.value ? outOptions : outOptions[0]);
}
mergedValue.value = outValue;
if (props.value === undefined) {
mergedValue.value = outValue;
}
};
const onInternalSelect = (