From d49a918ba4f8b7c38ac6a88f6f660bfe70aafd78 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=B0=8F=E8=8E=AB=E5=94=90=E5=B0=BC?= Date: Wed, 9 Sep 2026 16:48:22 +0800 Subject: [PATCH] =?UTF-8?q?refactor(preference):=20=E9=87=8D=E6=9E=84?= =?UTF-8?q?=E5=81=8F=E5=A5=BD=E8=AE=BE=E7=BD=AE=E5=BC=80=E5=85=B3=E4=BA=A4?= =?UTF-8?q?=E4=BA=92=E4=B8=8EUI=E5=B1=95=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 1. 移除冗余的switch组件,统一使用内联分段器替代开关选择 2. 调整布尔设置项的UI布局,优化视觉展示 3. 简化值变更逻辑,移除站点默认判断逻辑 4. 更新重置弹窗文案与按钮颜色 --- .../uh-settings-popup/uh-settings-popup.vue | 53 ++++++++------- src/hooks/usePreferenceRows.ts | 9 +-- src/pages-blog/setting/setting.vue | 66 ++++++++++--------- 3 files changed, 66 insertions(+), 62 deletions(-) diff --git a/src/components/uh-settings-popup/uh-settings-popup.vue b/src/components/uh-settings-popup/uh-settings-popup.vue index 9f7a119..40e9da8 100644 --- a/src/components/uh-settings-popup/uh-settings-popup.vue +++ b/src/components/uh-settings-popup/uh-settings-popup.vue @@ -36,10 +36,6 @@ }) /* ---------------- 交互 ---------------- */ - function handleSwitchChange(def : { path : string[] }, detail : { value ?: unknown }) { - handleBoolChange(def.path, detail.value === true) - } - function currentValueOf(path : string[]) : string | null { return isFollowing(path) ? null : String(prefValueOf(path) ?? '') } @@ -148,30 +144,39 @@ \ No newline at end of file