Skip to content

Add 'Refresh Tab' and 'Refresh Pane' to right-click context menus #149

@danshapiro

Description

@danshapiro

Summary

Add two new context menu actions for refreshing terminals and panes:

  1. "Refresh Tab" — right-click dropdown on each tab that calls refresh on every sub-pane in that tab's layout tree.
  2. "Refresh Pane" — right-click dropdown on each pane that regenerates the pane content using the best available method for its type:
    • Browser panes: reload/refresh the embedded browser page
    • Terminal panes (coding agents like Claude Code, Codex): reset the WebSocket connection or re-attach to the underlying PTY session
    • Plain terminal panes: re-attach / reconnect to the PTY, replaying the scrollback buffer

Motivation

Currently there's no quick way to recover a pane that has gotten into a bad state (stale connection, frozen browser, stuck agent) without closing and re-creating it. A refresh action preserves the session while re-establishing the frontend connection.

Acceptance Criteria

  • Right-clicking a tab shows a context menu with "Refresh Tab" (among existing items)
  • Right-clicking a pane (e.g. pane header/chrome) shows a context menu with "Refresh Pane"
  • "Refresh Pane" dispatches per-content-type logic:
    • Browser: reload the iframe/webview
    • Terminal (agent): detach + re-attach or equivalent reconnect
    • Terminal (shell): detach + re-attach, replaying scrollback
  • "Refresh Tab" iterates all panes in the tab's layout tree and refreshes each
  • Unit and integration tests cover the new menu items and refresh logic
  • Accessible: menu items have proper labels and keyboard support

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions