From e5baf9ead6c8d362085ffc2979c0f921222e11c3 Mon Sep 17 00:00:00 2001 From: Syngnat Date: Sun, 5 Jul 2026 12:08:45 +0800 Subject: [PATCH] =?UTF-8?q?=E2=9C=A8=20feat(update):=20=E6=94=AF=E6=8C=81?= =?UTF-8?q?=20latest=20=E4=B8=8E=20dev=20=E6=9B=B4=E6=96=B0=E9=80=9A?= =?UTF-8?q?=E9=81=93=E5=88=87=E6=8D=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 新增更新通道持久化与按通道检查 GitHub Release - 关于页支持切换通道并隔离本地更新缓存状态 - 补充多语言文案、Wails 绑定与前后端测试覆盖 --- frontend/src/App.tsx | 25 +++ .../src/hooks/useAppUpdateManager.test.tsx | 28 +++ frontend/src/hooks/useAppUpdateManager.ts | 143 ++++++++++--- frontend/src/main.tsx | 28 ++- frontend/wailsjs/go/app/App.d.ts | 6 + frontend/wailsjs/go/app/App.js | 12 ++ go.mod | 2 +- internal/app/methods_update.go | 190 +++++++++++++++--- internal/app/methods_update_test.go | 171 +++++++++++++++- internal/app/update_channel_state.go | 148 ++++++++++++++ shared/i18n/de-DE.json | 8 + shared/i18n/en-US.json | 8 + shared/i18n/ja-JP.json | 8 + shared/i18n/ru-RU.json | 8 + shared/i18n/zh-CN.json | 8 + shared/i18n/zh-TW.json | 8 + 16 files changed, 740 insertions(+), 61 deletions(-) create mode 100644 internal/app/update_channel_state.go diff --git a/frontend/src/App.tsx b/frontend/src/App.tsx index a35542e1..092a4b01 100644 --- a/frontend/src/App.tsx +++ b/frontend/src/App.tsx @@ -1695,6 +1695,7 @@ function App() { aboutLoading, aboutUpdateStatus, canShowProgressEntry, + changeUpdateChannel, checkForUpdates, downloadUpdate, formatBytes, @@ -1703,11 +1704,14 @@ function App() { isAboutOpen, isBackgroundProgressForLatestUpdate, isLatestUpdateDownloaded, + isUpdateChannelLoading, + isUpdateChannelSaving, lastUpdateInfo, markUpdateProgressDismissed, muteLatestUpdate, setIsAboutOpen, showUpdateDownloadProgress, + updateChannel, updateDownloadProgress, } = useAppUpdateManager({ isMacRuntime, @@ -4998,6 +5002,27 @@ function App() {
{t('app.about.field.update_status')}
{aboutUpdateStatus || t('app.about.update_status.not_checked')}
+
+
{t('app.about.field.update_channel')}
+