Skip to content

Commit bdede29

Browse files
authored
Fixed the auto-scrolling issue of the column-side element in the desktop version
1 parent d3e3eef commit bdede29

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

guides/assets/javascripts/guides.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -60,10 +60,10 @@
6060

6161
if ('matchMedia' in window) {
6262
var mediaQueryList = window.matchMedia(`(max-width: ${MOBILE_WIDTH_FROM_STYLE_CSS_BREAKPOINT}px)`);
63-
isMobile = mediaQueryList.matches ? 'auto' : 'smooth';
63+
isMobile = mediaQueryList.matches;
6464

6565
mediaQueryList.addEventListener('change', function (ev) {
66-
isMobile = ev.matches ? 'auto' : 'smooth';
66+
isMobile = ev.matches;
6767
});
6868
} else {
6969
window.addEventListener('resize', function onResize() {

0 commit comments

Comments
 (0)