Kaynağa Gözat

Merge branch 'feature-patch' into ktyq-test-new

TIANYONG 3 hafta önce
ebeveyn
işleme
c42d6decb7
1 değiştirilmiş dosya ile 3 ekleme ve 2 silme
  1. 3 2
      src/state.ts

+ 3 - 2
src/state.ts

@@ -1140,17 +1140,18 @@ export const scrollViewNote = (resetTop?: boolean) => {
   }
   // offsetTop = noteCenterOffsetTop;
   offsetTop = cursorElement.offsetTop;
+  const animateType = browser().android ? "instant" : "smooth"
   if (offsetTop > (state.headTopHeight + 30)) {
     musicScrollTop = (offsetTop - state.headTopHeight - 30) * state.musicZoom
     musicAndSelection.scrollTo({
       top: (offsetTop - state.headTopHeight - 30) * state.musicZoom,
-      behavior: "smooth",
+      behavior: animateType,
     });
   } else {
     musicScrollTop = 0
     musicAndSelection.scrollTo({
       top: 0,
-      behavior: "smooth",
+      behavior: animateType,
     });
   }
 };