From 12ef5ec9e223340a6cee15f91e99c17412d033db Mon Sep 17 00:00:00 2001 From: anghunk Date: Thu, 29 Jan 2026 17:40:13 +0800 Subject: [PATCH] =?UTF-8?q?chore:=20=E6=9B=B4=E6=96=B0=E7=89=88=E6=9C=AC?= =?UTF-8?q?=E5=8F=B7=E8=87=B30.0.8=E5=B9=B6=E4=BC=98=E5=8C=96=E7=AE=A1?= =?UTF-8?q?=E7=90=86=E7=95=8C=E9=9D=A2=E4=BB=A3=E7=A0=81=E6=A0=BC=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 将package.json版本从0.0.7更新至0.0.8 - 统一API响应消息为中文"保存成功!" - 优化Vue组件代码缩进和格式,提升可读性 - 移除冗余的CSS注释代码 --- cwd-admin/src/views/SettingsView.vue | 484 ++++++++++++----------- cwd-api/src/api/admin/featureSettings.ts | 2 +- docs/api/admin/feature-settings.md | 2 +- package.json | 2 +- 4 files changed, 251 insertions(+), 239 deletions(-) diff --git a/cwd-admin/src/views/SettingsView.vue b/cwd-admin/src/views/SettingsView.vue index c8a9881..340d350 100644 --- a/cwd-admin/src/views/SettingsView.vue +++ b/cwd-admin/src/views/SettingsView.vue @@ -17,86 +17,88 @@
-
- - -
-
- - -
-
- - -
-
- - -
-

安全设置

-
- - -
-
- +
+ + +
+
+ + +
+
+ + +
+
+ + +
+

安全设置

+
+ + +
+
+ - -
-
- - -
-
- - -
-
- - -
+ +
+
+ + +
+
+ + +
+
+ + +
-
- -
-
+
+ +
+
@@ -107,29 +109,31 @@
-
- - -
开启后,评论区顶部会显示的文章点赞(喜欢)按钮。
-
-
- - -
开启后,评论列表中的每条评论都会显示点赞按钮。
-
-
- -
-
+
+ + +
+ 开启后,评论区顶部会显示的文章点赞(喜欢)按钮。 +
+
+
+ + +
开启后,评论列表中的每条评论都会显示点赞按钮。
+
+
+ +
+
@@ -140,143 +144,151 @@
-
- - -
-
- - -
+
+ + +
+
+ + +
-
-

1. SMTP 发件配置

+
+

1. SMTP 发件配置

-
- - -
+
+ + +
-
-
- - +
+
+ + +
+
+ + +
+
+ + +
+
+ +
+ + +
+
+ + +
+ 注意:QQ 邮箱必须使用授权码,而非 QQ 密码。
+ 请登录 QQ 邮箱网页版,在【设置 - 账户】中开启 POP3/SMTP 服务并生成授权码。 +
+
+ +
+

2. 邮件模板设置

+ +
+ +
+ 可用变量:${commentAuthor} (评论人昵称), ${postTitle} (文章标题), + ${postUrl} (文章链接), ${commentContent} (评论内容) +
+ +
+ +
+ +
+ 可用变量:${toName} (接收人昵称), ${replyAuthor} (回复人昵称), + ${postTitle} (文章标题), ${postUrl} (文章链接), ${parentComment} (原评论), + ${replyContent} (回复内容) +
+ +
+ +
+ {{ message }} +
+
+ + + +
-
- - -
-
- - -
-
- -
- - -
-
- - -
- 注意:QQ 邮箱必须使用授权码,而非 QQ 密码。
- 请登录 QQ 邮箱网页版,在【设置 - 账户】中开启 POP3/SMTP 服务并生成授权码。 -
-
- -
-

2. 邮件模板设置

- -
- -
- 可用变量:${commentAuthor} (评论人昵称), ${postTitle} (文章标题), ${postUrl} - (文章链接), ${commentContent} (评论内容) -
- -
- -
- -
- 可用变量:${toName} (接收人昵称), ${replyAuthor} (回复人昵称), ${postTitle} - (文章标题), ${postUrl} (文章链接), ${parentComment} (原评论), ${replyContent} - (回复内容) -
- -
- -
- {{ message }} -
-
- - - -
-
@@ -707,7 +719,7 @@ onMounted(() => { } .card-body { - padding-top: 4px; + /* padding-top: 4px; */ } .card-subtitle { @@ -727,7 +739,7 @@ onMounted(() => { display: flex; flex-direction: column; gap: 6px; - margin-bottom: 12px; + margin: 10px 0; } .form-label { diff --git a/cwd-api/src/api/admin/featureSettings.ts b/cwd-api/src/api/admin/featureSettings.ts index 8515771..08f63cc 100644 --- a/cwd-api/src/api/admin/featureSettings.ts +++ b/cwd-api/src/api/admin/featureSettings.ts @@ -31,7 +31,7 @@ export const updateFeatureSettings = async (c: Context<{ Bindings: Bindings }>) enableArticleLike }); - return c.json({ message: 'Saved successfully' }); + return c.json({ message: '保存成功!' }); } catch (e: any) { return c.json({ message: e.message || 'Failed to save feature settings' }, 500); } diff --git a/docs/api/admin/feature-settings.md b/docs/api/admin/feature-settings.md index e083b3f..3c4a524 100644 --- a/docs/api/admin/feature-settings.md +++ b/docs/api/admin/feature-settings.md @@ -73,7 +73,7 @@ PUT /admin/settings/feature ```json { - "message": "Saved successfully" + "message": "保存成功!" } ``` diff --git a/package.json b/package.json index 62ce183..da02c67 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "cwd", - "version": "0.0.7", + "version": "0.0.8", "license": "Apache-2.0", "repository": { "type": "git",