Quellcode durchsuchen

fix: 清除上一次跟练状态

TIANYONG vor 1 Jahr
Ursprung
Commit
cece393259
1 geänderte Dateien mit 5 neuen und 3 gelöschten Zeilen
  1. 5 3
      src/subpages/colexiu/popups/follow/index.tsx

+ 5 - 3
src/subpages/colexiu/popups/follow/index.tsx

@@ -81,9 +81,11 @@ const onClear = () => {
   detailState.times.forEach((item) => {
     const note: HTMLElement = document.querySelector(`div[data-vf=vf${item.id}]`)!
     if (note) {
-      note.classList.remove('follow-error')
-      note.classList.remove('follow-success')
-      // note.classList.add('follow-error')
+      note.classList.remove('follow-up', 'follow-down', 'follow-error', 'follow-success')
+    }
+    const _note: HTMLElement = document.getElementById(`vf-${item.id}`)!
+    if (_note) {
+      _note.classList.remove('follow-up', 'follow-down')
     }
   })
 }