Skip to content

feat: persist agent chat across sidebar close/open#4158

Open
0vertake wants to merge 8 commits intosuperplanehq:mainfrom
0vertake:feat/persist-agent-chat-sidebar
Open

feat: persist agent chat across sidebar close/open#4158
0vertake wants to merge 8 commits intosuperplanehq:mainfrom
0vertake:feat/persist-agent-chat-sidebar

Conversation

@0vertake
Copy link
Copy Markdown
Collaborator

@0vertake 0vertake commented Apr 15, 2026

Summary

  • Lift currentChatId and activeTab state from OpenBuildingBlocksSidebar (unmounts on close) to the parent BuildingBlocksSidebar (stays mounted), so reopening the sidebar or clicking a node no longer loses the active conversation.
  • Messages are re-fetched from the API on remount via existing useEffect hooks — no backend changes needed.
    Test

Demo video

2026-04-15.15-27-38.mp4

Closes #4045

Signed-off-by: Milos Jovanovic <milosjovanovic519@gmail.com>
@superplanehq-integration
Copy link
Copy Markdown

👋 Commands for maintainers:

  • /sp start - Start an ephemeral machine (takes ~30s)
  • /sp stop - Stop a running machine (auto-executed on pr close)

Comment thread web_src/src/ui/BuildingBlocksSidebar/index.tsx
Copy link
Copy Markdown
Contributor

@cursor cursor bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 9cc68b3. Configure here.

Comment thread web_src/src/ui/BuildingBlocksSidebar/index.tsx
@lucaspin
Copy link
Copy Markdown
Contributor

lucaspin commented Apr 15, 2026

@shiroyasha you changed this sidebar recently. Can you take a look here?


sorry, clicked the wrong button :)

@lucaspin lucaspin closed this Apr 15, 2026
@lucaspin lucaspin reopened this Apr 15, 2026
onBlockClick,
}: BuildingBlocksSidebarProps) {
const disabledTooltip = disabledMessage || "Finish configuring the selected component first";
const [activeTab, setActiveTab] = useState<"components" | "ai">("components");
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The AI is no longer in the components sidebar, so this is probably deprecated.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

When you re-open the agent chat sidebar, it should continue from the last convo

3 participants