Skip to content

Commit 13632d5

Browse files
authored
Merge pull request #39 from lottielab/main
Update pxRatio after calculating scrollbar width
2 parents 2424703 + 0339f31 commit 13632d5

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/utils/getScrollbarWidth.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ export default function getScrollbarWidth() {
1111

1212
if (pxRatio !== newPxRatio) {
1313
scrollbarWidth = getScrollbarWidthFromDom();
14+
pxRatio = newPxRatio;
1415
}
1516

1617
if (typeof scrollbarWidth === 'number') return scrollbarWidth;

0 commit comments

Comments
 (0)