8000 Target the workspace browser side panel with --panel by strayge · Pull Request #472 · amirlehmam/wmux · GitHub
[go: up one dir, main page]

Skip to content

Target the workspace browser side panel with --panel - #472

Merged
amirlehmam merged 1 commit into
amirlehmam:masterfrom
strayge:feat/browser-panel-commands
Nov 23, 2026
Merged

amirlehmam merged 1 commit into
amirlehmam:masterfrom
strayge:feat/browser-panel-commands

Conversation

@strayge
@strayge strayge commented Nov 22, 2026
Copy link
Copy Markdown
Contributor

Problem

wmux browser can drive a browser pane, but the CLI has no explicit way to target the workspace’s side panel. An agent that wants to show a page alongside the terminal cannot reliably open it there and then inspect or interact with that same page.

Changes

  • Add --panel to all browser page commands.
  • Only open <url> reveals a closed panel. Other panel commands return an error instead of opening a split or driving another browser.
  • The side panel uses the Web engine. Without --panel, existing routing still applies.
wmux browser --panel open https://example.com
wmux browser --panel snapshot
wmux browser --panel click e1

Testing

  • Typecheck, main build, and CLI resource verification passed.
  • Full Vitest run: 7,154 passed, 10 skipped, 0 failed.

Use the existing Web browser commands and their result shapes against the caller’s workspace panel. Select the guest by surface ID and host window; never fall back to a split or shared attachment for an explicit panel request.

Only HTTP(S) navigation reveals a closed panel. Mount it on blank before navigating so a slow saved page cannot block the request. Keep docked panes and unflagged commands unchanged.
@amirlehmam
amirlehmam merged commit 9613930 into amirlehmam:master Nov 23, 2026
@amirlehmam
Copy link
Copy Markdown
Owner

Merged, thank you. It fits well on top of #470: the panel is a per-workspace thing now, so an explicit way to address it was the missing half. What I checked before merging: only open with an http(s) URL can reveal a closed panel and every other verb answers an error instead of opening a split; a stale caller is refused rather than falling back to another workspace's panel; the guest is checked against its host window before anything is sent to it; browserPanelStartBlank is not written to the session; and --surface and --panel typed after type, fill or eval in the prefix form stay part of the payload. The full suite passes on the merged tree (7,160 tests). It ships in 2.66.0, going out now.

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.

2 participants

0