From 764d6143000a3a96b1978ae7e9687a2f29c08592 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Sun, 15 Feb 2026 16:15:36 +0000 Subject: [PATCH 1/2] Initial plan From 388397d1b8b8cec7a73cce76d70b1865f6400649 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Sun, 15 Feb 2026 16:22:20 +0000 Subject: [PATCH 2/2] Add plan block display in chat area during plan mode MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit When plan mode is active and the agent sends intent/plan text, a collapsible "📋 Plan" block now appears in the chat messages area. This allows users to see the plan while the agent is working on it, rather than only seeing the transient intent pill near the input area. The plan block: - Shows markdown-rendered plan content in the messages area - Is collapsible (click to expand/collapse) when content exceeds 5 lines - Only appears in expanded (non-compact) view when plan mode is active - Styled with a purple accent consistent with existing intent/reasoning UI - Supports the minimal style layout Co-authored-by: PureWeen <5375137+PureWeen@users.noreply.github.com> --- PolyPilot/Components/ChatMessageList.razor | 26 ++++++++++++ .../Components/ChatMessageList.razor.css | 42 +++++++++++++++++++ .../Components/ExpandedSessionView.razor | 4 +- 3 files changed, 71 insertions(+), 1 deletion(-) diff --git a/PolyPilot/Components/ChatMessageList.razor b/PolyPilot/Components/ChatMessageList.razor index 2b349d64..4f13765d 100644 --- a/PolyPilot/Components/ChatMessageList.razor +++ b/PolyPilot/Components/ChatMessageList.razor @@ -58,6 +58,28 @@ } } + @* Plan/intent — shown in expanded view when plan mode is active and there's intent text *@ + @if (!Compact && PlanMode && !string.IsNullOrEmpty(Intent)) + { +
+ + @if (!_planCollapsed || LineCount(Intent) <= 5) + { +
@((MarkupString)RenderMarkdown(Intent))
+ } + else + { +
@FirstLines(Intent, 3)
+ } +
+ } + @* Streaming content — only show while actively processing to avoid overlap with finalized History *@ @if (!string.IsNullOrEmpty(StreamingContent) && IsProcessing) { @@ -109,6 +131,10 @@ [Parameter] public string? UserAvatarUrl { get; set; } [Parameter] public ChatLayout Layout { get; set; } = ChatLayout.Default; [Parameter] public ChatStyle Style { get; set; } = ChatStyle.Normal; + [Parameter] public bool PlanMode { get; set; } + [Parameter] public string Intent { get; set; } = ""; + + private bool _planCollapsed; private string GetLayoutClass() => Layout switch { diff --git a/PolyPilot/Components/ChatMessageList.razor.css b/PolyPilot/Components/ChatMessageList.razor.css index b4d9db2b..9492b6c0 100644 --- a/PolyPilot/Components/ChatMessageList.razor.css +++ b/PolyPilot/Components/ChatMessageList.razor.css @@ -268,6 +268,47 @@ overflow: hidden; } +/* Plan block — shown when plan mode is active */ +::deep .plan-block { + flex-shrink: 0; + margin: 0.15rem 1rem; + border-left: 2px solid rgba(139, 92, 246, 0.4); + padding-left: 0.6rem; + background: rgba(139, 92, 246, 0.06); + border-radius: 0 6px 6px 0; + padding: 0.25rem 0.6rem; +} + +::deep .plan-header { + background: none; + border: none; + color: #a78bfa; + font-size: var(--type-body); + cursor: pointer; + display: flex; + align-items: center; + gap: 0.5rem; + padding: 0.25rem 0; + width: 100%; +} + +::deep .plan-title { + font-weight: 600; +} + +::deep .plan-content { + font-size: var(--type-body); + color: var(--text-secondary); + line-height: 1.6; + padding: 0.25rem 0; +} + +::deep .plan-content.preview { + max-height: 4.5em; + overflow: hidden; + white-space: pre-wrap; +} + ::deep .tool-card { flex-shrink: 0; margin: 0.25rem 1rem; @@ -769,6 +810,7 @@ max-width: 100%; } .chat-message-list.full.style-minimal ::deep .reasoning-block, +.chat-message-list.full.style-minimal ::deep .plan-block, .chat-message-list.full.style-minimal ::deep .action-box, .chat-message-list.full.style-minimal ::deep .task-complete-card, .chat-message-list.full.style-minimal ::deep .error-card { diff --git a/PolyPilot/Components/ExpandedSessionView.razor b/PolyPilot/Components/ExpandedSessionView.razor index 6ae5f5db..11e1b91b 100644 --- a/PolyPilot/Components/ExpandedSessionView.razor +++ b/PolyPilot/Components/ExpandedSessionView.razor @@ -105,7 +105,9 @@ Compact="false" UserAvatarUrl="@UserAvatarUrl" Layout="@Layout" - Style="@Style" /> + Style="@Style" + PlanMode="@PlanMode" + Intent="@Intent" /> @if (!string.IsNullOrEmpty(Error))