Skip to content

feat(client): pair other Computers from the browser and add All/Computer tabs to the channel list - #2505

Merged
DoodleBears merged 1 commit into
mainfrom
claude/project-thread-fst88w
Oct 21, 2026
Merged

DoodleBears merged 1 commit into
mainfrom
claude/project-thread-fst88w

Conversation

@DoodleBears

Copy link
Copy Markdown
Contributor

Requested by Vain · project thread

Why the change

The web channel list only showed this computer, so a person with BotHarness on two machines could not reach the second one from the browser / 网页频道列表只能看到本机,无法从浏览器接入另一台电脑。

Issue: Refs #2500 (web part of the unification; mobile tabs live in #2499)

Special things to note

  • Merge risk: the device gateway now answers CORS, but only for Host-shaped origins (loopback, tailnet HTTPS, Connect), only without a cookie, and only on pair, unpair, stream-ticket and /api/*. The browser opens the Remote mux with a one-time, 30 s ticket bound to the device and stored as a hash. Review focus: packages/core/src/devices/gateway.ts. Reverting this PR removes the browser path and leaves mobile pairing untouched. ADR-0242 records the decision / 网关新增 CORS 与一次性流票据,评审重点在 gateway.ts;回退即可撤掉网页路径,不影响手机。
  • Relation to feat(mobile): show the computer's own icon after chat names #2499: no file overlap. The web reuses the mobile apps/mobile/src/host/* client, conversation and pairing modules through a browser carrier.
  • Verification:
    • Automated: device-gateway.test.ts (2 new tests: cross-origin pair/call, cookie refused, /web/ refused, ticket single use, evil origin and revoked device refused), computer-sources.test.ts (5 new), bot-sidebar.test.ts green. CI-selected related run: 330 files pass; workspace-grant-roundtrip.test.ts fails the same way on main (node:sqlite bundling).
    • pnpm typecheck, pnpm lint (incl. CLI parity) and pnpm format:check pass.
    • Runtime: two isolated local Hosts (laptop, studio-mac). The laptop browser paired studio-mac from a pairing link, opened Ada on studio-mac, sent a message, and Ada replied live through the ticketed mux with deepseek-v4-pro.
    • Not run: Desktop (Electron) shell, a real tailnet between two physical machines, Human QA.
  • CI test plan: affected. No new config file or test directory.
  • CLI parity: the new surfaces are browser-local storage (paired computers, selected tab). They are listed as a configurable: false exemption group in scripts/cli-ui-inventory.json; pairing itself already has deepseekbot devices commands.
  • Known gaps: All shows each computer as its own section, not one merged recency list; remote chat shows text and attachment names only, no images or cards; computers use a generic monitor icon until the icon work lands; the browser does not see a revocation until its next reconnect.

Change outline

  • Tabs above the channel list: All (default), This computer, then each paired computer, plus a + to add one. Right-click a computer tab to remove it (also revokes this browser there).
  • In All, rows from other computers carry a small monitor mark.
  • Opening a remote Bot or channel shows it in the Messages panel with its computer's name in the header.
Light Dark
Before
Add computer
All tab
Computer tab
Remote chat

Generated by Claude Code

… All/Computer tabs

A Host's browser pairs another Computer through that Computer's device
gateway (cross-origin pairing plus a one-time stream ticket), lists it
as a tab beside All and This computer, and chats with its Bots and
channels in the Messages panel.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Asbot1EHttjnKA6hQuCC6r
@coderabbitai

coderabbitai Bot commented Oct 21, 2026

Copy link
Copy Markdown

Warning

Review limit reached

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Next included review available in 52 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used all 2 included reviews currently available.

Learn how review limits work.

Review configuration:

⚙️ Run configuration
  • Configuration used: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 18f7cdd3-2b44-4ca3-8dbd-eb7fc03b0444
📥 Commits

Reviewing files that changed from the base of the PR and between 77ddca9 and e150d55.

⛔ Files ignored due to path filters: 10
  • .github/pr-screenshots/2500/add-dark.png is excluded by !**/*.png
  • .github/pr-screenshots/2500/add-light.png is excluded by !**/*.png
  • .github/pr-screenshots/2500/all-dark.png is excluded by !**/*.png
  • .github/pr-screenshots/2500/all-light.png is excluded by !**/*.png
  • .github/pr-screenshots/2500/before-dark.png is excluded by !**/*.png
  • .github/pr-screenshots/2500/before-light.png is excluded by !**/*.png
  • .github/pr-screenshots/2500/chat-dark.png is excluded by !**/*.png
  • .github/pr-screenshots/2500/chat-light.png is excluded by !**/*.png
  • .github/pr-screenshots/2500/tab-dark.png is excluded by !**/*.png
  • .github/pr-screenshots/2500/tab-light.png is excluded by !**/*.png
📒 Files selected for processing: 12
  • changes/2500-computer-tabs.md
  • docs/adr/0242-a-browser-pairs-other-computers-through-their-device-gateway.md
  • packages/client/src/client/bot-sidebar.tsx
  • packages/client/src/client/channel-dock.tsx
  • packages/client/src/client/computer-sources.ts
  • packages/client/src/client/computer-tabs.tsx
  • packages/client/src/client/locale.ts
  • packages/client/src/client/remote-conversation-view.tsx
  • packages/client/test/computer-sources.test.ts
  • packages/core/src/devices/gateway.ts
  • packages/core/test/device-gateway.test.ts
  • scripts/cli-ui-inventory.json
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

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