diff --git a/.gitignore b/.gitignore index 95745fb..99f4414 100644 --- a/.gitignore +++ b/.gitignore @@ -71,4 +71,5 @@ resources/wx_send pnpm-lock.yaml /pnpm-workspace.yaml wechat-research-site -.codex \ No newline at end of file +.codex +weflow-web-offical \ No newline at end of file diff --git a/electron/main.ts b/electron/main.ts index b2a93e5..080f247 100644 --- a/electron/main.ts +++ b/electron/main.ts @@ -136,6 +136,7 @@ const shouldOfferUpdateForTrack = (latestVersion: string, currentVersion: string } let lastAppliedUpdaterChannel: string | null = null +let lastAppliedUpdaterFeedUrl: string | null = null const resetUpdaterProviderCache = () => { const updater = autoUpdater as any // electron-updater 会缓存 provider;切换 channel 后需清理缓存,避免仍请求旧通道 @@ -146,23 +147,41 @@ const resetUpdaterProviderCache = () => { } } +const getUpdaterFeedUrlByTrack = (track: 'stable' | 'preview' | 'dev'): string => { + const repoBase = 'https://github.com/hicccc77/WeFlow/releases' + if (track === 'stable') return `${repoBase}/latest/download` + if (track === 'preview') return `${repoBase}/download/nightly-preview` + return `${repoBase}/download/nightly-dev` +} + const applyAutoUpdateChannel = (reason: 'startup' | 'settings' = 'startup') => { const track = getEffectiveUpdateTrack() const currentTrack = inferUpdateTrackFromVersion(appVersion) const baseUpdateChannel = track === 'stable' ? 'latest' : track + const nextFeedUrl = getUpdaterFeedUrlByTrack(track) const nextUpdaterChannel = process.platform === 'win32' && process.arch === 'arm64' ? `${baseUpdateChannel}-arm64` : baseUpdateChannel - if (lastAppliedUpdaterChannel && lastAppliedUpdaterChannel !== nextUpdaterChannel) { + if ( + (lastAppliedUpdaterChannel && lastAppliedUpdaterChannel !== nextUpdaterChannel) || + (lastAppliedUpdaterFeedUrl && lastAppliedUpdaterFeedUrl !== nextFeedUrl) + ) { resetUpdaterProviderCache() } autoUpdater.allowPrerelease = track !== 'stable' // 只要用户当前选择的目标通道与当前安装版本所属通道不同,就允许跨通道更新(含降级) autoUpdater.allowDowngrade = track !== currentTrack + // 统一走 generic feed,确保 preview/dev 命中各自固定发布页,不受 GitHub provider 的 prerelease 选择影响。 + autoUpdater.setFeedURL({ + provider: 'generic', + url: nextFeedUrl, + channel: nextUpdaterChannel + }) autoUpdater.channel = nextUpdaterChannel lastAppliedUpdaterChannel = nextUpdaterChannel - console.log(`[Update](${reason}) 当前版本 ${appVersion},当前轨道: ${currentTrack},渠道偏好: ${track},更新通道: ${autoUpdater.channel},allowDowngrade=${autoUpdater.allowDowngrade}`) + lastAppliedUpdaterFeedUrl = nextFeedUrl + console.log(`[Update](${reason}) 当前版本 ${appVersion},当前轨道: ${currentTrack},渠道偏好: ${track},更新通道: ${autoUpdater.channel},feed=${nextFeedUrl},allowDowngrade=${autoUpdater.allowDowngrade}`) } applyAutoUpdateChannel('startup') diff --git a/src/App.tsx b/src/App.tsx index 4ad162e..2f56226 100644 --- a/src/App.tsx +++ b/src/App.tsx @@ -591,9 +591,13 @@ function App() {
这是免费软件,如果你是付费购买的话请骂死那个骗子。 - 我们唯一的官方网站: + 官方网站: + + https://weflow.top + +  ·  - https://github.com/hicccc77/WeFlow + GitHub 仓库
@@ -608,7 +612,7 @@ function App() {

因使用本软件产生的任何直接或间接损失,开发者不承担任何责任。请确保你的使用行为符合当地法律法规。

4. 隐私保护

-

本软件不收集任何用户数据。软件更新检测仅获取版本信息,不涉及任何个人隐私。

+

本软件不收集任何用户隐私数据。软件更新检测仅获取版本信息,不涉及任何个人隐私。

@@ -666,30 +670,30 @@ function App() { )} {showWaylandWarning && ( -
-
-
- -

环境兼容性提示 (Wayland)

+
+
+
+ +

环境兼容性提示 (Wayland)

+
+
+
+

检测到您当前正在使用 Wayland 显示服务器。

+

在 Wayland 环境下,出于系统级的安全与设计机制,应用程序无法直接控制新弹出窗口的位置

+

这可能导致某些独立窗口(如消息通知、图片查看器等)出现位置随机、或不受控制的情况。这是底层机制导致的,对此我们无能为力。

+
+

如果您觉得窗口位置异常严重影响了使用体验,建议尝试:

+

1. 在系统登录界面,将会话切换回 X11 (Xorg) 模式。

+

2. 修改您的桌面管理器 (WM/DE) 配置,强制指定该应用程序的窗口规则。

-
-
-

检测到您当前正在使用 Wayland 显示服务器。

-

在 Wayland 环境下,出于系统级的安全与设计机制,应用程序无法直接控制新弹出窗口的位置

-

这可能导致某些独立窗口(如消息通知、图片查看器等)出现位置随机、或不受控制的情况。这是底层机制导致的,对此我们无能为力。

-
-

如果您觉得窗口位置异常严重影响了使用体验,建议尝试:

-

1. 在系统登录界面,将会话切换回 X11 (Xorg) 模式。

-

2. 修改您的桌面管理器 (WM/DE) 配置,强制指定该应用程序的窗口规则。

-
-
-
-
- -
+
+
+
+
+
)} {/* 更新提示对话框 */} diff --git a/src/pages/SettingsPage.tsx b/src/pages/SettingsPage.tsx index 808a601..1b3eb9f 100644 --- a/src/pages/SettingsPage.tsx +++ b/src/pages/SettingsPage.tsx @@ -2508,7 +2508,9 @@ function SettingsPage({ onClose }: SettingsPageProps = {}) {