Updated logic of mobile/tablet sizes & scrollbars.
This commit is contained in:
1 parent
1b2cf2697f
commit
74f4b11ad6
1 file changed
+2
-1
@@ -130,7 +130,8 @@ export function DesignPreview({previewOption = {widthDimension: 0}}) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
const scrollbarOffset = 7;
|
||||
// const scrollbarOffset = 7; Looks like browser scrollbar is not included in the width calculation anymore.
|
||||
const scrollbarOffset = 0;
|
||||
return window.innerWidth / 2 - previewOption.widthDimension / 2 - scrollbarOffset;
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user