skydive-cli 0.1.0-beta.109 → 0.1.0-beta.163
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/dist/js/bin.mjs +947 -19
- package/dist/js/{boot-DRWra2vY.mjs → boot-B-eA8M6t.mjs} +12 -39
- package/package.json +1 -1
- package/dist/js/print-CQ8b7JUC.mjs +0 -745
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import { a as
|
|
3
|
-
import { _ as getSavedTheme, a as noColorRequested, c as themeMode, d as themesForMode, f as getActiveWorkspaceId, g as DEFAULT_APP_URL, h as DEFAULT_API_URL, i as monoTheme, l as themeModeFromColorFgBg, m as setActiveWorkspace, n as applyTheme, o as theme, p as listWorkspaces, r as findTheme, s as themeForMode, t as DEFAULT_THEME_ID, u as themeVersion, v as resolveWebUrl, y as saveTheme } from "./bin.mjs";
|
|
2
|
+
import { A as resolveWebUrl, C as themesForMode, D as DEFAULT_API_URL, E as setActiveWorkspace, O as DEFAULT_APP_URL, S as themeVersion, T as listWorkspaces, _ as noColorRequested, a as parseOauthConnectParams, b as themeMode, c as parseConnectCard, d as HttpError, f as createRestClient, g as monoTheme, h as findTheme, i as parseExternalOauthConnectParams, j as saveTheme, k as getSavedTheme, l as errorMessage, m as applyTheme, n as MASK_CHAR, o as reconcileMaskedInput, p as DEFAULT_THEME_ID, r as cardActionErrorMessage, s as resolveConnectUrl, t as resolveAgent, u as isRecord, v as theme, w as getActiveWorkspaceId, x as themeModeFromColorFgBg, y as themeForMode } from "./bin.mjs";
|
|
4
3
|
import path, { basename, isAbsolute, join, win32 } from "node:path";
|
|
5
4
|
import { z } from "zod";
|
|
6
5
|
import open from "open";
|
|
@@ -509,7 +508,7 @@ var PortalClient = class {
|
|
|
509
508
|
this.setStatus("error", errorMessage(err));
|
|
510
509
|
}
|
|
511
510
|
if (!this.enabled || this.disposed) break;
|
|
512
|
-
await sleep
|
|
511
|
+
await sleep(backoff);
|
|
513
512
|
backoff = Math.min(backoff * 2, MAX_BACKOFF_MS);
|
|
514
513
|
}
|
|
515
514
|
}
|
|
@@ -555,7 +554,7 @@ var PortalClient = class {
|
|
|
555
554
|
for (let attempt = 0; attempt < 10; attempt += 1) {
|
|
556
555
|
await this.refreshDevice();
|
|
557
556
|
if (this.deviceId) return this.deviceId;
|
|
558
|
-
await sleep
|
|
557
|
+
await sleep(300);
|
|
559
558
|
}
|
|
560
559
|
throw new Error("this machine is not connected yet");
|
|
561
560
|
}
|
|
@@ -591,7 +590,7 @@ function toBuffer(data) {
|
|
|
591
590
|
function shortBody(res) {
|
|
592
591
|
return res.text().then((text) => text.slice(0, 120)).catch(() => "");
|
|
593
592
|
}
|
|
594
|
-
function sleep
|
|
593
|
+
function sleep(ms) {
|
|
595
594
|
return new Promise((resolve) => setTimeout(resolve, ms));
|
|
596
595
|
}
|
|
597
596
|
|
|
@@ -4640,9 +4639,6 @@ function ThemePicker({ onClose }) {
|
|
|
4640
4639
|
|
|
4641
4640
|
//#endregion
|
|
4642
4641
|
//#region src/chat/tui/screens/chat.tsx
|
|
4643
|
-
function sleep(ms) {
|
|
4644
|
-
return new Promise((resolve) => setTimeout(resolve, ms));
|
|
4645
|
-
}
|
|
4646
4642
|
/**
|
|
4647
4643
|
* Composer key bindings: Enter sends the message (matching the rest of the
|
|
4648
4644
|
* app), Shift+Enter inserts a hard newline. Everything else falls back to the
|
|
@@ -4859,41 +4855,18 @@ function ChatScreen({ agent, conversation }) {
|
|
|
4859
4855
|
]);
|
|
4860
4856
|
useEffect(() => {
|
|
4861
4857
|
if (!rest || !conversationId) return;
|
|
4862
|
-
|
|
4863
|
-
|
|
4864
|
-
|
|
4865
|
-
|
|
4866
|
-
|
|
4867
|
-
|
|
4868
|
-
1500,
|
|
4869
|
-
2500,
|
|
4870
|
-
4e3,
|
|
4871
|
-
6e3
|
|
4872
|
-
];
|
|
4873
|
-
let last = null;
|
|
4874
|
-
for (const delay of delays) {
|
|
4875
|
-
if (delay) await sleep(delay);
|
|
4876
|
-
if (cancelled) return;
|
|
4877
|
-
let title;
|
|
4878
|
-
try {
|
|
4879
|
-
({title} = await rest.getConversation({ conversationId }));
|
|
4880
|
-
} catch (_error) {
|
|
4881
|
-
continue;
|
|
4882
|
-
}
|
|
4883
|
-
if (cancelled) return;
|
|
4884
|
-
if (title && title !== last) {
|
|
4885
|
-
last = title;
|
|
4886
|
-
setChatTitle(title);
|
|
4887
|
-
}
|
|
4858
|
+
const abort = new AbortController();
|
|
4859
|
+
rest.streamConversation({
|
|
4860
|
+
conversationId,
|
|
4861
|
+
signal: abort.signal,
|
|
4862
|
+
onEvent: (event) => {
|
|
4863
|
+
if (event.title) setChatTitle(event.title);
|
|
4888
4864
|
}
|
|
4889
|
-
})();
|
|
4890
|
-
return () =>
|
|
4891
|
-
cancelled = true;
|
|
4892
|
-
};
|
|
4865
|
+
}).catch(() => {});
|
|
4866
|
+
return () => abort.abort();
|
|
4893
4867
|
}, [
|
|
4894
4868
|
rest,
|
|
4895
4869
|
conversationId,
|
|
4896
|
-
initialConversationId,
|
|
4897
4870
|
setChatTitle
|
|
4898
4871
|
]);
|
|
4899
4872
|
useEffect(() => {
|