Skip to content

Commit 645dc7d

Browse files
itsmeakhilclaude
andcommitted
fix(updater): surface translated failure title; drop bogus install-phase pill %
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
1 parent 1aaf302 commit 645dc7d

1 file changed

Lines changed: 10 additions & 12 deletions

File tree

apps/desktop-ui/src/components/desktop/update-progress-modal.tsx

Lines changed: 10 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -34,15 +34,13 @@ export function UpdateProgressModal() {
3434
const open = locked || visible || error != null;
3535

3636
const label =
37-
error != null
38-
? t("failed")
39-
: phase === "installing"
40-
? t("installing")
41-
: phase === "restarting"
42-
? t("restarting")
43-
: pct !== null
44-
? t("downloadingPct", { pct })
45-
: t("downloading");
37+
phase === "installing"
38+
? t("installing")
39+
: phase === "restarting"
40+
? t("restarting")
41+
: pct !== null
42+
? t("downloadingPct", { pct })
43+
: t("downloading");
4644

4745
// Corner pill when the run is active but the modal is dismissed (no error).
4846
if (!open) {
@@ -53,7 +51,7 @@ export function UpdateProgressModal() {
5351
className="fixed bottom-4 right-4 z-50 flex items-center gap-2 rounded-full border border-border bg-card px-3.5 py-2 text-xs font-medium shadow-lg"
5452
>
5553
<Loader2 className="h-3.5 w-3.5 animate-spin text-primary" />
56-
{pct !== null ? t("pillPct", { pct }) : t("pill")}
54+
{pct !== null && phase === "downloading" ? t("pillPct", { pct }) : t("pill")}
5755
</button>
5856
);
5957
}
@@ -68,7 +66,7 @@ export function UpdateProgressModal() {
6866
>
6967
<DialogContent className="sm:max-w-[400px]" showCloseButton={!locked && error == null}>
7068
<DialogHeader>
71-
<DialogTitle>{t("title")}</DialogTitle>
69+
<DialogTitle>{error != null ? t("failed") : t("title")}</DialogTitle>
7270
</DialogHeader>
7371

7472
{error != null ? (
@@ -88,7 +86,7 @@ export function UpdateProgressModal() {
8886
)}
8987
<AnimatePresence mode="wait">
9088
<motion.p
91-
key={error != null ? "error" : phase}
89+
key={phase}
9290
initial={{ opacity: 0, y: 4 }}
9391
animate={{ opacity: 1, y: 0 }}
9492
exit={{ opacity: 0, y: -4 }}

0 commit comments

Comments
 (0)