fix: dispatch plan chips on double-click and send now - #7110
Conversation
Double-click and the Send-now segment called onSend with the chip label, so Go/Cancel reached the agent as chat instead of POSTing plan-action. Route those gestures through the same plan gate as single-click. Fixes #6240
UX Review (Fable 5) — ✅ PASSUX-level review of The diff is behavior-only: it routes double-click and Send-now on plan chips ( UX-Verdict: PASS The visible Send-now arrow and double-click now do what the chip label promises — notably, Cancel actually stops the plan instead of chatting "Cancel". [UX-REVIEWED] 4856936 |
Design Review (Fable 5) — ✅ PASSDesign-level review of Design-Verdict: PASS Root-cause fix at the right layer: all three chip gestures now converge on one per-host dispatch gate, with the straddled-footer race covered and spec updated in-commit. [DESIGN-REVIEWED] 4856936 |
GPT 5.6 Review — ✅ no blocking findingsGPT 5.6 completed its review of This comment is updated in place on each push. Review detailsNo findings. False positive or not applicable? A repository writer can comment: |
First Principles Review (Fable 5) — ✅ PASSPremise-level review of All evidence gathered. The supplied patch is stale-base drift plus the real change; the branch's own diff (verified via First-Principles-Verdict: PASS All three send gestures now route through the one plan gate single-click already used — cause-level, no riders, and the diff deletes more inline duplication than it adds. What this change shipsIntent: make double-click and the Send-now arrow on a plan chip actually drive the plan (so Cancel stops it) instead of chatting the label — a FIX.
Watch
[FIRST-PRINCIPLES-REVIEWED] 4856936 |
Opus 4.8 Review — ✅ no blocking findingsReviewed Verdict parsed from the review's SHA-scoped output markers for commit False positive or not applicable? A repository writer can comment: |
Double-click and Send-now now pass the click-time source key through onSend, so a footer that replaces the reused chip mid-gesture is refused instead of approving the next stage. Both hosts share one dispatch helper for every plan-chip gesture.
Why no screenshot: Dispatch-only change — plan chips look the same; double-click and Send now now hit the plan endpoint instead of chatting the label.
Problem / Motivation
On an orchestrator plan footer, a double-click or a click on the visible Send now arrow sent the chip label (
Go,Go All,Cancel) as ordinary chat instead of POSTing/api/chat/slots/{slot}/plan-action.Cancelis the sharp edge: a typed Cancel is not special-cased server-side, so the user pressed the stop control and the plan kept running.Why it matters
Single-click already dispatched correctly (#6040 / #5893). The two remaining send gestures skipped that gate, so the discoverable Send-now control and a habitual double-click both bypassed the plan endpoint and its per-slot single-flight latches.
What changed (motivation → approach → change)
FollowUpBar's double-click and Send-now segment call
onSend, notonSelect. Hosts wiredonSendstraight tosend()/doSend().onSendnow carries the same click-time row identityonSelectalready receives, so a footer that replaces the reused chip between the two clicks of a double-click is refused instead of approving the next stage. ChatPage and ChatPane each have onedispatchPlanFollowUphelper used by every gesture. SideChat and ChatEmbed still dropfollowUpIsPlanon purpose (#6057 / #6754).The autopilot spec names all three gestures and the first-click row snapshot.
Tests
onSendthe first-click key; Send-now hands the current key.Goand Send now onCanceldispatchplanAction; a straddled double-click after a replacement footer does not dispatch; Send now on a non-plan chip still sends the label.Goand Send now onGo AlldispatchplanAction.npx vitest run src/test/FollowUpBar.test.tsx src/test/ChatPane.followUpOptions.test.tsx src/test/ChatPage.followUpToggle.test.tsx— 90 passed.Manual verification
N/A — unit coverage drives the real ChatPage/ChatPane handlers through the real FollowUpBar gestures, including the replaced-footer race. No visual change.
Related Issues
Fixes #6240
Checklist