fix(resource-usage): friendly label in kill-confirm dialog

The kill-confirm dialog showed the raw session ID
(uuid@@worktreeId@@absolute-path), which overflowed the dialog because
UUIDs/paths have no break points and isn't actionable for the user
anyway — they don't recognize their terminals by GUID.

Use session.label (e.g. "Terminal 2") and put it directly in the
dialog title so the body copy stays short and readable: "Kill Terminal 2?
Force-quits this terminal. Any unsaved work in the pane is lost."

Co-authored-by: Orca <help@stably.ai>
This commit is contained in:
Jinwoo-H
2026-05-05 14:31:37 -04:00
co-authored by Orca
parent c189624865
commit 6b85d30c5c
@@ -1253,11 +1253,16 @@ export function ResourceUsageStatusSegment({
}}
>
<DialogHeader>
<DialogTitle className="text-sm">Kill this session?</DialogTitle>
<DialogTitle className="text-sm">
Kill{' '}
<span className="font-medium text-foreground">
{killConfirm?.label ?? 'this session'}
</span>
?
</DialogTitle>
<DialogDescription className="text-xs">
Force-quits{' '}
<span className="font-medium text-foreground">{killConfirm?.sessionId}</span>. Any
unsaved work in that pane is lost. This can&apos;t be undone.
Force-quits this terminal. Any unsaved work in the pane is lost. This can&apos;t be
undone.
</DialogDescription>
</DialogHeader>
<DialogFooter>