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, 04:15 UTC
fix(web): the Tailscale HTTPS row says detection is off instead of telling users to start Tailscale (#18758)
Igor Makowski committed
Oct 18, 2026 at 21:16 UTC
784bad1c686f7e0faf72c3298387ba0a61eb62d9
3 files changed
+35
-1
apps/web/src/components/settings/ConnectionsSettings.logic.test.ts
+18
@@ -5,6 +5,7 @@ import {
5
canRevokeOtherClients,
6
isQrShareableEndpoint,
7
isWslSettingsRowVisible,
8
+ missingTailscaleEndpointDescription,
9
selectQrEndpointOption,
10
togglePairingScopeSelection,
11
} from "./ConnectionsSettings.logic";
@@ -232,3 +233,20 @@ describe("canRevokeOtherClients", () => {
233
expect(canRevokeOtherClients([{ current: true }, { current: false }])).toBe(true);
234
});
235
});
236
+
237
+describe("missingTailscaleEndpointDescription", () => {
238
+ it("explains that detection waits for Network access when the probe was skipped", () => {
239
+ expect(
240
+ missingTailscaleEndpointDescription({ mode: "local-only", tailscaleServeEnabled: false }),
241
+ ).toBe("Turn on Network access to detect Tailscale.");
242
+ });
243
+
244
+ it.each([
245
+ { mode: "network-accessible", tailscaleServeEnabled: false },
246
+ { mode: "local-only", tailscaleServeEnabled: true },
247
+ ] as const)("asks to start Tailscale when it was probed and not found (%o)", (state) => {
248
+ expect(missingTailscaleEndpointDescription(state)).toBe(
249
+ "Start Tailscale to set up HTTPS access through MagicDNS.",
250
+ );
251
+ });
252
+});
apps/web/src/components/settings/ConnectionsSettings.logic.ts
+15
@@ -4,6 +4,7 @@ import {
4
AuthTerminalOperateScope,
5
AuthTerminalReadScope,
6
type DesktopBridge,
7
+ type DesktopServerExposureState,
8
type DesktopWslState,
9
} from "@t3tools/contracts";
10
@@ -47,6 +48,20 @@ export function isQrShareableEndpoint(endpoint: AdvertisedEndpoint): boolean {
48
return endpoint.status !== "unavailable" && endpoint.reachability !== "loopback";
49
}
50
51
+/**
52
+ * Copy for the Tailscale HTTPS row when no Tailscale endpoint is advertised.
53
+ * The desktop skips the Tailscale probe until Network access or Tailscale
54
+ * Serve is on (it can trigger a macOS privacy prompt), so a missing endpoint
55
+ * then means "not checked", not "not running".
56
+ */
57
+export function missingTailscaleEndpointDescription(
58
+ state: Pick<DesktopServerExposureState, "mode" | "tailscaleServeEnabled"> | null,
59
+): string {
60
+ return state && state.mode !== "network-accessible" && !state.tailscaleServeEnabled
61
+ ? "Turn on Network access to detect Tailscale."
62
+ : "Start Tailscale to set up HTTPS access through MagicDNS.";
63
+}
64
+
65
export function isWslSettingsRowVisible(input: {
66
readonly state: DesktopWslState | null;
67
readonly error: string | null;
apps/web/src/components/settings/ConnectionsSettings.tsx
+2
-1
@@ -69,6 +69,7 @@ import {
69
canRevokeOtherClients,
70
isQrShareableEndpoint,
71
isWslSettingsRowVisible,
72
+ missingTailscaleEndpointDescription,
73
selectQrEndpointOption,
74
togglePairingScopeSelection,
75
} from "./ConnectionsSettings.logic";
@@ -3267,7 +3268,7 @@ export function ConnectionsSettings() {
3268
? tailscaleHttpsEndpoint.status === "available"
3269
? tailscaleHttpsEndpoint.httpBaseUrl
3270
: "Use Tailscale Serve to expose this backend through a MagicDNS HTTPS URL."
3270
- : "Start Tailscale to set up HTTPS access through MagicDNS."
3271
+ : missingTailscaleEndpointDescription(desktopServerExposureState)
3272
}
3273
control={
3274
tailscaleHttpsEndpoint ? (