File tree Expand file tree Collapse file tree 1 file changed +11
-2
lines changed
packages/vue-virtual-scroller/src/components Expand file tree Collapse file tree 1 file changed +11
-2
lines changed Original file line number Diff line number Diff line change @@ -54,8 +54,17 @@ export default {
54
54
}
55
55
for (const entry of entries) {
56
56
if (entry .target && entry .target .$_vs_onResize ) {
57
- const resizeObserverSize = entry .borderBoxSize [0 ]
58
- entry .target .$_vs_onResize (entry .target .$_vs_id , resizeObserverSize .inlineSize , resizeObserverSize .blockSize )
57
+ let width, height
58
+ if (entry .borderBoxSize ) {
59
+ const resizeObserverSize = entry .borderBoxSize [0 ]
60
+ width = resizeObserverSize .inlineSize
61
+ height = resizeObserverSize .blockSize
62
+ } else {
63
+ // @TODO remove when contentRect is deprecated
64
+ width = entry .contentRect .width
65
+ height = entry .contentRect .height
66
+ }
67
+ entry .target .$_vs_onResize (entry .target .$_vs_id , width, height)
59
68
}
60
69
}
61
70
})
You can’t perform that action at this time.
0 commit comments