Skip to content

Commit 6c8e5ef

Browse files
committed
fix(webapp): watch card confirms with one Watch button, no Done collapse step
1 parent 12cdc67 commit 6c8e5ef

1 file changed

Lines changed: 13 additions & 9 deletions

File tree

apps/webapp/app/components/dashboard-agent/WatchCard.tsx

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -143,22 +143,26 @@ export function WatchCard({
143143
icon={<EyeIcon className="size-3.5 shrink-0 text-text-dimmed" />}
144144
actions={
145145
<>
146+
{/* One confirm, expanded or not — an expanded card is submitted as
147+
shown, there is no separate "Done" collapse step. */}
146148
<Button
147149
variant="primary/small"
148150
disabled={blocked}
149151
LeadingIcon={pending ? ButtonSpinner : undefined}
150152
onClick={onSubmit}
151153
>
152-
{pending ? "Starting…" : "Start watching"}
153-
</Button>
154-
<Button
155-
variant="minimal/small"
156-
disabled={pending}
157-
aria-expanded={expanded}
158-
onClick={() => setExpanded((value) => !value)}
159-
>
160-
{expanded ? "Done" : "Customize"}
154+
{pending ? "Starting…" : "Watch"}
161155
</Button>
156+
{!expanded ? (
157+
<Button
158+
variant="minimal/small"
159+
disabled={pending}
160+
aria-expanded={expanded}
161+
onClick={() => setExpanded(true)}
162+
>
163+
Customize
164+
</Button>
165+
) : null}
162166
{onCancel ? (
163167
<Button variant="minimal/small" disabled={pending} onClick={onCancel}>
164168
Cancel

0 commit comments

Comments
 (0)