From b670680a7de5c9bcc62bd3b6e223907eb14a01d0 Mon Sep 17 00:00:00 2001 From: David Kaya Date: Thu, 26 Mar 2026 23:46:04 +0100 Subject: [PATCH] refactor: improve plan mode UX with composer-integrated toggle and guidance text - Move plan mode toggle from pills row to composer send button area - Plan toggle sits next to the send button as a mode switch icon - Send button turns emerald when plan mode is active - Add mode indicator strip below composer when plan mode is on - Replace 'Implement this plan' auto-send button with instructional guidance text that tells the user to send a follow-up message - Keep Dismiss button to clear the plan review banner Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- src/renderer/components/ChatPane.tsx | 102 ++++++++++-------- .../components/chat/PlanReviewBanner.tsx | 34 ++---- 2 files changed, 63 insertions(+), 73 deletions(-) diff --git a/src/renderer/components/ChatPane.tsx b/src/renderer/components/ChatPane.tsx index ce09e61..e5fd14d 100644 --- a/src/renderer/components/ChatPane.tsx +++ b/src/renderer/components/ChatPane.tsx @@ -130,12 +130,6 @@ export function ChatPane({ void onSend(content); } - function handleImplementPlan() { - if (!pendingPlanReview) return; - onDismissPlanReview?.(); - void onSend('Implement the plan.'); - } - function handleDismissPlan() { onDismissPlanReview?.(); } @@ -399,7 +393,6 @@ export function ChatPane({
@@ -426,22 +419,6 @@ export function ChatPane({ onUpdate={onUpdateSessionApprovalSettings} /> )} - {onSetInteractionMode && ( - - )} {primaryAgent && (
- )} - + + {/* Send / Stop button */} + +
+ {isPlanMode && !isSessionBusy && ( +
+
+ + Plan mode — the agent will propose a plan instead of implementing + +
+ )}
diff --git a/src/renderer/components/chat/PlanReviewBanner.tsx b/src/renderer/components/chat/PlanReviewBanner.tsx index f0a8166..d63f77c 100644 --- a/src/renderer/components/chat/PlanReviewBanner.tsx +++ b/src/renderer/components/chat/PlanReviewBanner.tsx @@ -1,22 +1,16 @@ import { useCallback } from 'react'; -import { ClipboardList, Play, X } from 'lucide-react'; +import { ClipboardList, X } from 'lucide-react'; import { MarkdownContent } from '@renderer/components/MarkdownContent'; import type { PendingPlanReviewRecord } from '@shared/domain/planReview'; export function PlanReviewBanner({ planReview, - onImplement, onDismiss, }: { planReview: PendingPlanReviewRecord; - onImplement: (planReview: PendingPlanReviewRecord) => void; onDismiss: (planReview: PendingPlanReviewRecord) => void; }) { - const handleImplement = useCallback(() => { - onImplement(planReview); - }, [planReview, onImplement]); - const handleDismiss = useCallback(() => { onDismiss(planReview); }, [planReview, onDismiss]); @@ -63,26 +57,14 @@ export function PlanReviewBanner({ )} - - - {/* Actions */} -
- - + {/* Guidance */} +

+ Send a follow-up message to proceed — e.g.{' '} + "implement the plan",{' '} + "adjust step 3", or ask for a different approach. +

+
);