Skip to content

Open terminal localhost links in the Browser preview#2610

Merged
illegalcall merged 6 commits into
mainfrom
fix/terminal-link-preview
Jul 13, 2026
Merged

Open terminal localhost links in the Browser preview#2610
illegalcall merged 6 commits into
mainfrom
fix/terminal-link-preview

Conversation

@codebanditssss

@codebanditssss codebanditssss commented Jul 11, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • keep terminal hyperlinks opening in the user's system browser
  • mirror loopback HTTP(S) links into the current worker session's AO Browser preview
  • reuse the existing session preview endpoint so the inspector opens and navigates through the normal CDC flow
  • clarify the empty Browser state with “Enter a URL or click one in the terminal.”

Behavior

Clicked URLs for localhost, *.localhost, 127.0.0.1, and ::1 in worker sessions open both externally and in AO's Browser panel. External and non-HTTP(S) links retain the existing external-only behavior.

Screenshot From 2026-07-11 19-19-00 Screenshot From 2026-07-11 19-19-10

Validation

  • npm test -- src/renderer/components/BrowserPanel.test.tsx src/renderer/components/XtermTerminal.test.tsx src/renderer/components/TerminalPane.test.tsx src/renderer/components/SessionView.test.tsx — 77/77 passed
  • npm run typecheck
  • Prettier check for all changed files
  • manual Electron verification on Fedora Linux

@codebanditssss codebanditssss marked this pull request as ready for review July 11, 2026 13:56
Comment thread frontend/src/renderer/components/TerminalPane.tsx Outdated
Comment thread frontend/src/renderer/components/TerminalPane.tsx Outdated
Comment thread frontend/src/renderer/components/TerminalPane.tsx Outdated
Comment thread frontend/src/renderer/components/TerminalPane.tsx Outdated
Comment thread frontend/src/renderer/components/XtermTerminal.tsx Outdated
@illegalcall

Copy link
Copy Markdown
Collaborator

PR description follow-up: the implementation now correctly excludes orchestrator sessions because they have no Browser inspector, but the Summary and Behavior sections still promise Browser mirroring for every current session. Please qualify those statements with worker sessions. Also update the Validation count: the listed focused command currently runs 76 tests, not 77.

- Share link activation across OSC 8 and detected URLs
- Keep loopback preview validation at its call site
@codebanditssss

Copy link
Copy Markdown
Collaborator Author

PR description follow-up: the implementation now correctly excludes orchestrator sessions because they have no Browser inspector, but the Summary and Behavior sections still promise Browser mirroring for every current session. Please qualify those statements with worker sessions. Also update the Validation count: the listed focused command currently runs 76 tests, not 77.

done

Comment thread frontend/src/renderer/components/TerminalPane.tsx Outdated
@i-trytoohard

Copy link
Copy Markdown
Contributor

From the NotesBot call on 2026-07-12, this existing pr appears to be relevant.
Match confidence: 0.78 (fuzzy).

Relevant discussion excerpts:

  • [26:48] Kiki: Yeah, now you can hear me? [27:02] prateek: Yeah, better. [27:03] Kiki: Yeah, so I was saying, uh, I reviewed some PRs and then fix issue. So the first issue was when we are like in the browser preview and we want to make changes using those notations, so they were like whatever changes we said, [...]
  • [27:02] prateek: Yeah, better. [27:03] Kiki: Yeah, so I was saying, uh, I reviewed some PRs and then fix issue. So the first issue was when we are like in the browser preview and we want to make changes using those notations, so they were like whatever changes we said, they were getting queued, so they were not [...]
  • [27:03] Kiki: Yeah, so I was saying, uh, I reviewed some PRs and then fix issue. So the first issue was when we are like in the browser preview and we want to make changes using those notations, so they were like whatever changes we said, they were getting queued, so they were not being able to send to the [...]

Source thread: https://discord.com/channels/1476302178913357958/1525926468444749957/1525926468444749957

Generated by AO Bot based on the transcript from NotesBot.

@illegalcall illegalcall merged commit ca0df77 into main Jul 13, 2026
3 checks passed
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.

3 participants