The best way to control Claude Code, Codex and more from any computer or phone
Mirrored from https://github.com/Camo67/t3code.git
Synced Nov 23, 20:30 UTC
fix(web): thread panel shows the remote machine a thread runs on (#14972)
Co-authored-by: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Theo Browne committed
Oct 2, 2026 at 19:44 UTC
bb7997709dd5ed91a3aa18c091286f5f5331b0ef
1 file changed
+17
-3
apps/web/src/components/chat/ThreadDetailsPanel.tsx
+17
-3
@@ -9,7 +9,11 @@ import { AlertTriangleIcon, XIcon } from "lucide-react";
9
10
import type { DraftId } from "../../composerDraftStore";
11
import { useT3ProjectFileScripts } from "../../hooks/useT3ProjectFileScripts";
12
-import type { EnvMode, EnvironmentOption } from "../BranchToolbar.logic";
12
+import {
13
+ shouldShowEnvironmentIndicator,
14
+ type EnvMode,
15
+ type EnvironmentOption,
16
+} from "../BranchToolbar.logic";
17
import { BranchToolbar } from "../BranchToolbar";
18
import { BranchToolbarEnvironmentSelector } from "../BranchToolbarEnvironmentSelector";
19
import GitActionsControl from "../GitActionsControl";
@@ -78,6 +82,14 @@ export function ThreadDetailsPanel(props: ThreadDetailsPanelProps) {
82
props.environmentId,
83
props.activeProjectScripts ? props.gitCwd : null,
84
);
85
+ // Same rule as the composer strip: a lone remote machine still gets a row,
86
+ // shown as a static label because there is nothing to pick.
87
+ const canPickEnvironment = props.availableEnvironments.length > 1;
88
+ const showEnvironment = shouldShowEnvironmentIndicator({
89
+ activeEnvironment:
90
+ props.availableEnvironments.find((env) => env.environmentId === props.environmentId) ?? null,
91
+ canPickEnvironment,
92
+ });
93
const branchToolbarProps = {
94
showGitControls: props.isGitRepo,
95
environmentId: props.environmentId,
@@ -138,7 +150,7 @@ export function ThreadDetailsPanel(props: ThreadDetailsPanelProps) {
150
) : null}
151
152
<div className="flex flex-col">
141
- {density === "full" && props.availableEnvironments.length > 1 ? (
153
+ {density === "full" && showEnvironment ? (
154
<BranchToolbarEnvironmentSelector
155
displayMode="panel"
156
autoEnvironmentLabel={props.autoEnvironmentLabel}
@@ -146,7 +158,9 @@ export function ThreadDetailsPanel(props: ThreadDetailsPanelProps) {
158
envLocked={props.envLocked}
159
environmentId={props.environmentId}
160
availableEnvironments={props.availableEnvironments}
149
- onEnvironmentChange={props.onEnvironmentChange}
161
+ {...(canPickEnvironment
162
+ ? { onEnvironmentChange: props.onEnvironmentChange }
163
+ : {})}
164
/>
165
) : null}
166