Browse Source

增加缺省图

黄琪勇 11 months ago
parent
commit
4a1dac9f8b

BIN
src/page-instrument/component/the-music-list/imgs/empty.png


+ 11 - 5
src/page-instrument/component/the-music-list/index.module.less

@@ -216,11 +216,17 @@
         }
         }
     }
     }
 }
 }
-.noData {
+.empty{
+    margin-top: 10px;
     display: flex;
     display: flex;
-    justify-content: center;
+    flex-direction: column;
     align-items: center;
     align-items: center;
-    height: 100%;
-    font-size: 14px;
-    color: #999999;
+    >img{
+        width: 182px;
+    }
+    >span{
+        font-size: 14px;
+        color: rgba(0,0,0,0.46);
+        margin-top: 10px;
+    }
 }
 }

+ 6 - 1
src/page-instrument/component/the-music-list/list.tsx

@@ -7,6 +7,7 @@ import { postMessage } from "/src/utils/native-message";
 import qs from "query-string";
 import qs from "query-string";
 import searImg from "./imgs/searImg.png"
 import searImg from "./imgs/searImg.png"
 import huoimg from "./imgs/huo.png"
 import huoimg from "./imgs/huo.png"
+import emptyImg from "./imgs/empty.png"
 
 
 export default defineComponent({
 export default defineComponent({
   name: "TheMusicList-list",
   name: "TheMusicList-list",
@@ -122,7 +123,11 @@ export default defineComponent({
               </div>
               </div>
             );
             );
           })}
           })}
-          {!data.loading && data.list.length === 0 && <div class={styles.noData}>暂无数据</div>}
+          {!data.loading && data.list.length === 0 
+            &&  <div class={styles.empty}>
+                  <img src={emptyImg}/>
+                  <span>暂无内容</span>
+                </div>}
         </List>
         </List>
       </div>
       </div>
     );
     );