feat:重构代码

This commit is contained in:
zyronon
2025-07-13 03:37:18 +08:00
parent 97c0c47746
commit 410f43e0c9
8 changed files with 270 additions and 107657 deletions

View File

@@ -49,6 +49,41 @@ export const PronunciationApi = 'https://dict.youdao.com/dictvoice?audio='
export type TranslateLanguageType = 'en' | 'zh-CN' | 'ja' | 'de' | 'common' | ''
export type LanguageType = 'en' | 'ja' | 'de' | 'code'
interface Word2 {
word: string,
phonetic0: string,
phonetic1: string,
trans: {
pos: string,
cn: string,
}[],
sentences: {
c: string,//content
cn: string,
}[],
phrases: {
c: string,
cn: string,
}[],
synos: {
pos: string,
cn: string,
ws: string[]
}[],
relWords: {
root: string,
rels: {
word: string,
cn: string,
}[]
},
etymology: {
t: string,//title
d: string,//desc
}[],
}
export type DictResource = {
id: string
name: string