fix(updater): keep update dialog compact and adapt branding contract

This commit is contained in:
YinBuLiao committed 2026-09-23 16:45:31 +08:00
1 parent c41f75081a
commit 5a781ccb04
5 files changed
+16 -4

No files matched your search

+2 -1
View File
@@ -800,8 +800,9 @@
},
"auto_download": "Download updates in the background",
"stop_download": "Stop download",
"skip_version": "Skip version",
"restart_install": "Restart and install",
"install_next_launch": "Install on next launch",
"install_next_launch": "Install on launch",
"ready_hint": "The update is ready. Pebrel will save your workspace and exit before installation, then reopen it.",
"later": "Later",
"prepare_failed": "Could not prepare the update: {error}. Pebrel will stay open.",
+1
View File
@@ -175,6 +175,7 @@
"sent_to": "{target}(으)로 전송했습니다"
},
"update": {
"skip_version": "이 버전 건너뛰기",
"downloading_hint": "이 기기에 맞는 업데이트 패키지를 다운로드하고 검증하는 중입니다.",
"no_verified_package": "이 릴리스에는 이 기기에 맞는 검증된 업데이트 패키지가 없습니다. 릴리스 페이지에서 직접 다운로드하세요.",
"check_fallback_failed": "GitHub API 접근이 제한되었으며(HTTP {status}) 공식 릴리스 페이지에도 연결할 수 없습니다: {error}. 나중에 다시 시도하거나 릴리스 페이지를 여세요.",
+2 -1
View File
@@ -800,9 +800,10 @@
},
"auto_download": "在后台预下载更新",
"stop_download": "停止下载",
"skip_version": "跳过此版本",
"restart_install": "重启并安装",
"install_next_launch": "下次启动时安装",
"ready_hint": "更新已就绪。Pebrel 将先保存工作区并退出,再安装更新并重新打开。",
"ready_hint": "更新已就绪,将保存工作区、安装更新并重启。",
"later": "稍后",
"prepare_failed": "更新准备失败:{error}。Pebrel 将保持打开。",
"draft_changed": "准备退出期间文档发生了变化。请保存或放弃最新修改后重试。",
@@ -203,7 +203,7 @@ pub(crate) fn open_update_dialog(
let latest_version: SharedString = format!("v{}", dialog_result.latest).into();
let later_text: SharedString =
language.text(Message::UpdateLater).into();
let skip_text: SharedString = language.pick("跳过此版本", "Skip this version").into();
let skip_text: SharedString = language.text(Message::UpdateSkipVersion).into();
let muted = cx.theme().muted_foreground;
let latest_color = cx.theme().warning;
let version_background = cx.theme().muted;
@@ -360,6 +360,7 @@ pub(crate) fn open_update_dialog(
let cancel_save_failed_prefix = save_failed_prefix.to_owned();
let cancel_error_separator = error_separator.to_owned();
let mut footer = DialogFooter::new()
.gap(px(6.0))
.child(
Button::new("skip-nebula-update")
.label(skip_text)
+9 -1
View File
@@ -85,7 +85,15 @@ class PebrelBrandingTests(unittest.TestCase):
self.assertIn('format!("Pebrel-v{version}-windows-x64-setup.exe")', check)
self.assertIn('format!("NebulaTerminal-{version}-windows-x64-setup.exe")', check)
self.assertIn("windows_x64_installer_names(version)", check)
self.assertIn("windows_x64_installer_names(&asset.version).contains(&asset.name)", download)
# Discovery and validation now route through the shared native selector.
# Retain the Windows brand contract while also checking the macOS path;
# executable Rust regressions cover accepted brands and rejected URLs.
assets = self.source("nebula_app/src/update_check/assets.rs")
self.assertIn("assets::native_names(&version)", check)
self.assertIn("assets::native_names(&asset.version)", download)
self.assertIn("super::windows_x64_installer_names(version).to_vec()", assets)
self.assertIn("Platform::MacOS => macos_names(version, std::env::consts::ARCH)", assets)
self.assertIn("if !names.contains(&asset.name)", download)
def test_notification_identity_uses_pebrel(self):
source = self.source("nebula_app/src/platform/notifications.rs")