Skip to content

Commit d9450a0

Browse files
committed
fix(sidebar): tighten update download progress layout
1 parent 4574fa3 commit d9450a0

1 file changed

Lines changed: 8 additions & 6 deletions

File tree

src/renderer/views/MainView/parts/Sidebar/Sidebar.tsx

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -76,14 +76,16 @@ function UpdateButtons(props: { iconOnly?: boolean }) {
7676
}
7777

7878
return (
79-
<div className="flex w-full items-center gap-2 rounded-3xl px-2 py-1.5 text-sm text-muted">
79+
<div className="flex w-full items-center gap-2 rounded-3xl px-2 py-1.5 text-muted">
8080
<Download className="size-4 shrink-0 animate-pulse text-accent" />
8181
<div className="flex min-w-0 flex-1 flex-col gap-1">
82-
<span className="truncate">
83-
Downloading{versionLabel}{Math.round(downloadPercent)}%
84-
{speedLine ? ` · ${speedLine}` : ""}
85-
</span>
86-
{byteLine ? <span className="truncate text-xs opacity-80">{byteLine}</span> : null}
82+
<span className="truncate text-xs">Downloading{versionLabel}</span>
83+
<div className="flex min-w-0 items-center justify-between gap-2 text-xs opacity-80">
84+
<span className="truncate">{byteLine ?? ""}</span>
85+
<span className="shrink-0 whitespace-nowrap">
86+
{Math.round(downloadPercent)}%{speedLine ? ` · ${speedLine}` : ""}
87+
</span>
88+
</div>
8789
<div className="h-1 w-full rounded-full bg-white/10">
8890
<div
8991
className="h-1 rounded-full bg-accent transition-[width] duration-300"

0 commit comments

Comments
 (0)