Skip to content

Commit f706df4

Browse files
committed
Both use ceil value in client and scroll size
1 parent 67a796b commit f706df4

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/index.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@ const VirtualList = Vue.component('virtual-list', {
113113
return document.documentElement[key] || document.body[key]
114114
} else {
115115
const { root } = this.$refs
116-
return root ? root[key] : 0
116+
return root ? Math.ceil(root[key]) : 0
117117
}
118118
},
119119

@@ -124,7 +124,7 @@ const VirtualList = Vue.component('virtual-list', {
124124
return document.documentElement[key] || document.body[key]
125125
} else {
126126
const { root } = this.$refs
127-
return root ? root[key] : 0
127+
return root ? Math.ceil(root[key]) : 0
128128
}
129129
},
130130

0 commit comments

Comments
 (0)