mirror of
https://github.com/Jerryplusy/rc-plugin.git
synced 2025-10-14 08:09:19 +00:00
✨ feat: 添加云盘默认图片
This commit is contained in:
parent
f48da3b91f
commit
6b28f27ec4
@ -150,8 +150,12 @@ export class songRequest extends plugin {
|
||||
}).then(res => {
|
||||
let imgList = {}
|
||||
for (let i = 0; i < res.data.songs.length; i++) {
|
||||
if (res.data.songs[i].al.includes('109951169484091680.jpg')) {
|
||||
imgList[res.data.songs[i].id] = 'def'
|
||||
} else {
|
||||
imgList[res.data.songs[i].id] = res.data.songs[i].al.picUrl;
|
||||
}
|
||||
}
|
||||
for (let i = 0; i < musicDate.data.length; i++) {
|
||||
const songId = musicDate.data[i].id;
|
||||
if (imgList[songId]) {
|
||||
|
@ -69,6 +69,7 @@ html {
|
||||
width: 135px;
|
||||
height: 135px;
|
||||
border-radius: 10px;
|
||||
object-fit: cover;
|
||||
box-shadow: 2px 2px 5px rgba(0, 0, 0, 0.3);
|
||||
}
|
||||
|
||||
|
@ -12,14 +12,22 @@
|
||||
|
||||
<body>
|
||||
<div class="bg-image">
|
||||
{{ if songInfo.cover == 'def' }}
|
||||
<img src="{{ songInfo.cover }}" alt="" class="img" width="100%">
|
||||
{{ else }}
|
||||
<img src="{{pluResPath}}img/default.png" alt="" class="img" width="100%">
|
||||
{{ /if }}
|
||||
<div class="inner"></div>
|
||||
</div>
|
||||
<div class="infoBox">
|
||||
<div class="info">
|
||||
<div class="songinfobox">
|
||||
<div class="cover">
|
||||
{{ if songInfo.cover == 'def' }}
|
||||
<img src="{{ songInfo.cover }}" alt="">
|
||||
{{ else }}
|
||||
<img src="{{pluResPath}}img/default.png" alt="">
|
||||
{{ /if }}
|
||||
</div>
|
||||
<div class="songSize">
|
||||
{{ songInfo.size }}
|
||||
|
@ -95,6 +95,7 @@ html {
|
||||
height: 90px;
|
||||
border-radius: 8px;
|
||||
flex-shrink: 0;
|
||||
object-fit: cover;
|
||||
}
|
||||
|
||||
.bgicon {
|
||||
|
@ -16,7 +16,11 @@
|
||||
<div class="songListNav">
|
||||
<div class="navInfo">
|
||||
<div class="number">{{ key+1 }}</div>
|
||||
{{ if info.cover == 'def' }}
|
||||
<img src="{{ info.cover }}" alt="">
|
||||
{{ else }}
|
||||
<img src="{{pluResPath}}imgdefault.png" alt="">
|
||||
{{ /if }}
|
||||
<div class="navText">
|
||||
<div class="songName">{{ info.songName }}</div>
|
||||
<div class="singerText">{{ info.singerName }}</div>
|
||||
|
BIN
resources/img/default.png
Normal file
BIN
resources/img/default.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 6.6 MiB |
Loading…
x
Reference in New Issue
Block a user