You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
We need an API for modifying an existing iframe and webview #1898
It's currently not possible for an agent to navigate a browser or iframe to somewhere else. This is a common useful case. We either need to add this capability or at least make it easier to "swap", delete the existing and reopen a new in that spot.
Navigating in place looks like the smaller change, since the pane already does it. Every browser renderer registers a screen controller whose chromeActions.navigate(url) is what the header's URL bar calls on Enter (SurfacePaneHeader.tsx#L89-L91). The iframe commits the URL and reloads (IframePanel.tsx#L396). The webview calls host.navigate, or queues the URL while the view is still opening (WebviewPanel.tsx#L279-L284). So a control method such as surface.navigate { surface, url } could look up the target's screen controller and call that same action. The URL would pass through the same browserSurfaceUrl check that surface.iframe and surface.webview use. The Surface id, its spot in the layout, and its render mode would all stay the same.
What exists today:
agent-browser panes can already be pointed at a new page: dor agent-browser --surface surface:N open <url> drives the session bound to that Surface.
iframe and webview panes have no dor path. dor iframe and dor webview only open new panes, and --from replaces only an untouched terminal. docs/specs/dor-browser.md → "Placement And Lifetime" says Never replace a reference that already has a browser. So dor kill followed by dor iframe --from <neighbour> splits next to the neighbour instead of reusing the closed pane's spot.
The "swap" option would conflict with that spec rule and with I10 (a replacement is a new Surface, so the agent's handle would change). Navigating in place keeps the handle, which suits an agent that is reusing one pane.
Two choices need a maintainer:
CLI shape. A standalone dor navigate <surface> <target> that works on any browser Surface (and hands agent-browser panes to their provider), or a --surface <handle> flag on dor iframe / dor webview that navigates instead of opening.
Render mode on mismatch. If the target is a webview and the agent runs dor iframe --surface, should the pane stay a webview or switch to an iframe?
Once the shape is settled I can implement it with its dor-cli.md / dor-browser.md changes.
Activity
dormouse-bot commentedon Nov 28, 2026
Navigating in place looks like the smaller change, since the pane already does it. Every browser renderer registers a screen controller whose
chromeActions.navigate(url)is what the header's URL bar calls on Enter (SurfacePaneHeader.tsx#L89-L91). The iframe commits the URL and reloads (IframePanel.tsx#L396). The webview callshost.navigate, or queues the URL while the view is still opening (WebviewPanel.tsx#L279-L284). So a control method such assurface.navigate { surface, url }could look up the target's screen controller and call that same action. The URL would pass through the samebrowserSurfaceUrlcheck thatsurface.iframeandsurface.webviewuse. The Surface id, its spot in the layout, and its render mode would all stay the same.What exists today:
dor agent-browser --surface surface:N open <url>drives the session bound to that Surface.dorpath.dor iframeanddor webviewonly open new panes, and--fromreplaces only an untouched terminal.docs/specs/dor-browser.md→ "Placement And Lifetime" says Never replace a reference that already has a browser. Sodor killfollowed bydor iframe --from <neighbour>splits next to the neighbour instead of reusing the closed pane's spot.The "swap" option would conflict with that spec rule and with I10 (a replacement is a new Surface, so the agent's handle would change). Navigating in place keeps the handle, which suits an agent that is reusing one pane.
Two choices need a maintainer:
dor navigate <surface> <target>that works on any browser Surface (and hands agent-browser panes to their provider), or a--surface <handle>flag ondor iframe/dor webviewthat navigates instead of opening.dor iframe --surface, should the pane stay a webview or switch to an iframe?Once the shape is settled I can implement it with its
dor-cli.md/dor-browser.mdchanges.