mirror of
https://github.com/Megghy/vtsuru.live.git
synced 2025-12-07 02:46:55 +08:00
update domain
This commit is contained in:
@@ -231,6 +231,7 @@ function createColumns(): DataTableColumns<SongsInfo> {
|
|||||||
type: 'primary',
|
type: 'primary',
|
||||||
size: 'small',
|
size: 'small',
|
||||||
circle: true,
|
circle: true,
|
||||||
|
loading: isLrcLoading.value == data.key,
|
||||||
onClick: () => OnPlayMusic(data),
|
onClick: () => OnPlayMusic(data),
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -306,7 +307,9 @@ function OnPlayMusic(song: SongsInfo) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
const isLrcLoading = ref('')
|
||||||
async function GetLyric(song: SongsInfo) {
|
async function GetLyric(song: SongsInfo) {
|
||||||
|
isLrcLoading.value = song.key
|
||||||
QueryGetAPI<{ lyric: string; tlyric: string }>(SONG_API_URL + 'get-netease-lyric', { id: song.id })
|
QueryGetAPI<{ lyric: string; tlyric: string }>(SONG_API_URL + 'get-netease-lyric', { id: song.id })
|
||||||
.then((data) => {
|
.then((data) => {
|
||||||
console.log(mergeLyrics(data.data.lyric, data.data.tlyric))
|
console.log(mergeLyrics(data.data.lyric, data.data.tlyric))
|
||||||
@@ -329,6 +332,9 @@ async function GetLyric(song: SongsInfo) {
|
|||||||
lrc: '',
|
lrc: '',
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
.finally(() => {
|
||||||
|
isLrcLoading.value = ''
|
||||||
|
})
|
||||||
}
|
}
|
||||||
function mergeLyrics(originalLyrics: string, translatedLyrics: string): string {
|
function mergeLyrics(originalLyrics: string, translatedLyrics: string): string {
|
||||||
const originalLines = originalLyrics.split('\n')
|
const originalLines = originalLyrics.split('\n')
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
import { ref } from 'vue'
|
import { ref } from 'vue'
|
||||||
|
|
||||||
const debugAPI = import.meta.env.VITE_DEBUG_API
|
const debugAPI = import.meta.env.VITE_DEBUG_API
|
||||||
const releseAPI = `${document.location.protocol}//api.vtsuru.live/api/`
|
const releseAPI = `https://vtsuru.suki.club/api/`
|
||||||
|
|
||||||
export const isBackendUsable = ref(true)
|
export const isBackendUsable = ref(true)
|
||||||
|
|
||||||
|
|||||||
@@ -14,6 +14,6 @@ defineProps<{
|
|||||||
|
|
||||||
<template>
|
<template>
|
||||||
<NDivider style="margin-top: 10px" />
|
<NDivider style="margin-top: 10px" />
|
||||||
<ScheduleList v-if="currentData" :schedules="currentData ?? []" :is-self="accountInfo?.id == userInfo?.id" v-bind="$attrs" />
|
<ScheduleList v-if="currentData" :schedules="currentData ?? []" :is-self="false" v-bind="$attrs" />
|
||||||
<NDivider />
|
<NDivider />
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
Reference in New Issue
Block a user