refactor!: 移除品牌字样,音源改为 sources/ 目录自动加载,脚本不入库

This commit is contained in:
snowy-yang committed 2026-09-16 21:28:50 +08:00
1 parent f548e5990b
commit 5dd0468860
34 files changed
+256 -232

No files matched your search

+4 -4
View File
@@ -11,7 +11,7 @@ const mrcTools = {
parseLyric(str) {
str = str.replace(/\r/g, '')
const lines = str.split('\n')
const lxlrcLines: string[] = []
const yrcLines: string[] = []
const lrcLines: string[] = []
for (const line of lines) {
@@ -40,11 +40,11 @@ const mrcTools = {
})
const wordArr = words.split(this.rxps.wordTime)
const newWords = times.map((time, index) => `${time}${wordArr[index]}`).join('')
lxlrcLines.push(`[${time}]${newWords}`)
yrcLines.push(`[${time}]${newWords}`)
}
return {
lyric: lrcLines.join('\n'),
lxlyric: lxlrcLines.join('\n'),
yrc: yrcLines.join('\n'),
}
},
getText(url, tryNum = 0) {
@@ -67,7 +67,7 @@ const mrcTools = {
})
},
getLrc(url) {
return this.getText(url).then(text => ({ lxlyric: '', lyric: text }))
return this.getText(url).then(text => ({ yrc: '', lyric: text }))
},
getTrc(url) {
if (!url) return Promise.resolve('')
+1 -1
View File
@@ -72,7 +72,7 @@ const toBigintArray = (data: string): bigint[] => {
return jArr
}
// https://github.com/lyswhut/lx-music-desktop/issues/445#issuecomment-1139338682
// 基于社区通用的 mrc 逐字歌词解析思路
const MAX = 9223372036854775807n
const MIN = -9223372036854775808n
const toLong = (str: string | bigint): bigint => {