From 5d10c4f1ff640e435711085767312f7d4669fee6 Mon Sep 17 00:00:00 2001 From: Toly Date: Thu, 13 Feb 2025 15:25:27 +0800 Subject: [PATCH 1/3] =?UTF-8?q?=E2=9C=A8=20Add=20new=20pages=20for=20readi?= =?UTF-8?q?ng=20article.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .vscode/settings.json | 11 +- components.d.ts | 14 --- src/router/index.ts | 10 ++ src/views/HomePage.vue | 13 +- src/views/ReadingArticle.vue | 27 +++++ src/views/ReadingArticleDetail.vue | 13 ++ src/views/RecordWord.vue | 186 +++++++++++++++-------------- 7 files changed, 169 insertions(+), 105 deletions(-) create mode 100644 src/views/ReadingArticle.vue create mode 100644 src/views/ReadingArticleDetail.vue diff --git a/.vscode/settings.json b/.vscode/settings.json index c357907..6ee4f34 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -1,4 +1,13 @@ { "files.autoSave": "afterDelay", - "editor.bracketPairColorization.independentColorPoolPerBracketType": true + "editor.bracketPairColorization.independentColorPoolPerBracketType": true, + "cSpell.words": [ + "dsense", + "FUIYOH", + "HIYAA", + "thisweek", + "usersetting", + "wordgroup", + "wordlist" + ] } diff --git a/components.d.ts b/components.d.ts index 3749c87..9e02a80 100644 --- a/components.d.ts +++ b/components.d.ts @@ -9,29 +9,15 @@ declare module 'vue' { export interface GlobalComponents { ElAffix: typeof import('element-plus/es')['ElAffix'] ElBacktop: typeof import('element-plus/es')['ElBacktop'] - ElButton: typeof import('element-plus/es')['ElButton'] ElCard: typeof import('element-plus/es')['ElCard'] ElCarousel: typeof import('element-plus/es')['ElCarousel'] ElCarouselItem: typeof import('element-plus/es')['ElCarouselItem'] ElCol: typeof import('element-plus/es')['ElCol'] - ElCollapse: typeof import('element-plus/es')['ElCollapse'] - ElCollapseItem: typeof import('element-plus/es')['ElCollapseItem'] - ElDescriptions: typeof import('element-plus/es')['ElDescriptions'] - ElDescriptionsItem: typeof import('element-plus/es')['ElDescriptionsItem'] - ElDialog: typeof import('element-plus/es')['ElDialog'] - ElDivider: typeof import('element-plus/es')['ElDivider'] ElEmpty: typeof import('element-plus/es')['ElEmpty'] - ElForm: typeof import('element-plus/es')['ElForm'] - ElFormItem: typeof import('element-plus/es')['ElFormItem'] ElIcon: typeof import('element-plus/es')['ElIcon'] - ElInput: typeof import('element-plus/es')['ElInput'] - ElOption: typeof import('element-plus/es')['ElOption'] - ElRadio: typeof import('element-plus/es')['ElRadio'] ElRow: typeof import('element-plus/es')['ElRow'] - ElSelect: typeof import('element-plus/es')['ElSelect'] ElSkeleton: typeof import('element-plus/es')['ElSkeleton'] ElSkeletonItem: typeof import('element-plus/es')['ElSkeletonItem'] - ElSwitch: typeof import('element-plus/es')['ElSwitch'] Header: typeof import('./src/components/Header.vue')['default'] IconCommunity: typeof import('./src/components/icons/IconCommunity.vue')['default'] IconDocumentation: typeof import('./src/components/icons/IconDocumentation.vue')['default'] diff --git a/src/router/index.ts b/src/router/index.ts index 4579987..0858461 100644 --- a/src/router/index.ts +++ b/src/router/index.ts @@ -18,6 +18,16 @@ const router = createRouter({ name: 'register', component: () => import('@/views/UserRegister.vue'), }, + { + path: '/reading', + name: 'reading', + component: () => import('@/views/ReadingArticle.vue'), + }, + { + path: '/reading/:articleID', + name: 'readingDetail', + component: () => import('@/views/ReadingArticleDetail.vue'), + }, { path: '/review/word/:groupID', name: 'reviewWord', diff --git a/src/views/HomePage.vue b/src/views/HomePage.vue index 4d5b5bf..6faf097 100644 --- a/src/views/HomePage.vue +++ b/src/views/HomePage.vue @@ -59,6 +59,16 @@ 词组广场 --> + + + 阅读理解 + + + 即将开放 + + row.year), @@ -147,6 +157,7 @@ function redirect(condition: string) { if (condition === 'settings') router.push('/settings'); if (condition === 'help') router.push('/help'); if (condition === 'square') router.push('/square'); + if (condition === 'reading') router.push('/reading'); } function mapWeekDay(week: string) { diff --git a/src/views/ReadingArticle.vue b/src/views/ReadingArticle.vue new file mode 100644 index 0000000..01d3b9e --- /dev/null +++ b/src/views/ReadingArticle.vue @@ -0,0 +1,27 @@ + + + diff --git a/src/views/ReadingArticleDetail.vue b/src/views/ReadingArticleDetail.vue new file mode 100644 index 0000000..1d2bad2 --- /dev/null +++ b/src/views/ReadingArticleDetail.vue @@ -0,0 +1,13 @@ + + diff --git a/src/views/RecordWord.vue b/src/views/RecordWord.vue index 023bf5c..570a3c2 100644 --- a/src/views/RecordWord.vue +++ b/src/views/RecordWord.vue @@ -5,48 +5,66 @@
Word:
-
-
-
Search +
+
+
Search
Group:
- + - +
 Audio 
- +
{{ card.property }} {{ card.phonetic }}
@@ -228,7 +238,7 @@ async function getDefaultGroup() { gap: 10px; margin-bottom: 10px; - &>div:nth-child(3) { + & > div:nth-child(3) { width: 100px; } @@ -261,7 +271,5 @@ async function getDefaultGroup() { width: 90%; color: #ff7c0ab3; } - - } - \ No newline at end of file + From 318e62d3ef4804949908b051bf37a09622a8b077 Mon Sep 17 00:00:00 2001 From: Toly Date: Fri, 14 Feb 2025 17:30:21 +0800 Subject: [PATCH 2/3] =?UTF-8?q?=F0=9F=8E=A8=20Update?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/utils/service.ts | 2 +- src/views/ReadingArticle.vue | 29 ++++++++++++++++++---- src/views/ReadingArticleDetail.vue | 40 ++++++++++++++++++++++++++++-- 3 files changed, 63 insertions(+), 8 deletions(-) diff --git a/src/utils/service.ts b/src/utils/service.ts index fefcab4..67c68b2 100644 --- a/src/utils/service.ts +++ b/src/utils/service.ts @@ -110,7 +110,7 @@ function createRequest(service: AxiosInstance) { Authorization: token ? `Bearer ${token}` : '', 'Content-Type': 'application/json', }, - timeout: 10000, + timeout: 100000, baseURL: import.meta.env.VITE_BASE_API, data: {}, }; diff --git a/src/views/ReadingArticle.vue b/src/views/ReadingArticle.vue index 01d3b9e..25aebcf 100644 --- a/src/views/ReadingArticle.vue +++ b/src/views/ReadingArticle.vue @@ -1,11 +1,16 @@