From 8d4579f98729772214cfbaa70411498077da88be Mon Sep 17 00:00:00 2001 From: Jz0ojiang Date: Wed, 12 Aug 2026 03:32:53 +0800 Subject: [PATCH] =?UTF-8?q?=E5=BC=B9=E7=AA=97=E5=8A=A0=E5=BF=AB=E9=80=9F?= =?UTF-8?q?=E6=B7=A1=E5=87=BA=E9=80=80=E5=9C=BA=EF=BC=9B=E9=87=8D=E5=90=AF?= =?UTF-8?q?=E7=A1=AE=E8=AE=A4=E7=9A=84=E6=96=87=E6=A1=88=E6=8C=89=E9=85=8D?= =?UTF-8?q?=E7=BD=AE=E8=AF=B4=E8=AF=9D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 退场用 opacity 过渡加 display/overlay 的 allow-discrete——过渡结束前 元素留在 top layer,不支持的浏览器退化为立即消失。所有 dialog 一并 生效。 重启确认原来把 profile.store-selected 的配置项名直接甩给用户。现在读 配置判断(内核默认记住选中,config.go:576,显式 false 才会丢),按 实际情况说「选中的线路重启后不变」或「会回到默认成员」。 --- web/App.vue | 17 ++++++++++++++++- web/styles/tokens.css | 17 ++++++++++++++++- 2 files changed, 32 insertions(+), 2 deletions(-) diff --git a/web/App.vue b/web/App.vue index d1c1b21..bab9f07 100644 --- a/web/App.vue +++ b/web/App.vue @@ -100,6 +100,17 @@ const busyAct = ref(false) const historyOpen = ref(false) const askRestart = ref(false) +/** + * 重启后各组选中的线路能不能找回来:内核把选中记在缓存文件里,由 + * profile.store-selected 控制,默认开(config.go:576),显式写 false 才会丢。 + * 按用户的配置说话,不把配置项名字甩给他。 + */ +const keepsSelection = computed(() => { + const profile = snapshot.value?.data.profile + if (typeof profile !== 'object' || profile === null || Array.isArray(profile)) return true + return (profile as Record)['store-selected'] !== false +}) + async function undo() { if (busyAct.value) return busyAct.value = true @@ -379,7 +390,11 @@ const current = computed(() => NAV.find((n) => n.key === active.value))