[PR #9665] feat(desktop): add Revert and Fork actions to user messages #13180

Closed
opened 2026-02-16 18:18:03 -05:00 by yindo · 0 comments
Owner

Original Pull Request: https://github.com/anomalyco/opencode/pull/9665

State: closed
Merged: No


What does this PR do?

Fixes #9661
Adds Revert and Fork message actions to the desktop/web app, bringing feature parity with the CLI TUI.

  • Hover menu: Three-dot button appears next to copy button with Revert/Fork/Copy options
  • Right-click menu: Context menu on user messages with the same actions

Screenshots

Hover Button

Before After
before-button after-buttons

Right-Click Menu

Before After
before-rc after-rc

Changes

  • packages/app/src/components/message-actions.tsx - New MessageActions and MessageActionsMenu components
  • packages/ui/src/components/context-menu.tsx - New ContextMenu component (wraps Kobalte)
  • packages/ui/src/components/message-part.tsx - Added actions prop to render custom action buttons
  • packages/ui/src/components/session-turn.tsx - Pass actions through to Message component
  • packages/app/e2e/message-actions.spec.ts - E2E tests for all actions

How did you verify your code works?

  • Hover shows menu button
  • Menu opens with Revert/Fork/Copy options
  • Right-click shows context menu
  • Revert removes message and restores prompt
  • Fork creates new session and navigates to it
  • Copy copies message text to clipboard
  • All 5 E2E tests pass
**Original Pull Request:** https://github.com/anomalyco/opencode/pull/9665 **State:** closed **Merged:** No --- ### What does this PR do? Fixes #9661 Adds Revert and Fork message actions to the desktop/web app, bringing feature parity with the CLI TUI. - **Hover menu**: Three-dot button appears next to copy button with Revert/Fork/Copy options - **Right-click menu**: Context menu on user messages with the same actions ### Screenshots Hover Button | Before | After | |--------|-------| | <img width="579" height="123" alt="before-button" src="https://github.com/user-attachments/assets/0ffedb17-e1f6-41e5-b2a7-e0e9fa0737d1" /> | <img width="782" height="173" alt="after-buttons" src="https://github.com/user-attachments/assets/bc06e903-f03f-41c5-af82-8b381afb4524" /> Right-Click Menu | Before | After | |--------|-------| | <img width="574" height="171" alt="before-rc" src="https://github.com/user-attachments/assets/2f3268b0-17c4-471b-ba48-b15e3cb2e7bb" /> | <img width="714" height="186" alt="after-rc" src="https://github.com/user-attachments/assets/64fc4ba4-2e52-4b60-a165-21fd51fd49d0" /> | Changes - `packages/app/src/components/message-actions.tsx` - New MessageActions and MessageActionsMenu components - `packages/ui/src/components/context-menu.tsx` - New ContextMenu component (wraps Kobalte) - `packages/ui/src/components/message-part.tsx` - Added `actions` prop to render custom action buttons - `packages/ui/src/components/session-turn.tsx` - Pass actions through to Message component - `packages/app/e2e/message-actions.spec.ts` - E2E tests for all actions ### How did you verify your code works? - [x] Hover shows menu button - [x] Menu opens with Revert/Fork/Copy options - [x] Right-click shows context menu - [x] Revert removes message and restores prompt - [x] Fork creates new session and navigates to it - [x] Copy copies message text to clipboard - [x] All 5 E2E tests pass
yindo added the pull-request label 2026-02-16 18:18:03 -05:00
yindo closed this issue 2026-02-16 18:18:03 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#13180