diff --git a/Note.md b/Note.md index 17441191..a7127dc8 100644 --- a/Note.md +++ b/Note.md @@ -41,8 +41,6 @@ A cold welcome 有bug [EditAbleText.vue](src%2Fcomponents%2FEditAbleText.vue) 不能自动聚焦 -在文章模式下,背单词时不能调出面板 - 单词发音,点击第二遍时减速 http://enpuz.com/ 语法分析工具 @@ -51,8 +49,6 @@ http://enpuz.com/ 语法分析工具 加载单词列表时需要loading -背单词页面div,位置应该恒定,不应该随翻译内容变动而跳动 - 点击句子播放的音乐,需要可暂停 footer 的输入数统计有问题,当在列表点一个,然后输入错误之后,不会统计到输入数里面(单词和文章的都有问题) diff --git a/components.d.ts b/components.d.ts index 68992d6f..0459c6fb 100644 --- a/components.d.ts +++ b/components.d.ts @@ -66,5 +66,9 @@ declare module 'vue' { VolumeSetting: typeof import('./src/components/Toolbar/VolumeSetting.vue')['default'] WordList: typeof import('./src/components/WordList.vue')['default'] WordListModal: typeof import('./src/components/WordListModal.vue')['default'] + WordListModal2: typeof import('./src/components/WordListModal2.vue')['default'] + } + export interface ComponentCustomProperties { + vLoading: typeof import('element-plus/es')['ElLoadingDirective'] } } diff --git a/src/assets/css/style.scss b/src/assets/css/style.scss index a002b501..248a8a71 100644 --- a/src/assets/css/style.scss +++ b/src/assets/css/style.scss @@ -40,14 +40,12 @@ html.dark { --color-main-bg: rgba(14, 18, 23, 1); //--color-main-bg: rgba(30,31,34, 1); --color-second-bg: rgb(43,45,48); + --color-second-bg: rgb(30,31,34); - --color-item-bg: rgb(51, 51, 51); - --color-item-hover: #5e5e5e; + --color-item-bg: rgb(43,45,48); --color-item-hover: rgb(67,69,74); - //--color-item-active: rgb(75, 110, 175); - //--color-item-active: rgb(103, 103, 103); - --color-item-active: rgb(67,69,74); - --color-item-border: rgb(73, 73, 73); + --color-item-active: rgb(84,84,84); + --color-item-border: rgb(41, 41, 41); --color-header-bg: rgb(51, 51, 51); --color-tooltip-bg: #252525; diff --git a/src/components/Backgorund.vue b/src/components/Backgorund.vue index d59ae80e..11531c51 100644 --- a/src/components/Backgorund.vue +++ b/src/components/Backgorund.vue @@ -12,7 +12,7 @@ import {onMounted} from "vue" const canvas = $ref() onMounted(() => { - console.log('canvas;', canvas) + // console.log('canvas;', canvas) let ctx = canvas.getContext("2d"); canvas.width = window.innerWidth; canvas.height = window.innerHeight; diff --git a/src/components/ChapterList.vue b/src/components/ChapterList.vue index b1db983d..7f6c7d6a 100644 --- a/src/components/ChapterList.vue +++ b/src/components/ChapterList.vue @@ -24,17 +24,11 @@ const list: any[] = $computed(() => { function showWordListModal(index: number, item: Word[]) { - if (runtimeStore.editDict.translateLanguage === 'common') { - console.time() - item.map((w: Word) => { - if (!w.trans.length) { - let res = runtimeStore.translateWordList.find(a => a.name === w.name) - if (res) w = Object.assign(w, res) - } - }) - console.timeEnd() - } - emitter.emit(EventKey.openWordListModal, {title: `第${index + 1}章`, list: item}) + emitter.emit(EventKey.openWordListModal, { + title: `第${index + 1}章`, + translateLanguage: runtimeStore.editDict.translateLanguage, + list: item + }) } diff --git a/src/components/Practice/PracticeWord/PracticeWord.vue b/src/components/Practice/PracticeWord/PracticeWord.vue index fd5e8dc1..df8f165b 100644 --- a/src/components/Practice/PracticeWord/PracticeWord.vue +++ b/src/components/Practice/PracticeWord/PracticeWord.vue @@ -18,10 +18,8 @@ let wordData = $ref({ watch([ () => store.load, - () => store.current.index, - () => store.current.dictType, () => store.currentDict.chapterIndex, - () => store.currentDict.chapterWordNumber, + () => store.currentDict.words, ], n => { getCurrentPractice() }) @@ -36,7 +34,7 @@ function getCurrentPractice() { } wordData.words = cloneDeep(store.chapter) wordData.index = 0 - console.log('wordData', wordData) + // console.log('wordData', wordData) } onMounted(() => { diff --git a/src/components/Practice/PracticeWord/TypingWord.vue b/src/components/Practice/PracticeWord/TypingWord.vue index 6ab3488e..382ba858 100644 --- a/src/components/Practice/PracticeWord/TypingWord.vue +++ b/src/components/Practice/PracticeWord/TypingWord.vue @@ -237,6 +237,8 @@ useOnKeyboardEventListener(onKeyDown, onKeyUp) class="word-list" :is-active="active" @change="(i:number) => data.index = i" + :show-word="!settingStore.dictation" + :show-translate="settingStore.translate" :list="data.words" :activeIndex="data.index"/> diff --git a/src/components/Toolbar/DictModal.vue b/src/components/Toolbar/DictModal.vue index 2f4cdfcf..0a50d192 100644 --- a/src/components/Toolbar/DictModal.vue +++ b/src/components/Toolbar/DictModal.vue @@ -1,9 +1,9 @@