Skip to content
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions apps/web/src/components/ChatView.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3152,6 +3152,10 @@ function ChatViewContent(props: ChatViewProps) {
if (!activeThreadRef) return;
useRightPanelStore.getState().open(activeThreadRef, "agents");
}, [activeThreadRef]);
const addPlanSurface = useCallback(() => {
if (!activeThreadRef) return;
useRightPanelStore.getState().open(activeThreadRef, "plan");
}, [activeThreadRef]);
Comment thread
cursor[bot] marked this conversation as resolved.
Outdated
const openFileSurface = useCallback(
(relativePath: string) => {
if (!activeThreadRef || !activeProject) return;
Expand Down Expand Up @@ -6316,6 +6320,7 @@ function ChatViewContent(props: ChatViewProps) {
onAddDiff={addDiffSurface}
onAddFiles={addFilesSurface}
onAddAgents={addAgentsSurface}
onAddPlan={addPlanSurface}
browserAvailable={isPreviewSupportedInRuntime()}
diffAvailable={isServerThread && isGitRepo}
filesAvailable={activeProject !== null}
Expand Down Expand Up @@ -6344,6 +6349,7 @@ function ChatViewContent(props: ChatViewProps) {
onAddDiff={addDiffSurface}
onAddFiles={addFilesSurface}
onAddAgents={addAgentsSurface}
onAddPlan={addPlanSurface}
browserAvailable={isPreviewSupportedInRuntime()}
diffAvailable={isServerThread && isGitRepo}
filesAvailable={activeProject !== null}
Expand Down
15 changes: 15 additions & 0 deletions apps/web/src/components/RightPanelTabs.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ interface RightPanelTabsProps {
onAddDiff: () => void;
onAddFiles: () => void;
onAddAgents: () => void;
onAddPlan: () => void;
browserAvailable: boolean;
diffAvailable: boolean;
filesAvailable: boolean;
Expand Down Expand Up @@ -93,6 +94,7 @@ function RightPanelEmptyState(props: {
onAddDiff: () => void;
onAddFiles: () => void;
onAddAgents: () => void;
onAddPlan: () => void;
browserAvailable: boolean;
diffAvailable: boolean;
filesAvailable: boolean;
Expand Down Expand Up @@ -138,6 +140,14 @@ function RightPanelEmptyState(props: {
disabledReason: null,
onClick: props.onAddAgents,
},
{
label: "Plan",
description: "View plan steps and tasks.",
icon: ClipboardList,
available: true,
disabledReason: null,
onClick: props.onAddPlan,
},
] as const;

return (
Expand Down Expand Up @@ -484,6 +494,10 @@ export function RightPanelTabs(props: RightPanelTabsProps) {
<Bot />
Agents
</SurfaceMenuItem>
<SurfaceMenuItem available onClick={props.onAddPlan}>
<ClipboardList />
Plan
</SurfaceMenuItem>
</MenuPopup>
</Menu>
) : null}
Expand All @@ -499,6 +513,7 @@ export function RightPanelTabs(props: RightPanelTabsProps) {
onAddDiff={props.onAddDiff}
onAddFiles={props.onAddFiles}
onAddAgents={props.onAddAgents}
onAddPlan={props.onAddPlan}
browserAvailable={props.browserAvailable}
diffAvailable={props.diffAvailable}
filesAvailable={props.filesAvailable}
Expand Down