fix: select can not scroll #4396

close #4396
pull/4479/head
tangjinzhou 2021-08-05 11:41:34 +08:00
parent f35bafb88a
commit 7665cbea01
1 changed files with 63 additions and 61 deletions

View File

@ -145,6 +145,7 @@ const List = defineComponent({
watch(
[inVirtual, useVirtual, () => state.scrollTop, mergedData, heights, () => props.height],
() => {
nextTick(() => {
if (!useVirtual.value) {
calRes.value = {
scrollHeight: undefined,
@ -211,8 +212,9 @@ const List = defineComponent({
end: endIndex,
offset: startOffset,
};
});
},
{ immediate: true },
{ immediate: true, flush: 'post' },
);
// =============================== In Range ===============================