feat(app): explorer context menu (rename/delete) and open files as tabs by Ratel-tech · Pull Request #39811 · anomalyco/opencode · GitHub
Skip to content

feat(app): explorer context menu (rename/delete) and open files as tabs - #39811

Closed
Ratel-tech wants to merge 3 commits into
anomalyco:devfrom
Ratel-tech:file-explorer-actions
Closed

Ratel-tech wants to merge 3 commits into
anomalyco:devfrom
Ratel-tech:file-explorer-actions

Conversation

@Ratel-tech

Copy link
Copy Markdown

Summary

Enhances the project file explorer sidebar with right-click actions and tab opening.

Note: this PR is stacked on #39808 (project file explorer sidebar). Once that merges, this diff will shrink to only the changes below.

Changes

  • Right-click context menu on files/directories in the explorer: Rename and Delete. Uses a controlled \MenuV2\ dropdown positioned at the cursor (fixes the prior always-open menu bug).
  • Rename dialog (\DialogV2\ + \TextInputV2, pre-filled name, Enter to confirm) and Delete confirmation dialog (danger button). \F2\ opens the rename dialog directly.
  • Real filesystem operations via new desktop IPC channels
    ename-path\ and
    emove-path\ (node \s.rename\ / \s.rm), exposed through preload and the \Platform\ interface.
  • Open file as tab: clicking a file in the explorer opens it as a tab in the existing session side panel (\layout.tabs(sessionKey).open) when a session is active; otherwise it navigates to the project session as before.
  • New i18n keys for rename/delete across all locales.

Testing

  • \�un typecheck\ in \packages/app\ and \packages/desktop\ (only pre-existing \custom-elements.d.ts\ error).
  • File tree unit tests passing.
  • Tested interactively in the desktop app.

Add a persistent left sidebar showing the current project file tree on all screens (new and legacy layouts), with searchable file listing and adjustable width. Add a BUILD/PLAN segmented control below the chat that switches the active agent mode.
Add right-click rename/delete actions to the project file explorer via a controlled dropdown menu and confirm dialogs, with F2 shortcut for rename. Rename/delete run on the real filesystem through new desktop IPC channels. Clicking a file in the explorer now opens it as a tab in the existing session side panel when a session is active.
@github-actions github-actions Bot added the needs:compliance This means the issue will auto-close after 2 hours. label Jul 31, 2026
@github-actions

Copy link
Copy Markdown
Contributor

@github-actions

Copy link
Copy Markdown
Contributor

@github-actions github-actions Bot removed the needs:compliance This means the issue will auto-close after 2 hours. label Jul 31, 2026
@github-actions github-actions Bot closed this Jul 31, 2026
@KamranM5 KamranM5 mentioned this pull request Oct 21, 2026
1 task done
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.

1 participant