skyblued 2 years ago
parent
commit
effc31179a

+ 4 - 0
src/student/leaderboard/index.module.less

@@ -48,6 +48,7 @@
     width: 32px;
     margin: 0 21px 0 2px;
     text-align: center;
+    font-weight: bold;
   }
   .center {
     display: flex;
@@ -103,6 +104,9 @@
   box-shadow: 0 -8px 12px #ebedf0;
   background-color: #fff;
   :global {
+    .van-cell__title{
+      font-weight: bold;
+    }
     .van-cell__value {
       flex: initial;
       margin-left: 8px;

+ 2 - 2
src/student/leaderboard/index.tsx

@@ -126,8 +126,8 @@ export default defineComponent({
               class={styles.tabs}
               animated
               swipeable
-              titleInactiveColor="#fff"
-              titleActiveColor="rgba(224,146,144,1)"
+              titleInactiveColor="rgba(153,152,155,1)"
+              titleActiveColor="#fff"
               onChange={index => getData()}
             >
               {state.musicList.map((item: IMusicItem) => {

+ 1 - 0
src/teacher/leaderboard/index.module.less

@@ -47,6 +47,7 @@
     width: 32px;
     margin: 0 21px 0 2px;
     text-align: center;
+    font-weight: bold;
   }
   .center {
     display: flex;

+ 2 - 20
src/teacher/leaderboard/index.tsx

@@ -82,24 +82,6 @@ export default defineComponent({
       await getMusicList()
       await getData()
     })
-    const user = computed(() => {
-      if (!state.musicList[state.tabIndex]) return {} as any
-      const userdata = userInfo.user.data
-      if (!userdata.userId) return {} as any
-      const rank = state.musicList[state.tabIndex]
-      const item = rank?.rankingList?.find(n => n.userId == userdata.userId)
-      let step = rank?.rankingList?.findIndex(n => n.userId == userdata.userId)
-      step = step > -1 ? step + 1 : 0
-      return {
-        join: rank.join,
-        score: rank.score,
-        isTop: item ? true : false,
-        heardUrl: userdata.heardUrl,
-        username: userdata.username,
-        userId: userdata.userId,
-        step
-      }
-    })
     const imgRef = ref()
     return () => (
       <div class={styles.leaderboard}>
@@ -126,8 +108,8 @@ export default defineComponent({
               class={styles.tabs}
               animated
               swipeable
-              titleInactiveColor="#fff"
-              titleActiveColor="rgba(224,146,144,1)"
+              titleInactiveColor="rgba(153,152,155,1)"
+              titleActiveColor="#fff"
               onChange={index => getData()}
             >
               {state.musicList.map((item: IMusicItem) => {