refactor(sdk): tipSearch 全删、歌词解码器归位、IPC 桥移除、api-source 层拆除
- 四平台 tipSearch 全部删除(永不做搜索联想),types 同步去掉 tipSearch 字段 - 歌词解码器归位:kg/krcDecode、tx/qrcDecode、kw/lyricDecode(原 common/ 下三处) - rendererIpc/ipcNames IPC 桥删除,SDK 纯服务端化 - supportQuality 由各平台 apis 内联导出(sdk/index 汇总),kg/kw/tx/wy 改直连 apis/*,api-source 旧层移除
This commit is contained in:
1 parent
3c51e4d06a
commit
66d06ef48a
25 files changed
+42
-342
No files matched your search
+5
-3
@@ -1,12 +1,14 @@
|
||||
import type { HttpRequestObject } from '../types.ts'
|
||||
import { httpFetch } from '../request.ts'
|
||||
import getMusicInfo from './musicInfo.ts'
|
||||
import { rendererInvoke } from '../common/rendererIpc.ts'
|
||||
import { WIN_MAIN_RENDERER_EVENT_NAME } from '../common/ipcNames.ts'
|
||||
import { decodeQrc } from './qrcDecode.ts'
|
||||
|
||||
const songIdMap = new Map()
|
||||
const promises = new Map()
|
||||
export const decodeLyric = (lrc: any, tlrc?: any, rlrc?: any): Promise<any> => rendererInvoke(WIN_MAIN_RENDERER_EVENT_NAME.handle_tx_decode_lyric, { lrc, tlrc, rlrc })
|
||||
export const decodeLyric = async(lrc: any, tlrc?: any, rlrc?: any) => {
|
||||
const [lyric, tlyric, rlyric] = await Promise.all([decodeQrc(lrc), decodeQrc(tlrc), decodeQrc(rlrc)])
|
||||
return { lyric, tlyric, rlyric }
|
||||
}
|
||||
|
||||
|
||||
const parseTools = {
|
||||
|
||||
Reference in new issue
Block a user