Skip to content

Commit 9eb9cf5

Browse files
authored
fix(web): reduce page jitter on browsers that support overlay scrollbar (#21850)
Reduce jitter caused by the presence or absence of scrollbars in page switching --- Ref [scrollbar-gutter | MDN](https://developer.mozilla.org/en-US/docs/Web/CSS/scrollbar-gutter) https://user-images.githubusercontent.com/45708948/165972251-7d5a5017-f76d-4ba2-9106-a224b3ee521f.mp4
1 parent d084ce3 commit 9eb9cf5

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

web_src/less/_base.less

+7
Original file line numberDiff line numberDiff line change
@@ -222,6 +222,13 @@ body {
222222
overflow-wrap: break-word;
223223
}
224224

225+
@supports (overflow: overlay) {
226+
body {
227+
overflow: overlay;
228+
scrollbar-gutter: stable;
229+
}
230+
}
231+
225232
img {
226233
border-radius: 3px;
227234
}

0 commit comments

Comments
 (0)