Skip to content

feat(web): open a message as a right panel surface - #5209

Open
rt2zz wants to merge 4 commits into
pingdotgg:mainfrom
rt2zz:message-surface
Open

feat(web): open a message as a right panel surface#5209
rt2zz wants to merge 4 commits into
pingdotgg:mainfrom
rt2zz:message-surface

Conversation

@rt2zz

@rt2zz rt2zz commented Aug 1, 2026

Copy link
Copy Markdown

What Changed

Adds a "open message as a surface" feature. Exposed as a button next to the copy message button.

Why

Often the model gives a long report. I want to respond to one point immediately while continuing to formulate a response to the rest. Currently I copy the message into zed to do this, but way better if I can just pop it open as a surface.

I kept this intentionally minimal using only existing concepts

  • Does not support attachments yet
  • I don't actually think this deserves a standalone button, it should either be in a context menu or overflow menu, and most importantly bindable to a shortcut. I did not add a shortcut though because that would depend on a concept of message focus which would be independently valuable, but require more significant and mostly orthogonal changes.

future ideas:

  • give message surface tabs useful titles
  • path to get back to a conversation (or fork) from a message surface

UI Changes

Before:
Screenshot 2026-08-01 at 4 04 09 PM
After:
Screenshot 2026-08-01 at 4 12 21 PM
Screenshot 2026-08-01 at 4 12 30 PM

Checklist

  • This PR is small and focused
  • I explained what changed and why
  • I included before/after screenshots for any UI changes
  • [n/a] I included a video for animation/interaction changes

Note

Low Risk
UI-only extension of the existing right-panel surface pattern; no auth, API, or persistence schema beyond the versioned panel store already used for other surfaces.

Overview
Users can open a chat message in the right panel as a dedicated surface, alongside files, diff, and terminal—useful for reading long assistant replies while composing a response in the main thread.

Right panel model: Adds a message surface kind and openMessage(ref, messageId) in rightPanelStore, with per-message tab ids (message:messageId) and persistence bump. UI: Timeline rows expose an Open as surface control (panel icon) next to copy on user and assistant messages; ChatView renders MessageSurface when that tab is active, resolving the message from timeline entries and showing an empty state if it was removed. Tabs: RightPanelTabs labels message surfaces as "Message" with a MessageSquare icon.

User message text in the surface uses the same displayed text as the timeline (terminal context stripped via deriveDisplayedUserMessageState).

Reviewed by Cursor Bugbot for commit 21a5706. Bugbot is set up for automated code reviews on this repo. Configure here.

Note

Add message surfaces to the right panel in the chat view

  • Adds a message surface kind to rightPanelStore that stores a message by ID, deduplicating on repeated opens and setting it as the active surface.
  • Adds OpenMessageSurfaceButton (panel-right icon) to user and assistant message action bars in MessagesTimeline, wiring to openMessage in the store.
  • Adds MessageSurface component that renders the message content as markdown in the right panel, with a 'Message unavailable' fallback for missing messages.
  • Updates RightPanelTabs to show a message-bubble icon and 'Message' title for message surface tabs.

Macroscope summarized 21a5706.

@coderabbitai

coderabbitai Bot commented Aug 1, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 26a50d89-eb11-48f4-8eb6-fcec5d7d904f

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@github-actions github-actions Bot added vouch:unvouched PR author is not yet trusted in the VOUCHED list. size:L 100-499 changed lines (additions + deletions). labels Aug 1, 2026
Comment thread apps/web/src/components/chat/MessageSurface.tsx Outdated
Comment thread apps/web/src/components/chat/MessageSurface.tsx
@macroscopeapp

macroscopeapp Bot commented Aug 1, 2026

Copy link
Copy Markdown
Contributor

Approvability

Verdict: Needs human review

This PR introduces a new user-facing feature (opening messages in the right panel surface), adding new components and extending the panel store with a new surface type. New capabilities warrant human review even when implementation follows existing patterns.

You can customize Macroscope's approvability policy. Learn more.

Comment thread apps/web/src/components/chat/MessageSurface.tsx
@rt2zz rt2zz changed the title feat(web): open messages in right panel surfaces feat(web): open a message as a right panel surface Aug 2, 2026

@cursor cursor Bot left a comment

Copy link
Copy Markdown
Contributor

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 using high effort 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 008baf4. Configure here.

Comment thread apps/web/src/components/chat/MessageSurface.tsx Outdated
@rt2zz

rt2zz commented Aug 2, 2026

Copy link
Copy Markdown
Author

FYI: I removed attachment support, not because its a bad idea but because it implies a slighly larger component refactor and I didnt want to dilute the main suggestion here unless theres a baseline interest

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

Labels

size:L 100-499 changed lines (additions + deletions). vouch:unvouched PR author is not yet trusted in the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant