@adminide-stack/yantra-mobile 12.0.174-alpha.1 → 12.0.174
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/config/env-config.js +4 -0
- package/lib/config/env-config.js.map +1 -1
- package/lib/features/channels/ChannelIcon.js +11 -0
- package/lib/features/channels/ChannelIcon.js.map +1 -1
- package/lib/features/channels/ComputerPanel.js +538 -0
- package/lib/features/channels/ComputerPanel.js.map +1 -0
- package/lib/features/channels/ConnectAppsSheet.js +3 -2
- package/lib/features/channels/ConnectAppsSheet.js.map +1 -1
- package/lib/features/channels/channelLinks.js +6 -0
- package/lib/features/channels/channelLinks.js.map +1 -1
- package/lib/features/channels/computerLink.js +80 -0
- package/lib/features/channels/computerLink.js.map +1 -0
- package/lib/features/games/cubeforge3D.js +114 -7
- package/lib/features/games/cubeforge3D.js.map +1 -1
- package/lib/features/games/cubeforgeFriends.js +11 -3
- package/lib/features/games/cubeforgeFriends.js.map +1 -1
- package/lib/features/games/cubeforgeHelper.js +105 -0
- package/lib/features/games/cubeforgeHelper.js.map +1 -0
- package/lib/features/games/useCubeforgeHelper.js +25 -0
- package/lib/features/games/useCubeforgeHelper.js.map +1 -0
- package/lib/features/games/vendored/core/cubeforge/helper.js +13 -0
- package/lib/features/games/vendored/core/cubeforge/helper.js.map +1 -0
- package/lib/features/games/vendored/core/cubeforge/nativeWorlds.js +36 -1
- package/lib/features/games/vendored/core/cubeforge/nativeWorlds.js.map +1 -1
- package/lib/features/games/vendored/core/cubeforge/sharedWorlds.js.map +1 -1
- package/lib/features/games/vendored/core/cubeforge/skin.js +2 -2
- package/lib/features/games/vendored/core/cubeforge/skin.js.map +1 -1
- package/lib/features/games/vendored/ui/GamesRoot.js +25 -5
- package/lib/features/games/vendored/ui/GamesRoot.js.map +1 -1
- package/lib/features/games/vendored/ui/screens/Cubeforge3DHomeScreen.js +21 -9
- package/lib/features/games/vendored/ui/screens/Cubeforge3DHomeScreen.js.map +1 -1
- package/lib/screens/GamesNative/index.js +5 -3
- package/lib/screens/GamesNative/index.js.map +1 -1
- package/package.json +5 -4
|
@@ -0,0 +1,538 @@
|
|
|
1
|
+
import {jsx,jsxs}from'react/jsx-runtime';import {useState,useRef,useCallback,useEffect}from'react';import {StyleSheet,Alert,View,ActivityIndicator,Text,Pressable,TextInput,Clipboard}from'react-native';import {MaterialCommunityIcons}from'@expo/vector-icons';import {ChannelIcon}from'./ChannelIcon.js';import {useComputerLinkApi,parsePairingCode,computerStatusLabel,spacedCheck,CLI_PAIR_COMMAND,MAC_APP_URL,CLI_INSTALL_COMMAND}from'./computerLink.js';var __defProp = Object.defineProperty;
|
|
2
|
+
var __defProps = Object.defineProperties;
|
|
3
|
+
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
4
|
+
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
7
|
+
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
8
|
+
var __spreadValues = (a, b) => {
|
|
9
|
+
for (var prop in b || (b = {}))
|
|
10
|
+
if (__hasOwnProp.call(b, prop))
|
|
11
|
+
__defNormalProp(a, prop, b[prop]);
|
|
12
|
+
if (__getOwnPropSymbols)
|
|
13
|
+
for (var prop of __getOwnPropSymbols(b)) {
|
|
14
|
+
if (__propIsEnum.call(b, prop))
|
|
15
|
+
__defNormalProp(a, prop, b[prop]);
|
|
16
|
+
}
|
|
17
|
+
return a;
|
|
18
|
+
};
|
|
19
|
+
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
20
|
+
const POLL_MS = 3e3;
|
|
21
|
+
const COPIED_MS = 1800;
|
|
22
|
+
function messageOf(err) {
|
|
23
|
+
return err instanceof Error && err.message ? err.message : "Something went wrong. Please try again.";
|
|
24
|
+
}
|
|
25
|
+
function Action({
|
|
26
|
+
label,
|
|
27
|
+
colors,
|
|
28
|
+
onPress,
|
|
29
|
+
tone = "primary",
|
|
30
|
+
busy,
|
|
31
|
+
disabled
|
|
32
|
+
}) {
|
|
33
|
+
const filled = tone === "primary";
|
|
34
|
+
const ink = filled ? "#fff" : colors.text;
|
|
35
|
+
return /* @__PURE__ */ jsxs(Pressable, { onPress, disabled: disabled || busy, accessibilityRole: "button", accessibilityLabel: label, style: ({
|
|
36
|
+
pressed
|
|
37
|
+
}) => [styles.action, filled ? {
|
|
38
|
+
backgroundColor: colors.primary
|
|
39
|
+
} : {
|
|
40
|
+
borderColor: colors.border,
|
|
41
|
+
borderWidth: 1
|
|
42
|
+
}, (pressed || disabled) && styles.dim], children: [
|
|
43
|
+
busy ? /* @__PURE__ */ jsx(ActivityIndicator, { size: "small", color: ink }) : null,
|
|
44
|
+
/* @__PURE__ */ jsx(Text, { style: [styles.actionLabel, {
|
|
45
|
+
color: ink
|
|
46
|
+
}], children: label })
|
|
47
|
+
] });
|
|
48
|
+
}
|
|
49
|
+
function Problem({
|
|
50
|
+
label,
|
|
51
|
+
colors
|
|
52
|
+
}) {
|
|
53
|
+
return /* @__PURE__ */ jsxs(View, { accessibilityRole: "alert", style: [styles.note, {
|
|
54
|
+
backgroundColor: colors.dangerSoft
|
|
55
|
+
}], children: [
|
|
56
|
+
/* @__PURE__ */ jsx(MaterialCommunityIcons, { name: "alert-circle-outline", size: 16, color: colors.dangerText }),
|
|
57
|
+
/* @__PURE__ */ jsx(Text, { style: [styles.noteText, {
|
|
58
|
+
color: colors.dangerText
|
|
59
|
+
}], children: label })
|
|
60
|
+
] });
|
|
61
|
+
}
|
|
62
|
+
function CopyRow({
|
|
63
|
+
label,
|
|
64
|
+
value,
|
|
65
|
+
colors
|
|
66
|
+
}) {
|
|
67
|
+
const [copied, setCopied] = useState(false);
|
|
68
|
+
const timer = useRef(null);
|
|
69
|
+
useEffect(() => () => {
|
|
70
|
+
if (timer.current) clearTimeout(timer.current);
|
|
71
|
+
}, []);
|
|
72
|
+
return /* @__PURE__ */ jsxs(Pressable, { onPress: () => {
|
|
73
|
+
Clipboard.setString(value);
|
|
74
|
+
setCopied(true);
|
|
75
|
+
if (timer.current) clearTimeout(timer.current);
|
|
76
|
+
timer.current = setTimeout(() => setCopied(false), COPIED_MS);
|
|
77
|
+
}, accessibilityRole: "button", accessibilityLabel: `Copy ${label}`, style: ({
|
|
78
|
+
pressed
|
|
79
|
+
}) => [styles.copy, {
|
|
80
|
+
backgroundColor: colors.surfaceMuted
|
|
81
|
+
}, pressed && styles.dim], children: [
|
|
82
|
+
/* @__PURE__ */ jsx(Text, { style: [styles.copyText, {
|
|
83
|
+
color: colors.text
|
|
84
|
+
}], selectable: true, children: value }),
|
|
85
|
+
/* @__PURE__ */ jsx(MaterialCommunityIcons, { name: copied ? "check" : "content-copy", size: 18, color: copied ? colors.successText : colors.textMuted })
|
|
86
|
+
] });
|
|
87
|
+
}
|
|
88
|
+
async function loadCamera() {
|
|
89
|
+
try {
|
|
90
|
+
return await import('expo-camera');
|
|
91
|
+
} catch (e) {
|
|
92
|
+
return null;
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
function Scanner({
|
|
96
|
+
colors,
|
|
97
|
+
onCode
|
|
98
|
+
}) {
|
|
99
|
+
const [camera, setCamera] = useState(void 0);
|
|
100
|
+
const [granted, setGranted] = useState(null);
|
|
101
|
+
const scanned = useRef(false);
|
|
102
|
+
useEffect(() => {
|
|
103
|
+
let cancelled = false;
|
|
104
|
+
void (async () => {
|
|
105
|
+
const loaded = await loadCamera();
|
|
106
|
+
if (cancelled) return;
|
|
107
|
+
setCamera(loaded);
|
|
108
|
+
if (!loaded) return;
|
|
109
|
+
try {
|
|
110
|
+
const answer = await loaded.Camera.requestCameraPermissionsAsync();
|
|
111
|
+
if (!cancelled) setGranted(answer.granted);
|
|
112
|
+
} catch (e) {
|
|
113
|
+
if (!cancelled) setCamera(null);
|
|
114
|
+
}
|
|
115
|
+
})();
|
|
116
|
+
return () => {
|
|
117
|
+
cancelled = true;
|
|
118
|
+
};
|
|
119
|
+
}, []);
|
|
120
|
+
const message = camera === null ? "Scanning needs a newer version of the app. Type the code below." : granted === false ? "Yantra cannot use the camera. Type the code below, or allow the camera in Settings." : null;
|
|
121
|
+
return /* @__PURE__ */ jsxs(View, { style: styles.scanner, children: [
|
|
122
|
+
camera && granted ? /* @__PURE__ */ jsx(camera.CameraView, { style: StyleSheet.absoluteFill, barcodeScannerSettings: {
|
|
123
|
+
barcodeTypes: ["qr"]
|
|
124
|
+
}, onBarcodeScanned: ({
|
|
125
|
+
data
|
|
126
|
+
}) => {
|
|
127
|
+
if (scanned.current || !parsePairingCode(data)) return;
|
|
128
|
+
scanned.current = true;
|
|
129
|
+
onCode(data);
|
|
130
|
+
} }) : null,
|
|
131
|
+
message ? /* @__PURE__ */ jsx(Text, { style: styles.scannerText, children: message }) : null,
|
|
132
|
+
!message && !(camera && granted) ? /* @__PURE__ */ jsx(ActivityIndicator, { color: colors.surface }) : null
|
|
133
|
+
] });
|
|
134
|
+
}
|
|
135
|
+
function ComputerPanel({
|
|
136
|
+
colors
|
|
137
|
+
}) {
|
|
138
|
+
const api = useComputerLinkApi();
|
|
139
|
+
const [step, setStep] = useState("loading");
|
|
140
|
+
const [computers, setComputers] = useState([]);
|
|
141
|
+
const [tab, setTab] = useState("desktop");
|
|
142
|
+
const [typed, setTyped] = useState("");
|
|
143
|
+
const [offer, setOffer] = useState(null);
|
|
144
|
+
const [problem, setProblem] = useState(null);
|
|
145
|
+
const [busy, setBusy] = useState(false);
|
|
146
|
+
const [removingId, setRemovingId] = useState(null);
|
|
147
|
+
const baseline = useRef(0);
|
|
148
|
+
const stepRef = useRef(step);
|
|
149
|
+
stepRef.current = step;
|
|
150
|
+
const refresh = useCallback(async () => {
|
|
151
|
+
const rows = await api.list();
|
|
152
|
+
setComputers(rows);
|
|
153
|
+
const current = stepRef.current;
|
|
154
|
+
if (current === "loading") {
|
|
155
|
+
baseline.current = rows.length;
|
|
156
|
+
setStep(rows.length > 0 ? "list" : "install");
|
|
157
|
+
} else if (current === "install" && rows.length > baseline.current) {
|
|
158
|
+
setStep("list");
|
|
159
|
+
}
|
|
160
|
+
}, [api]);
|
|
161
|
+
useEffect(() => {
|
|
162
|
+
if (step !== "loading" && step !== "list" && step !== "install") return void 0;
|
|
163
|
+
let stopped = false;
|
|
164
|
+
const tick = () => {
|
|
165
|
+
refresh().then(() => {
|
|
166
|
+
if (!stopped) setProblem(null);
|
|
167
|
+
}, (err) => {
|
|
168
|
+
if (stopped) return;
|
|
169
|
+
setProblem(messageOf(err));
|
|
170
|
+
if (stepRef.current === "loading") setStep("install");
|
|
171
|
+
});
|
|
172
|
+
};
|
|
173
|
+
tick();
|
|
174
|
+
const timer = setInterval(tick, POLL_MS);
|
|
175
|
+
return () => {
|
|
176
|
+
stopped = true;
|
|
177
|
+
clearInterval(timer);
|
|
178
|
+
};
|
|
179
|
+
}, [step, refresh]);
|
|
180
|
+
const openInstall = useCallback(() => {
|
|
181
|
+
baseline.current = computers.length;
|
|
182
|
+
setProblem(null);
|
|
183
|
+
setStep("install");
|
|
184
|
+
}, [computers.length]);
|
|
185
|
+
const lookUp = useCallback(async (raw) => {
|
|
186
|
+
const code = parsePairingCode(raw);
|
|
187
|
+
if (!code) {
|
|
188
|
+
setProblem("That is not a pairing code. It looks like QRTX-4821.");
|
|
189
|
+
return;
|
|
190
|
+
}
|
|
191
|
+
setBusy(true);
|
|
192
|
+
setProblem(null);
|
|
193
|
+
try {
|
|
194
|
+
setOffer(__spreadProps(__spreadValues({}, await api.preview(code)), {
|
|
195
|
+
code
|
|
196
|
+
}));
|
|
197
|
+
setStep("confirm");
|
|
198
|
+
} catch (err) {
|
|
199
|
+
setProblem(messageOf(err));
|
|
200
|
+
} finally {
|
|
201
|
+
setBusy(false);
|
|
202
|
+
}
|
|
203
|
+
}, [api]);
|
|
204
|
+
const add = useCallback(async () => {
|
|
205
|
+
if (!offer) return;
|
|
206
|
+
setBusy(true);
|
|
207
|
+
setProblem(null);
|
|
208
|
+
try {
|
|
209
|
+
await api.claim(offer.code);
|
|
210
|
+
setOffer(null);
|
|
211
|
+
setTyped("");
|
|
212
|
+
setComputers(await api.list());
|
|
213
|
+
setStep("list");
|
|
214
|
+
} catch (err) {
|
|
215
|
+
setProblem(messageOf(err));
|
|
216
|
+
} finally {
|
|
217
|
+
setBusy(false);
|
|
218
|
+
}
|
|
219
|
+
}, [api, offer]);
|
|
220
|
+
const remove = useCallback((computer) => {
|
|
221
|
+
Alert.alert(`Remove ${computer.name}?`, "Yantra will no longer be able to reach this computer until you add it again.", [{
|
|
222
|
+
text: "Cancel",
|
|
223
|
+
style: "cancel"
|
|
224
|
+
}, {
|
|
225
|
+
text: "Remove",
|
|
226
|
+
style: "destructive",
|
|
227
|
+
onPress: () => {
|
|
228
|
+
setRemovingId(computer.id);
|
|
229
|
+
api.remove(computer.id).then(() => setComputers((rows) => rows.filter((row) => row.id !== computer.id))).catch((err) => setProblem(messageOf(err))).finally(() => setRemovingId(null));
|
|
230
|
+
}
|
|
231
|
+
}]);
|
|
232
|
+
}, [api]);
|
|
233
|
+
if (step === "loading") {
|
|
234
|
+
return /* @__PURE__ */ jsx(View, { style: styles.center, children: /* @__PURE__ */ jsx(ActivityIndicator, { color: colors.textMuted }) });
|
|
235
|
+
}
|
|
236
|
+
if (step === "list") {
|
|
237
|
+
return /* @__PURE__ */ jsxs(View, { style: styles.stack, children: [
|
|
238
|
+
computers.length === 0 ? /* @__PURE__ */ jsx(Text, { style: [styles.body, {
|
|
239
|
+
color: colors.textMuted
|
|
240
|
+
}], children: "No computers on your account yet." }) : null,
|
|
241
|
+
computers.map((computer) => /* @__PURE__ */ jsxs(View, { accessibilityLabel: `${computer.name}, ${computerStatusLabel(computer, Date.now())}`, style: [styles.computer, {
|
|
242
|
+
borderColor: colors.border
|
|
243
|
+
}], children: [
|
|
244
|
+
/* @__PURE__ */ jsx(ChannelIcon, { id: "computer", size: 24, ink: colors.text }),
|
|
245
|
+
/* @__PURE__ */ jsxs(View, { style: styles.flex, children: [
|
|
246
|
+
/* @__PURE__ */ jsx(Text, { numberOfLines: 1, style: [styles.strong, {
|
|
247
|
+
color: colors.text
|
|
248
|
+
}], children: computer.name }),
|
|
249
|
+
/* @__PURE__ */ jsxs(View, { style: styles.statusRow, children: [
|
|
250
|
+
/* @__PURE__ */ jsx(View, { style: [styles.dot, {
|
|
251
|
+
backgroundColor: computer.online ? colors.successText : colors.textMuted
|
|
252
|
+
}] }),
|
|
253
|
+
/* @__PURE__ */ jsx(Text, { style: [styles.caption, {
|
|
254
|
+
color: colors.textMuted
|
|
255
|
+
}], children: computerStatusLabel(computer, Date.now()) })
|
|
256
|
+
] })
|
|
257
|
+
] }),
|
|
258
|
+
/* @__PURE__ */ jsx(Pressable, { onPress: () => remove(computer), disabled: removingId === computer.id, hitSlop: 8, accessibilityRole: "button", accessibilityLabel: `Remove ${computer.name}`, children: removingId === computer.id ? /* @__PURE__ */ jsx(ActivityIndicator, { size: "small", color: colors.textMuted }) : /* @__PURE__ */ jsx(Text, { style: [styles.link, {
|
|
259
|
+
color: colors.dangerText
|
|
260
|
+
}], children: "Remove" }) })
|
|
261
|
+
] }, computer.id)),
|
|
262
|
+
computers.length > 0 ? /* @__PURE__ */ jsxs(Text, { style: [styles.caption, {
|
|
263
|
+
color: colors.textMuted
|
|
264
|
+
}], children: [
|
|
265
|
+
"In any chat, ask Yantra to do something on",
|
|
266
|
+
" ",
|
|
267
|
+
computers.length === 1 ? computers[0].name : "one of these",
|
|
268
|
+
". It asks here before each command."
|
|
269
|
+
] }) : null,
|
|
270
|
+
problem ? /* @__PURE__ */ jsx(Problem, { label: problem, colors }) : null,
|
|
271
|
+
/* @__PURE__ */ jsx(Action, { label: "Add another computer", tone: "line", colors, onPress: openInstall })
|
|
272
|
+
] });
|
|
273
|
+
}
|
|
274
|
+
if (step === "confirm" && offer) {
|
|
275
|
+
return /* @__PURE__ */ jsxs(View, { style: styles.stack, children: [
|
|
276
|
+
/* @__PURE__ */ jsx(Text, { style: [styles.heading, {
|
|
277
|
+
color: colors.text
|
|
278
|
+
}], children: "Is this your computer?" }),
|
|
279
|
+
/* @__PURE__ */ jsxs(View, { style: [styles.computer, {
|
|
280
|
+
borderColor: colors.border
|
|
281
|
+
}], children: [
|
|
282
|
+
/* @__PURE__ */ jsx(ChannelIcon, { id: "computer", size: 24, ink: colors.text }),
|
|
283
|
+
/* @__PURE__ */ jsxs(View, { style: styles.flex, children: [
|
|
284
|
+
/* @__PURE__ */ jsx(Text, { numberOfLines: 1, style: [styles.strong, {
|
|
285
|
+
color: colors.text
|
|
286
|
+
}], children: offer.name }),
|
|
287
|
+
offer.os ? /* @__PURE__ */ jsx(Text, { style: [styles.caption, {
|
|
288
|
+
color: colors.textMuted
|
|
289
|
+
}], children: offer.os }) : null
|
|
290
|
+
] })
|
|
291
|
+
] }),
|
|
292
|
+
/* @__PURE__ */ jsx(Text, { style: [styles.body, {
|
|
293
|
+
color: colors.textMuted
|
|
294
|
+
}], children: "Check that your computer shows this same number." }),
|
|
295
|
+
/* @__PURE__ */ jsx(Text, { accessibilityLabel: `Check number ${offer.check}`, style: [styles.check, {
|
|
296
|
+
color: colors.text
|
|
297
|
+
}], children: spacedCheck(offer.check) }),
|
|
298
|
+
problem ? /* @__PURE__ */ jsx(Problem, { label: problem, colors }) : null,
|
|
299
|
+
/* @__PURE__ */ jsx(Action, { label: "Add this computer", colors, busy, onPress: () => void add() }),
|
|
300
|
+
/* @__PURE__ */ jsx(Action, { label: "It doesn't match", tone: "line", colors, disabled: busy, onPress: () => {
|
|
301
|
+
setOffer(null);
|
|
302
|
+
setProblem(null);
|
|
303
|
+
setStep("pair");
|
|
304
|
+
} })
|
|
305
|
+
] });
|
|
306
|
+
}
|
|
307
|
+
if (step === "pair") {
|
|
308
|
+
return /* @__PURE__ */ jsxs(View, { style: styles.stack, children: [
|
|
309
|
+
/* @__PURE__ */ jsx(Text, { style: [styles.heading, {
|
|
310
|
+
color: colors.text
|
|
311
|
+
}], children: "Scan the pairing code" }),
|
|
312
|
+
/* @__PURE__ */ jsxs(Text, { style: [styles.body, {
|
|
313
|
+
color: colors.textMuted
|
|
314
|
+
}], children: [
|
|
315
|
+
"On your computer, run ",
|
|
316
|
+
CLI_PAIR_COMMAND,
|
|
317
|
+
" and point your phone at the code."
|
|
318
|
+
] }),
|
|
319
|
+
/* @__PURE__ */ jsx(Scanner, { colors, onCode: (raw) => void lookUp(raw) }),
|
|
320
|
+
/* @__PURE__ */ jsxs(View, { style: [styles.field, {
|
|
321
|
+
backgroundColor: colors.surfaceMuted
|
|
322
|
+
}], children: [
|
|
323
|
+
/* @__PURE__ */ jsx(TextInput, { value: typed, onChangeText: setTyped, placeholder: "Or type the code", placeholderTextColor: colors.textMuted, autoCapitalize: "characters", autoCorrect: false, returnKeyType: "go", onSubmitEditing: () => void lookUp(typed), accessibilityLabel: "Pairing code", style: [styles.input, {
|
|
324
|
+
color: colors.text
|
|
325
|
+
}] }),
|
|
326
|
+
/* @__PURE__ */ jsx(Pressable, { onPress: () => void lookUp(typed), disabled: busy || !typed.trim(), hitSlop: 8, accessibilityRole: "button", accessibilityLabel: "Look up this code", children: busy ? /* @__PURE__ */ jsx(ActivityIndicator, { size: "small", color: colors.textMuted }) : /* @__PURE__ */ jsx(MaterialCommunityIcons, { name: "arrow-right", size: 22, color: colors.textMuted }) })
|
|
327
|
+
] }),
|
|
328
|
+
problem ? /* @__PURE__ */ jsx(Problem, { label: problem, colors }) : null,
|
|
329
|
+
/* @__PURE__ */ jsx(Text, { style: [styles.caption, {
|
|
330
|
+
color: colors.textMuted
|
|
331
|
+
}], children: "Your computer connects out to Yantra, so it works from anywhere with nothing to open on your router." }),
|
|
332
|
+
/* @__PURE__ */ jsx(Action, { label: "Back", tone: "line", colors, onPress: () => {
|
|
333
|
+
setProblem(null);
|
|
334
|
+
setStep(computers.length > baseline.current ? "list" : "install");
|
|
335
|
+
} })
|
|
336
|
+
] });
|
|
337
|
+
}
|
|
338
|
+
return /* @__PURE__ */ jsxs(View, { style: styles.stack, children: [
|
|
339
|
+
/* @__PURE__ */ jsx(Text, { style: [styles.heading, {
|
|
340
|
+
color: colors.text
|
|
341
|
+
}], children: "Install Yantra on your computer" }),
|
|
342
|
+
/* @__PURE__ */ jsx(Text, { style: [styles.body, {
|
|
343
|
+
color: colors.textMuted
|
|
344
|
+
}], children: "Yantra works there when you ask. This phone is how you ask it." }),
|
|
345
|
+
/* @__PURE__ */ jsx(View, { style: [styles.tabs, {
|
|
346
|
+
backgroundColor: colors.surfaceMuted
|
|
347
|
+
}], children: [["desktop", "Mac app"], ["terminal", "Linux or server"]].map(([id, label]) => /* @__PURE__ */ jsx(Pressable, { onPress: () => setTab(id), accessibilityRole: "tab", accessibilityState: {
|
|
348
|
+
selected: tab === id
|
|
349
|
+
}, accessibilityLabel: label, style: [styles.tab, tab === id && {
|
|
350
|
+
backgroundColor: colors.surface
|
|
351
|
+
}], children: /* @__PURE__ */ jsx(Text, { style: [styles.tabLabel, {
|
|
352
|
+
color: tab === id ? colors.text : colors.textMuted
|
|
353
|
+
}], children: label }) }, id)) }),
|
|
354
|
+
tab === "desktop" ? /* @__PURE__ */ jsxs(View, { style: styles.stack, children: [
|
|
355
|
+
/* @__PURE__ */ jsx(Text, { style: [styles.caption, {
|
|
356
|
+
color: colors.textMuted
|
|
357
|
+
}], children: "Open this link on your Mac to download Yantra (Apple Silicon)" }),
|
|
358
|
+
/* @__PURE__ */ jsx(CopyRow, { label: "the download link", value: MAC_APP_URL, colors }),
|
|
359
|
+
/* @__PURE__ */ jsx(Text, { style: [styles.body, {
|
|
360
|
+
color: colors.textMuted
|
|
361
|
+
}], children: "Sign in there with this account and choose Allow, and it shows up here. Already have Yantra? Open Settings there and turn on Allow from my phone." })
|
|
362
|
+
] }) : /* @__PURE__ */ jsxs(View, { style: styles.stack, children: [
|
|
363
|
+
/* @__PURE__ */ jsx(Text, { style: [styles.caption, {
|
|
364
|
+
color: colors.textMuted
|
|
365
|
+
}], children: "Install the command line tool" }),
|
|
366
|
+
/* @__PURE__ */ jsx(CopyRow, { label: "the install command", value: CLI_INSTALL_COMMAND, colors }),
|
|
367
|
+
/* @__PURE__ */ jsx(Text, { style: [styles.caption, {
|
|
368
|
+
color: colors.textMuted
|
|
369
|
+
}], children: "Then show the pairing code" }),
|
|
370
|
+
/* @__PURE__ */ jsx(CopyRow, { label: "the pair command", value: CLI_PAIR_COMMAND, colors })
|
|
371
|
+
] }),
|
|
372
|
+
/* @__PURE__ */ jsxs(View, { style: styles.waiting, children: [
|
|
373
|
+
/* @__PURE__ */ jsx(ActivityIndicator, { size: "small", color: colors.textMuted }),
|
|
374
|
+
/* @__PURE__ */ jsx(Text, { style: [styles.caption, {
|
|
375
|
+
color: colors.textMuted
|
|
376
|
+
}], children: "Waiting for your computer" })
|
|
377
|
+
] }),
|
|
378
|
+
problem ? /* @__PURE__ */ jsx(Problem, { label: problem, colors }) : null,
|
|
379
|
+
/* @__PURE__ */ jsx(Action, { label: "I have a pairing code", tone: "line", colors, onPress: () => {
|
|
380
|
+
setProblem(null);
|
|
381
|
+
setStep("pair");
|
|
382
|
+
} })
|
|
383
|
+
] });
|
|
384
|
+
}
|
|
385
|
+
const styles = StyleSheet.create({
|
|
386
|
+
stack: {
|
|
387
|
+
gap: 10
|
|
388
|
+
},
|
|
389
|
+
center: {
|
|
390
|
+
paddingVertical: 32,
|
|
391
|
+
alignItems: "center"
|
|
392
|
+
},
|
|
393
|
+
flex: {
|
|
394
|
+
flex: 1,
|
|
395
|
+
minWidth: 0
|
|
396
|
+
},
|
|
397
|
+
dim: {
|
|
398
|
+
opacity: 0.6
|
|
399
|
+
},
|
|
400
|
+
heading: {
|
|
401
|
+
fontSize: 20,
|
|
402
|
+
fontWeight: "700",
|
|
403
|
+
lineHeight: 26
|
|
404
|
+
},
|
|
405
|
+
body: {
|
|
406
|
+
fontSize: 14,
|
|
407
|
+
lineHeight: 20
|
|
408
|
+
},
|
|
409
|
+
caption: {
|
|
410
|
+
fontSize: 12,
|
|
411
|
+
lineHeight: 16
|
|
412
|
+
},
|
|
413
|
+
strong: {
|
|
414
|
+
fontSize: 15,
|
|
415
|
+
fontWeight: "600"
|
|
416
|
+
},
|
|
417
|
+
link: {
|
|
418
|
+
fontSize: 13,
|
|
419
|
+
fontWeight: "600"
|
|
420
|
+
},
|
|
421
|
+
check: {
|
|
422
|
+
fontSize: 34,
|
|
423
|
+
fontWeight: "700",
|
|
424
|
+
letterSpacing: 2,
|
|
425
|
+
textAlign: "center",
|
|
426
|
+
paddingVertical: 6
|
|
427
|
+
},
|
|
428
|
+
action: {
|
|
429
|
+
flexDirection: "row",
|
|
430
|
+
alignItems: "center",
|
|
431
|
+
justifyContent: "center",
|
|
432
|
+
gap: 8,
|
|
433
|
+
minHeight: 44,
|
|
434
|
+
paddingHorizontal: 16,
|
|
435
|
+
borderRadius: 12
|
|
436
|
+
},
|
|
437
|
+
actionLabel: {
|
|
438
|
+
fontSize: 14,
|
|
439
|
+
fontWeight: "600"
|
|
440
|
+
},
|
|
441
|
+
note: {
|
|
442
|
+
flexDirection: "row",
|
|
443
|
+
alignItems: "center",
|
|
444
|
+
gap: 8,
|
|
445
|
+
padding: 12,
|
|
446
|
+
borderRadius: 12
|
|
447
|
+
},
|
|
448
|
+
noteText: {
|
|
449
|
+
flex: 1,
|
|
450
|
+
fontSize: 13,
|
|
451
|
+
lineHeight: 18
|
|
452
|
+
},
|
|
453
|
+
copy: {
|
|
454
|
+
flexDirection: "row",
|
|
455
|
+
alignItems: "center",
|
|
456
|
+
gap: 10,
|
|
457
|
+
minHeight: 44,
|
|
458
|
+
padding: 12,
|
|
459
|
+
borderRadius: 12
|
|
460
|
+
},
|
|
461
|
+
copyText: {
|
|
462
|
+
flex: 1,
|
|
463
|
+
fontSize: 12,
|
|
464
|
+
lineHeight: 17,
|
|
465
|
+
fontFamily: "Courier"
|
|
466
|
+
},
|
|
467
|
+
computer: {
|
|
468
|
+
flexDirection: "row",
|
|
469
|
+
alignItems: "center",
|
|
470
|
+
gap: 12,
|
|
471
|
+
padding: 12,
|
|
472
|
+
borderRadius: 12,
|
|
473
|
+
borderWidth: 1
|
|
474
|
+
},
|
|
475
|
+
statusRow: {
|
|
476
|
+
flexDirection: "row",
|
|
477
|
+
alignItems: "center",
|
|
478
|
+
gap: 6,
|
|
479
|
+
marginTop: 2
|
|
480
|
+
},
|
|
481
|
+
dot: {
|
|
482
|
+
width: 7,
|
|
483
|
+
height: 7,
|
|
484
|
+
borderRadius: 4
|
|
485
|
+
},
|
|
486
|
+
scanner: {
|
|
487
|
+
height: 220,
|
|
488
|
+
borderRadius: 16,
|
|
489
|
+
overflow: "hidden",
|
|
490
|
+
backgroundColor: "#111",
|
|
491
|
+
alignItems: "center",
|
|
492
|
+
justifyContent: "center",
|
|
493
|
+
padding: 20
|
|
494
|
+
},
|
|
495
|
+
scannerText: {
|
|
496
|
+
color: "#fff",
|
|
497
|
+
fontSize: 13,
|
|
498
|
+
lineHeight: 18,
|
|
499
|
+
textAlign: "center"
|
|
500
|
+
},
|
|
501
|
+
field: {
|
|
502
|
+
flexDirection: "row",
|
|
503
|
+
alignItems: "center",
|
|
504
|
+
gap: 10,
|
|
505
|
+
minHeight: 48,
|
|
506
|
+
paddingHorizontal: 14,
|
|
507
|
+
borderRadius: 12
|
|
508
|
+
},
|
|
509
|
+
input: {
|
|
510
|
+
flex: 1,
|
|
511
|
+
fontSize: 15,
|
|
512
|
+
fontFamily: "Courier",
|
|
513
|
+
paddingVertical: 10
|
|
514
|
+
},
|
|
515
|
+
tabs: {
|
|
516
|
+
flexDirection: "row",
|
|
517
|
+
padding: 3,
|
|
518
|
+
borderRadius: 12
|
|
519
|
+
},
|
|
520
|
+
tab: {
|
|
521
|
+
flex: 1,
|
|
522
|
+
alignItems: "center",
|
|
523
|
+
justifyContent: "center",
|
|
524
|
+
minHeight: 36,
|
|
525
|
+
borderRadius: 10
|
|
526
|
+
},
|
|
527
|
+
tabLabel: {
|
|
528
|
+
fontSize: 13,
|
|
529
|
+
fontWeight: "600"
|
|
530
|
+
},
|
|
531
|
+
waiting: {
|
|
532
|
+
flexDirection: "row",
|
|
533
|
+
alignItems: "center",
|
|
534
|
+
justifyContent: "center",
|
|
535
|
+
gap: 8,
|
|
536
|
+
paddingVertical: 4
|
|
537
|
+
}
|
|
538
|
+
});export{ComputerPanel};//# sourceMappingURL=ComputerPanel.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ComputerPanel.js","sources":["../../../src/features/channels/ComputerPanel.tsx"],"sourcesContent":["/**\n * Connect apps > Computer: install Yantra on a computer and it shows up here, or pair one that has\n * no desktop app by scanning or typing its code. A paired computer is one more Computer the agent\n * can use, and it asks here before each command (the chat's approval card).\n */\nimport React, { useCallback, useEffect, useRef, useState } from 'react';\nimport {\n ActivityIndicator,\n Alert,\n Clipboard,\n Pressable,\n StyleSheet,\n Text,\n TextInput,\n View,\n} from 'react-native';\nimport { MaterialCommunityIcons } from '@expo/vector-icons';\nimport type { mobileColors } from '../../theme/mobileTokens';\nimport { ChannelIcon } from './ChannelIcon';\nimport {\n CLI_INSTALL_COMMAND,\n CLI_PAIR_COMMAND,\n MAC_APP_URL,\n computerStatusLabel,\n parsePairingCode,\n spacedCheck,\n useComputerLinkApi,\n type ComputerOffer,\n type LinkedComputer,\n} from './computerLink';\n\ntype Colors = ReturnType<typeof mobileColors>;\ntype Step = 'loading' | 'list' | 'install' | 'pair' | 'confirm';\ntype InstallTab = 'desktop' | 'terminal';\n\nconst POLL_MS = 3000;\nconst COPIED_MS = 1800;\n\nfunction messageOf(err: unknown): string {\n return err instanceof Error && err.message ? err.message : 'Something went wrong. Please try again.';\n}\n\nfunction Action({\n label,\n colors,\n onPress,\n tone = 'primary',\n busy,\n disabled,\n}: {\n label: string;\n colors: Colors;\n onPress: () => void;\n tone?: 'primary' | 'line';\n busy?: boolean;\n disabled?: boolean;\n}) {\n const filled = tone === 'primary';\n const ink = filled ? '#fff' : colors.text;\n return (\n <Pressable\n onPress={onPress}\n disabled={disabled || busy}\n accessibilityRole=\"button\"\n accessibilityLabel={label}\n style={({ pressed }) => [\n styles.action,\n filled ? { backgroundColor: colors.primary } : { borderColor: colors.border, borderWidth: 1 },\n (pressed || disabled) && styles.dim,\n ]}\n >\n {busy ? <ActivityIndicator size=\"small\" color={ink} /> : null}\n <Text style={[styles.actionLabel, { color: ink }]}>{label}</Text>\n </Pressable>\n );\n}\n\nfunction Problem({ label, colors }: { label: string; colors: Colors }) {\n return (\n <View accessibilityRole=\"alert\" style={[styles.note, { backgroundColor: colors.dangerSoft }]}>\n <MaterialCommunityIcons name=\"alert-circle-outline\" size={16} color={colors.dangerText} />\n <Text style={[styles.noteText, { color: colors.dangerText }]}>{label}</Text>\n </View>\n );\n}\n\nfunction CopyRow({ label, value, colors }: { label: string; value: string; colors: Colors }) {\n const [copied, setCopied] = useState(false);\n const timer = useRef<ReturnType<typeof setTimeout> | null>(null);\n useEffect(\n () => () => {\n if (timer.current) clearTimeout(timer.current);\n },\n [],\n );\n return (\n <Pressable\n onPress={() => {\n Clipboard.setString(value);\n setCopied(true);\n if (timer.current) clearTimeout(timer.current);\n timer.current = setTimeout(() => setCopied(false), COPIED_MS);\n }}\n accessibilityRole=\"button\"\n accessibilityLabel={`Copy ${label}`}\n style={({ pressed }) => [styles.copy, { backgroundColor: colors.surfaceMuted }, pressed && styles.dim]}\n >\n <Text style={[styles.copyText, { color: colors.text }]} selectable>\n {value}\n </Text>\n <MaterialCommunityIcons\n name={copied ? 'check' : 'content-copy'}\n size={18}\n color={copied ? colors.successText : colors.textMuted}\n />\n </Pressable>\n );\n}\n\ntype CameraModule = {\n CameraView: React.ComponentType<Record<string, unknown>>;\n Camera: { requestCameraPermissionsAsync: () => Promise<{ granted: boolean }> };\n};\n\n/** Loaded on demand: an update reaching an older app build must not crash on a missing camera module. */\nasync function loadCamera(): Promise<CameraModule | null> {\n try {\n // @ts-ignore - provided by the app binary\n return (await import('expo-camera')) as unknown as CameraModule;\n } catch {\n return null;\n }\n}\n\nfunction Scanner({ colors, onCode }: { colors: Colors; onCode: (raw: string) => void }) {\n const [camera, setCamera] = useState<CameraModule | null | undefined>(undefined);\n const [granted, setGranted] = useState<boolean | null>(null);\n const scanned = useRef(false);\n\n useEffect(() => {\n let cancelled = false;\n void (async () => {\n const loaded = await loadCamera();\n if (cancelled) return;\n setCamera(loaded);\n if (!loaded) return;\n try {\n const answer = await loaded.Camera.requestCameraPermissionsAsync();\n if (!cancelled) setGranted(answer.granted);\n } catch {\n if (!cancelled) setCamera(null);\n }\n })();\n return () => {\n cancelled = true;\n };\n }, []);\n\n const message =\n camera === null\n ? 'Scanning needs a newer version of the app. Type the code below.'\n : granted === false\n ? 'Yantra cannot use the camera. Type the code below, or allow the camera in Settings.'\n : null;\n\n return (\n <View style={styles.scanner}>\n {camera && granted ? (\n <camera.CameraView\n style={StyleSheet.absoluteFill}\n barcodeScannerSettings={{ barcodeTypes: ['qr'] }}\n onBarcodeScanned={({ data }: { data: string }) => {\n if (scanned.current || !parsePairingCode(data)) return;\n scanned.current = true;\n onCode(data);\n }}\n />\n ) : null}\n {message ? <Text style={styles.scannerText}>{message}</Text> : null}\n {!message && !(camera && granted) ? <ActivityIndicator color={colors.surface} /> : null}\n </View>\n );\n}\n\nexport function ComputerPanel({ colors }: { colors: Colors }) {\n const api = useComputerLinkApi();\n const [step, setStep] = useState<Step>('loading');\n const [computers, setComputers] = useState<LinkedComputer[]>([]);\n const [tab, setTab] = useState<InstallTab>('desktop');\n const [typed, setTyped] = useState('');\n const [offer, setOffer] = useState<(ComputerOffer & { code: string }) | null>(null);\n const [problem, setProblem] = useState<string | null>(null);\n const [busy, setBusy] = useState(false);\n const [removingId, setRemovingId] = useState<string | null>(null);\n /** How many computers there were when the install screen opened: one more means it worked. */\n const baseline = useRef(0);\n const stepRef = useRef(step);\n stepRef.current = step;\n\n const refresh = useCallback(async () => {\n const rows = await api.list();\n setComputers(rows);\n const current = stepRef.current;\n if (current === 'loading') {\n baseline.current = rows.length;\n setStep(rows.length > 0 ? 'list' : 'install');\n } else if (current === 'install' && rows.length > baseline.current) {\n setStep('list');\n }\n }, [api]);\n\n useEffect(() => {\n if (step !== 'loading' && step !== 'list' && step !== 'install') return undefined;\n let stopped = false;\n const tick = () => {\n refresh().then(\n () => {\n if (!stopped) setProblem(null);\n },\n (err) => {\n if (stopped) return;\n setProblem(messageOf(err));\n if (stepRef.current === 'loading') setStep('install');\n },\n );\n };\n tick();\n const timer = setInterval(tick, POLL_MS);\n return () => {\n stopped = true;\n clearInterval(timer);\n };\n }, [step, refresh]);\n\n const openInstall = useCallback(() => {\n baseline.current = computers.length;\n setProblem(null);\n setStep('install');\n }, [computers.length]);\n\n const lookUp = useCallback(\n async (raw: string) => {\n const code = parsePairingCode(raw);\n if (!code) {\n setProblem('That is not a pairing code. It looks like QRTX-4821.');\n return;\n }\n setBusy(true);\n setProblem(null);\n try {\n setOffer({ ...(await api.preview(code)), code });\n setStep('confirm');\n } catch (err) {\n setProblem(messageOf(err));\n } finally {\n setBusy(false);\n }\n },\n [api],\n );\n\n const add = useCallback(async () => {\n if (!offer) return;\n setBusy(true);\n setProblem(null);\n try {\n await api.claim(offer.code);\n setOffer(null);\n setTyped('');\n setComputers(await api.list());\n setStep('list');\n } catch (err) {\n setProblem(messageOf(err));\n } finally {\n setBusy(false);\n }\n }, [api, offer]);\n\n const remove = useCallback(\n (computer: LinkedComputer) => {\n Alert.alert(\n `Remove ${computer.name}?`,\n 'Yantra will no longer be able to reach this computer until you add it again.',\n [\n { text: 'Cancel', style: 'cancel' },\n {\n text: 'Remove',\n style: 'destructive',\n onPress: () => {\n setRemovingId(computer.id);\n api.remove(computer.id)\n .then(() => setComputers((rows) => rows.filter((row) => row.id !== computer.id)))\n .catch((err) => setProblem(messageOf(err)))\n .finally(() => setRemovingId(null));\n },\n },\n ],\n );\n },\n [api],\n );\n\n if (step === 'loading') {\n return (\n <View style={styles.center}>\n <ActivityIndicator color={colors.textMuted} />\n </View>\n );\n }\n\n if (step === 'list') {\n return (\n <View style={styles.stack}>\n {computers.length === 0 ? (\n <Text style={[styles.body, { color: colors.textMuted }]}>No computers on your account yet.</Text>\n ) : null}\n {computers.map((computer) => (\n <View\n key={computer.id}\n accessibilityLabel={`${computer.name}, ${computerStatusLabel(computer, Date.now())}`}\n style={[styles.computer, { borderColor: colors.border }]}\n >\n <ChannelIcon id=\"computer\" size={24} ink={colors.text} />\n <View style={styles.flex}>\n <Text numberOfLines={1} style={[styles.strong, { color: colors.text }]}>\n {computer.name}\n </Text>\n <View style={styles.statusRow}>\n <View\n style={[\n styles.dot,\n { backgroundColor: computer.online ? colors.successText : colors.textMuted },\n ]}\n />\n <Text style={[styles.caption, { color: colors.textMuted }]}>\n {computerStatusLabel(computer, Date.now())}\n </Text>\n </View>\n </View>\n <Pressable\n onPress={() => remove(computer)}\n disabled={removingId === computer.id}\n hitSlop={8}\n accessibilityRole=\"button\"\n accessibilityLabel={`Remove ${computer.name}`}\n >\n {removingId === computer.id ? (\n <ActivityIndicator size=\"small\" color={colors.textMuted} />\n ) : (\n <Text style={[styles.link, { color: colors.dangerText }]}>Remove</Text>\n )}\n </Pressable>\n </View>\n ))}\n {computers.length > 0 ? (\n <Text style={[styles.caption, { color: colors.textMuted }]}>\n In any chat, ask Yantra to do something on{' '}\n {computers.length === 1 ? computers[0].name : 'one of these'}. It asks here before each command.\n </Text>\n ) : null}\n {problem ? <Problem label={problem} colors={colors} /> : null}\n <Action label=\"Add another computer\" tone=\"line\" colors={colors} onPress={openInstall} />\n </View>\n );\n }\n\n if (step === 'confirm' && offer) {\n return (\n <View style={styles.stack}>\n <Text style={[styles.heading, { color: colors.text }]}>Is this your computer?</Text>\n <View style={[styles.computer, { borderColor: colors.border }]}>\n <ChannelIcon id=\"computer\" size={24} ink={colors.text} />\n <View style={styles.flex}>\n <Text numberOfLines={1} style={[styles.strong, { color: colors.text }]}>\n {offer.name}\n </Text>\n {offer.os ? <Text style={[styles.caption, { color: colors.textMuted }]}>{offer.os}</Text> : null}\n </View>\n </View>\n <Text style={[styles.body, { color: colors.textMuted }]}>\n Check that your computer shows this same number.\n </Text>\n <Text accessibilityLabel={`Check number ${offer.check}`} style={[styles.check, { color: colors.text }]}>\n {spacedCheck(offer.check)}\n </Text>\n {problem ? <Problem label={problem} colors={colors} /> : null}\n <Action label=\"Add this computer\" colors={colors} busy={busy} onPress={() => void add()} />\n <Action\n label=\"It doesn't match\"\n tone=\"line\"\n colors={colors}\n disabled={busy}\n onPress={() => {\n setOffer(null);\n setProblem(null);\n setStep('pair');\n }}\n />\n </View>\n );\n }\n\n if (step === 'pair') {\n return (\n <View style={styles.stack}>\n <Text style={[styles.heading, { color: colors.text }]}>Scan the pairing code</Text>\n <Text style={[styles.body, { color: colors.textMuted }]}>\n On your computer, run {CLI_PAIR_COMMAND} and point your phone at the code.\n </Text>\n <Scanner colors={colors} onCode={(raw) => void lookUp(raw)} />\n <View style={[styles.field, { backgroundColor: colors.surfaceMuted }]}>\n <TextInput\n value={typed}\n onChangeText={setTyped}\n placeholder=\"Or type the code\"\n placeholderTextColor={colors.textMuted}\n autoCapitalize=\"characters\"\n autoCorrect={false}\n returnKeyType=\"go\"\n onSubmitEditing={() => void lookUp(typed)}\n accessibilityLabel=\"Pairing code\"\n style={[styles.input, { color: colors.text }]}\n />\n <Pressable\n onPress={() => void lookUp(typed)}\n disabled={busy || !typed.trim()}\n hitSlop={8}\n accessibilityRole=\"button\"\n accessibilityLabel=\"Look up this code\"\n >\n {busy ? (\n <ActivityIndicator size=\"small\" color={colors.textMuted} />\n ) : (\n <MaterialCommunityIcons name=\"arrow-right\" size={22} color={colors.textMuted} />\n )}\n </Pressable>\n </View>\n {problem ? <Problem label={problem} colors={colors} /> : null}\n <Text style={[styles.caption, { color: colors.textMuted }]}>\n Your computer connects out to Yantra, so it works from anywhere with nothing to open on your router.\n </Text>\n <Action\n label=\"Back\"\n tone=\"line\"\n colors={colors}\n onPress={() => {\n setProblem(null);\n setStep(computers.length > baseline.current ? 'list' : 'install');\n }}\n />\n </View>\n );\n }\n\n return (\n <View style={styles.stack}>\n <Text style={[styles.heading, { color: colors.text }]}>Install Yantra on your computer</Text>\n <Text style={[styles.body, { color: colors.textMuted }]}>\n Yantra works there when you ask. This phone is how you ask it.\n </Text>\n <View style={[styles.tabs, { backgroundColor: colors.surfaceMuted }]}>\n {(\n [\n ['desktop', 'Mac app'],\n ['terminal', 'Linux or server'],\n ] as const\n ).map(([id, label]) => (\n <Pressable\n key={id}\n onPress={() => setTab(id)}\n accessibilityRole=\"tab\"\n accessibilityState={{ selected: tab === id }}\n accessibilityLabel={label}\n style={[styles.tab, tab === id && { backgroundColor: colors.surface }]}\n >\n <Text style={[styles.tabLabel, { color: tab === id ? colors.text : colors.textMuted }]}>\n {label}\n </Text>\n </Pressable>\n ))}\n </View>\n {tab === 'desktop' ? (\n <View style={styles.stack}>\n <Text style={[styles.caption, { color: colors.textMuted }]}>\n Open this link on your Mac to download Yantra (Apple Silicon)\n </Text>\n <CopyRow label=\"the download link\" value={MAC_APP_URL} colors={colors} />\n <Text style={[styles.body, { color: colors.textMuted }]}>\n Sign in there with this account and choose Allow, and it shows up here. Already have Yantra? Open\n Settings there and turn on Allow from my phone.\n </Text>\n </View>\n ) : (\n <View style={styles.stack}>\n <Text style={[styles.caption, { color: colors.textMuted }]}>Install the command line tool</Text>\n <CopyRow label=\"the install command\" value={CLI_INSTALL_COMMAND} colors={colors} />\n <Text style={[styles.caption, { color: colors.textMuted }]}>Then show the pairing code</Text>\n <CopyRow label=\"the pair command\" value={CLI_PAIR_COMMAND} colors={colors} />\n </View>\n )}\n <View style={styles.waiting}>\n <ActivityIndicator size=\"small\" color={colors.textMuted} />\n <Text style={[styles.caption, { color: colors.textMuted }]}>Waiting for your computer</Text>\n </View>\n {problem ? <Problem label={problem} colors={colors} /> : null}\n <Action\n label=\"I have a pairing code\"\n tone=\"line\"\n colors={colors}\n onPress={() => {\n setProblem(null);\n setStep('pair');\n }}\n />\n </View>\n );\n}\n\nconst styles = StyleSheet.create({\n stack: { gap: 10 },\n center: { paddingVertical: 32, alignItems: 'center' },\n flex: { flex: 1, minWidth: 0 },\n dim: { opacity: 0.6 },\n heading: { fontSize: 20, fontWeight: '700', lineHeight: 26 },\n body: { fontSize: 14, lineHeight: 20 },\n caption: { fontSize: 12, lineHeight: 16 },\n strong: { fontSize: 15, fontWeight: '600' },\n link: { fontSize: 13, fontWeight: '600' },\n check: { fontSize: 34, fontWeight: '700', letterSpacing: 2, textAlign: 'center', paddingVertical: 6 },\n action: {\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'center',\n gap: 8,\n minHeight: 44,\n paddingHorizontal: 16,\n borderRadius: 12,\n },\n actionLabel: { fontSize: 14, fontWeight: '600' },\n note: { flexDirection: 'row', alignItems: 'center', gap: 8, padding: 12, borderRadius: 12 },\n noteText: { flex: 1, fontSize: 13, lineHeight: 18 },\n copy: { flexDirection: 'row', alignItems: 'center', gap: 10, minHeight: 44, padding: 12, borderRadius: 12 },\n copyText: { flex: 1, fontSize: 12, lineHeight: 17, fontFamily: 'Courier' },\n computer: { flexDirection: 'row', alignItems: 'center', gap: 12, padding: 12, borderRadius: 12, borderWidth: 1 },\n statusRow: { flexDirection: 'row', alignItems: 'center', gap: 6, marginTop: 2 },\n dot: { width: 7, height: 7, borderRadius: 4 },\n scanner: {\n height: 220,\n borderRadius: 16,\n overflow: 'hidden',\n backgroundColor: '#111',\n alignItems: 'center',\n justifyContent: 'center',\n padding: 20,\n },\n scannerText: { color: '#fff', fontSize: 13, lineHeight: 18, textAlign: 'center' },\n field: { flexDirection: 'row', alignItems: 'center', gap: 10, minHeight: 48, paddingHorizontal: 14, borderRadius: 12 },\n input: { flex: 1, fontSize: 15, fontFamily: 'Courier', paddingVertical: 10 },\n tabs: { flexDirection: 'row', padding: 3, borderRadius: 12 },\n tab: { flex: 1, alignItems: 'center', justifyContent: 'center', minHeight: 36, borderRadius: 10 },\n tabLabel: { fontSize: 13, fontWeight: '600' },\n waiting: { flexDirection: 'row', alignItems: 'center', justifyContent: 'center', gap: 8, paddingVertical: 4 },\n});\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;AAcA,MAAM,OAAU,GAAA,GAAA;AAChB,MAAM,SAAY,GAAA,IAAA;AAClB,SAAS,UAAU,GAAsB,EAAA;AACvC,EAAA,OAAO,GAAe,YAAA,KAAA,IAAS,GAAI,CAAA,OAAA,GAAU,IAAI,OAAU,GAAA,yCAAA;AAC7D;AACA,SAAS,MAAO,CAAA;AAAA,EACd,KAAA;AAAA,EACA,MAAA;AAAA,EACA,OAAA;AAAA,EACA,IAAO,GAAA,SAAA;AAAA,EACP,IAAA;AAAA,EACA;AACF,CAOG,EAAA;AACD,EAAA,MAAM,SAAS,IAAS,KAAA,SAAA;AACxB,EAAM,MAAA,GAAA,GAAM,MAAS,GAAA,MAAA,GAAS,MAAO,CAAA,IAAA;AACrC,EAAO,uBAAA,IAAA,CAAC,SAAU,EAAA,EAAA,OAAA,EAAkB,QAAU,EAAA,QAAA,IAAY,IAAM,EAAA,iBAAA,EAAkB,QAAS,EAAA,kBAAA,EAAoB,KAAO,EAAA,KAAA,EAAO,CAAC;AAAA,IAC5H;AAAA,GACI,KAAA,CAAC,MAAO,CAAA,MAAA,EAAQ,MAAS,GAAA;AAAA,IAC7B,iBAAiB,MAAO,CAAA;AAAA,GACtB,GAAA;AAAA,IACF,aAAa,MAAO,CAAA,MAAA;AAAA,IACpB,WAAa,EAAA;AAAA,GACX,EAAA,CAAA,OAAA,IAAW,QAAa,KAAA,MAAA,CAAO,GAAG,CAC3B,EAAA,QAAA,EAAA;AAAA,IAAA,IAAA,uBAAQ,iBAAkB,EAAA,EAAA,IAAA,EAAK,OAAQ,EAAA,KAAA,EAAO,KAAK,CAAK,GAAA,IAAA;AAAA,oBACxD,GAAA,CAAA,IAAA,EAAA,EAAK,KAAO,EAAA,CAAC,OAAO,WA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';import {useState,useEffect,useRef,useCallback,useMemo}from'react';import {StyleSheet,Modal,View,Pressable,Text,Platform,ScrollView,ActivityIndicator,Linking,Image}from'react-native';import {MaterialCommunityIcons}from'@expo/vector-icons';import {useSafeAreaInsets}from'react-native-safe-area-context';import*as WebBrowser from'expo-web-browser';import {mobileColors}from'../../theme/mobileTokens.js';import {ChannelIcon}from'./ChannelIcon.js';import {CHANNELS,channelDisplay,planFirstMessage,buildWhatsAppHref,buildImessageHref,pairingRefusalMessage,AGENTS,qrImageUrl,expiryLabel}from'./channelLinks.js';import {useChannelBindings,useMessagesRecipient,useWhatsAppRecipient,useChannelActions,usePairingWatcher}from'./useChannelsApi.js';var __defProp = Object.defineProperty;
|
|
1
|
+
import {jsx,jsxs,Fragment}from'react/jsx-runtime';import {useState,useEffect,useRef,useCallback,useMemo}from'react';import {StyleSheet,Modal,View,Pressable,Text,Platform,ScrollView,ActivityIndicator,Linking,Image}from'react-native';import {MaterialCommunityIcons}from'@expo/vector-icons';import {useSafeAreaInsets}from'react-native-safe-area-context';import*as WebBrowser from'expo-web-browser';import {mobileColors}from'../../theme/mobileTokens.js';import {ChannelIcon}from'./ChannelIcon.js';import {ComputerPanel}from'./ComputerPanel.js';import {CHANNELS,channelDisplay,planFirstMessage,buildWhatsAppHref,buildImessageHref,pairingRefusalMessage,AGENTS,qrImageUrl,expiryLabel}from'./channelLinks.js';import {useChannelBindings,useMessagesRecipient,useWhatsAppRecipient,useChannelActions,usePairingWatcher}from'./useChannelsApi.js';var __defProp = Object.defineProperty;
|
|
2
2
|
var __defProps = Object.defineProperties;
|
|
3
3
|
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
4
4
|
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
@@ -555,7 +555,8 @@ function ConnectAppsSheet({
|
|
|
555
555
|
}) : null,
|
|
556
556
|
(panelProps == null ? void 0 : panelProps.channel.flow) === "agents" ? /* @__PURE__ */ jsx(AgentsPanel, __spreadValues({}, panelProps), panelProps.channel.id) : null,
|
|
557
557
|
(panelProps == null ? void 0 : panelProps.channel.flow) === "pairing" ? /* @__PURE__ */ jsx(PairingPanel, __spreadValues({}, panelProps), panelProps.channel.id) : null,
|
|
558
|
-
(panelProps == null ? void 0 : panelProps.channel.flow) === "oauth" ? /* @__PURE__ */ jsx(OAuthPanel, __spreadValues({}, panelProps), panelProps.channel.id) : null
|
|
558
|
+
(panelProps == null ? void 0 : panelProps.channel.flow) === "oauth" ? /* @__PURE__ */ jsx(OAuthPanel, __spreadValues({}, panelProps), panelProps.channel.id) : null,
|
|
559
|
+
(panelProps == null ? void 0 : panelProps.channel.flow) === "computer" ? /* @__PURE__ */ jsx(ComputerPanel, { colors }) : null
|
|
559
560
|
] })
|
|
560
561
|
] })
|
|
561
562
|
] }) });
|