mirror of
https://github.com/imsyy/SPlayer.git
synced 2025-11-25 03:14:57 +08:00
fix: 修复底部播放器样式错误
This commit is contained in:
1
components.d.ts
vendored
1
components.d.ts
vendored
@@ -8,7 +8,6 @@ export {}
|
||||
declare module 'vue' {
|
||||
export interface GlobalComponents {
|
||||
AddPlaylist: typeof import('./src/components/Modal/AddPlaylist.vue')['default']
|
||||
CloudMatch: typeof import('./src/components/Modal/CloudMatch.vue')['default']
|
||||
CloudSongMatch: typeof import('./src/components/Modal/CloudSongMatch.vue')['default']
|
||||
CommentList: typeof import('./src/components/List/CommentList.vue')['default']
|
||||
CountDown: typeof import('./src/components/Player/CountDown.vue')['default']
|
||||
|
||||
@@ -5,7 +5,7 @@ const netEaseApi = require("NeteaseCloudMusicApi");
|
||||
*
|
||||
* @async
|
||||
* @param {Object} options - 服务器配置
|
||||
* @param {number} [options.port=12141] - 服务器端口
|
||||
* @param {number} [options.port=11451] - 服务器端口
|
||||
* @param {string} [options.host="127.0.0.1"] - 服务器主机地址
|
||||
* @returns {Promise<void>} 返回一个 Promise,在 API 服务器成功启动后 resolve
|
||||
*/
|
||||
|
||||
@@ -24,7 +24,7 @@
|
||||
"@electron-toolkit/preload": "^2.0.0",
|
||||
"@electron-toolkit/utils": "^2.0.0",
|
||||
"@material/material-color-utilities": "^0.2.7",
|
||||
"NeteaseCloudMusicApi": "^4.13.5",
|
||||
"NeteaseCloudMusicApi": "^4.13.6",
|
||||
"axios": "^1.4.0",
|
||||
"colorthief": "^2.4.0",
|
||||
"electron-dl": "^3.5.1",
|
||||
|
||||
8
pnpm-lock.yaml
generated
8
pnpm-lock.yaml
generated
@@ -15,8 +15,8 @@ dependencies:
|
||||
specifier: ^0.2.7
|
||||
version: 0.2.7
|
||||
NeteaseCloudMusicApi:
|
||||
specifier: ^4.13.5
|
||||
version: 4.13.5
|
||||
specifier: ^4.13.6
|
||||
version: 4.13.6
|
||||
axios:
|
||||
specifier: ^1.4.0
|
||||
version: 1.4.0
|
||||
@@ -1076,8 +1076,8 @@ packages:
|
||||
requiresBuild: true
|
||||
dev: true
|
||||
|
||||
/NeteaseCloudMusicApi@4.13.5:
|
||||
resolution: {integrity: sha512-UjaZeODKHBpSm/L4oxS1l5C7WGddoIhvmQ1BPknMZx32SmJRGUtNUKYWIGmVuO9uemtobLfPOhI7owNAzn2Udg==}
|
||||
/NeteaseCloudMusicApi@4.13.6:
|
||||
resolution: {integrity: sha512-dK6vReOVYBhOuUSocex1M3FNfRnJJvGmTfCavqXkSFguS+PyyeP7D6JDmF0NVqMskwE7r1uT2yqrozDnBA/Syw==}
|
||||
engines: {node: '>=12'}
|
||||
hasBin: true
|
||||
dependencies:
|
||||
|
||||
@@ -780,11 +780,15 @@ watch(
|
||||
bottom: 0;
|
||||
}
|
||||
&.no-sider {
|
||||
max-width: 1400px;
|
||||
margin: 0 auto;
|
||||
padding: 0 10vw;
|
||||
@media (max-width: 1200px) {
|
||||
padding: 0 5vw;
|
||||
padding: 0;
|
||||
.player {
|
||||
width: auto;
|
||||
max-width: 1400px;
|
||||
margin: 0 auto;
|
||||
padding: 0 10vw;
|
||||
@media (max-width: 1200px) {
|
||||
padding: 0 5vw;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -27,6 +27,7 @@
|
||||
<script setup>
|
||||
import { useRouter } from "vue-router";
|
||||
import { getArtistSongs } from "@/api/artist";
|
||||
import { getSongDetail } from "@/api/song";
|
||||
import formatData from "@/utils/formatData";
|
||||
|
||||
const router = useRouter();
|
||||
@@ -41,7 +42,14 @@ const getArtistHotData = async (id) => {
|
||||
artistHotSongs.value = null;
|
||||
// 获取热门歌曲
|
||||
const result = await getArtistSongs(id);
|
||||
artistHotSongs.value = formatData(result.hotSongs, "song");
|
||||
// 处理数据
|
||||
if (result.hotSongs?.[0]?.al?.picUrl) {
|
||||
artistHotSongs.value = formatData(result.hotSongs, "song");
|
||||
return true;
|
||||
}
|
||||
const ids = result.hotSongs.map((song) => song.id).join(",");
|
||||
const songsDetail = await getSongDetail(ids);
|
||||
artistHotSongs.value = formatData(songsDetail.songs, "song");
|
||||
} catch (error) {
|
||||
console.error("获取歌手热门数据失败:", error);
|
||||
}
|
||||
|
||||
@@ -32,7 +32,12 @@
|
||||
</n-text>
|
||||
<n-text v-if="albumDetail.alia" class="alia" depth="3">{{ albumDetail.alia }}</n-text>
|
||||
<div v-if="albumDetail.artists" class="creator">
|
||||
<n-text v-for="(item, index) in albumDetail.artists" :key="index" class="ar">
|
||||
<n-text
|
||||
v-for="(item, index) in albumDetail.artists"
|
||||
:key="index"
|
||||
class="ar"
|
||||
@click="router.push(`/artist?id=${item.id}`)"
|
||||
>
|
||||
{{ item.name }}
|
||||
</n-text>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user