@omniviewdev/runtime 0.15.0 → 0.16.0
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/api.cjs +1 -1
- package/dist/api.js +160 -219
- package/dist/bindings/events/index.d.ts +4 -0
- package/dist/bindings/github.com/omniviewdev/omniview/backend/window/index.d.ts +1 -1
- package/dist/bindings/github.com/omniviewdev/omniview/backend/window/models.d.ts +19 -1
- package/dist/bindings/github.com/omniviewdev/omniview/backend/window/service.d.ts +16 -0
- package/dist/context/settings/index.d.ts +1 -0
- package/dist/context/settings/settingsWindow.d.ts +4 -0
- package/dist/context/windows/activePageNavigator.d.ts +2 -3
- package/dist/index.cjs +3 -3
- package/dist/index.d.ts +1 -0
- package/dist/index.js +400 -381
- package/dist/models-B8VGD21U.cjs +1 -0
- package/dist/models-BJZVpONm.cjs +1 -0
- package/dist/models-BlxGoC2X.js +1463 -0
- package/dist/{models-BJgLAHwq.js → models-ddVn9pLv.js} +79 -284
- package/dist/models.cjs +1 -1
- package/dist/models.js +33 -33
- package/dist/service-DKddH-QF.cjs +1 -0
- package/dist/service-lcq0B7wi.js +739 -0
- package/dist/settingsEditors.d.ts +35 -0
- package/package.json +1 -1
- package/dist/models-BTzXdmUY.js +0 -1240
- package/dist/models-BhsFYb70.cjs +0 -1
- package/dist/models-NYvUa5Yc.cjs +0 -1
- package/dist/servicewrapper-CZ9BUUjp.js +0 -662
- package/dist/servicewrapper-lF8bBrIo.cjs +0 -1
package/dist/index.js
CHANGED
|
@@ -1,24 +1,24 @@
|
|
|
1
1
|
import { jsx as P, jsxs as te, Fragment as Ct } from "react/jsx-runtime";
|
|
2
2
|
import { c as q } from "react/compiler-runtime";
|
|
3
|
-
import L, { useEffect as ge, useContext as $e, createContext as Ze, useSyncExternalStore as Me, useCallback as we, useState as pe, useRef as ne, createElement as
|
|
4
|
-
import { W as j, s as
|
|
5
|
-
import { S as
|
|
6
|
-
import { useQueryClient as ce, useQuery as G, useMutation as ee, keepPreviousData as Jt, CancelledError as Ke, skipToken as ie, useQueries as
|
|
7
|
-
import { G as
|
|
3
|
+
import L, { useEffect as ge, useContext as $e, createContext as Ze, useSyncExternalStore as Me, useCallback as we, useState as pe, useRef as ne, createElement as Sn, useId as Cn, useLayoutEffect as ft, Component as In } from "react";
|
|
4
|
+
import { W as j, s as _n } from "./graph-JDqyJC_i.js";
|
|
5
|
+
import { S as bi } from "./graph-JDqyJC_i.js";
|
|
6
|
+
import { useQueryClient as ce, useQuery as G, useMutation as ee, keepPreviousData as Jt, CancelledError as Ke, skipToken as ie, useQueries as Dn, hashKey as pt } from "@tanstack/react-query";
|
|
7
|
+
import { G as Rn, C as Nn, V as kn, O as On, h as Tn, i as An, S as Pn, j as xn, k as Ln, I as Fn, R as qn, o as $n, p as Mn, q as Ht, r as Un, L as Wn, t as Qn, u as jn, v as It, w as Vt, x as Kn, y as Gn, z as zn, A as Bn, B as Jn, D as Hn, E as Vn, F as Yn, H as Zn, J as Xn, K as er, M as tr, Q as nr, N as rr, U as Lt, P as sr, T as Yt, W as or, X as ir, Y as Zt, Z as cr, _ as ar, $ as lr, a0 as ur, a1 as Ft, a2 as Xt, a3 as dr, a4 as fr, a5 as pr, a6 as gr, a7 as hr, a8 as yr, a9 as mr, aa as qt, ab as vr, ac as br, ad as wr, ae as Er, af as Sr } from "./service-lcq0B7wi.js";
|
|
8
8
|
import "./index-zyAgCXOO.js";
|
|
9
9
|
import { O as W, a as en } from "./events-uBheGmqm.js";
|
|
10
|
-
import { Link as
|
|
11
|
-
import { useToast as
|
|
12
|
-
import { P as
|
|
13
|
-
import { RouterProvider as
|
|
10
|
+
import { Link as Cr, useNavigate as Ir, useLocation as _r, createMemoryRouter as Dr } from "react-router";
|
|
11
|
+
import { useToast as Rr, Card as Nr, Toolbar as $t, Text as _e, IconButton as Be, EmptyState as kr, Button as Oe, Code as Or, Spinner as Tr } from "@omniviewdev/base-ui";
|
|
12
|
+
import { P as Ar, S as Pr, F as xr } from "./models-BlxGoC2X.js";
|
|
13
|
+
import { RouterProvider as Lr } from "react-router/dom";
|
|
14
14
|
const _t = L.createContext(void 0), gt = {
|
|
15
15
|
kind: "host"
|
|
16
|
-
},
|
|
16
|
+
}, Fr = (t) => ["settings", t.kind, t.kind === "plugin" ? t.pluginId : ""], qr = {};
|
|
17
17
|
async function tn(t, e) {
|
|
18
18
|
await t.cancelQueries(e), await t.invalidateQueries(e);
|
|
19
19
|
}
|
|
20
20
|
const nt = /* @__PURE__ */ new WeakMap();
|
|
21
|
-
function
|
|
21
|
+
function $r(t) {
|
|
22
22
|
let e = nt.get(t);
|
|
23
23
|
if (!e) {
|
|
24
24
|
const r = (s) => {
|
|
@@ -46,20 +46,20 @@ function Fr(t) {
|
|
|
46
46
|
--e.users === 0 && (e.stop(), nt.delete(t));
|
|
47
47
|
};
|
|
48
48
|
}
|
|
49
|
-
function
|
|
49
|
+
function Mr(t, e, r) {
|
|
50
50
|
return t.kind === "host" ? `${e}.${r}` : r;
|
|
51
51
|
}
|
|
52
52
|
function nn(t) {
|
|
53
53
|
const e = q(25), r = ce(), n = t.kind, s = t.pluginId;
|
|
54
54
|
let i, o;
|
|
55
|
-
e[0] !== r ? (i = () =>
|
|
55
|
+
e[0] !== r ? (i = () => $r(r), o = [r], e[0] = r, e[1] = i, e[2] = o) : (i = e[1], o = e[2]), ge(i, o);
|
|
56
56
|
let c;
|
|
57
|
-
e[3] !== t ? (c =
|
|
57
|
+
e[3] !== t ? (c = Fr(t), e[3] = t, e[4] = c) : c = e[4];
|
|
58
58
|
let u;
|
|
59
59
|
e[5] !== t ? (u = async (y) => {
|
|
60
60
|
const {
|
|
61
61
|
signal: b
|
|
62
|
-
} = y, w = await
|
|
62
|
+
} = y, w = await Rn(t);
|
|
63
63
|
return b.throwIfAborted(), w;
|
|
64
64
|
}, e[5] = t, e[6] = u) : u = e[6];
|
|
65
65
|
let a;
|
|
@@ -73,7 +73,7 @@ function nn(t) {
|
|
|
73
73
|
let l;
|
|
74
74
|
e[10] !== r || e[11] !== n || e[12] !== s || e[13] !== t ? (l = {
|
|
75
75
|
mutationFn: async (y) => {
|
|
76
|
-
const b = await
|
|
76
|
+
const b = await Nn(t, y);
|
|
77
77
|
return await tn(r, {
|
|
78
78
|
queryKey: ["settings", n, s ?? ""]
|
|
79
79
|
}), b;
|
|
@@ -83,11 +83,11 @@ function nn(t) {
|
|
|
83
83
|
mutateAsync: f
|
|
84
84
|
} = ee(l);
|
|
85
85
|
let p;
|
|
86
|
-
e[15] !== n || e[16] !== s ? (p = (y, b) =>
|
|
86
|
+
e[15] !== n || e[16] !== s ? (p = (y, b) => kn(n === "host" ? gt : {
|
|
87
87
|
kind: n,
|
|
88
88
|
pluginId: s
|
|
89
89
|
}, y, b), e[15] = n, e[16] = s, e[17] = p) : p = e[17];
|
|
90
|
-
const v = p, h = d.data?.categories ??
|
|
90
|
+
const v = p, h = d.data?.categories ?? qr, g = d.error ?? void 0;
|
|
91
91
|
let m;
|
|
92
92
|
return e[18] !== f || e[19] !== d.data || e[20] !== d.isPending || e[21] !== h || e[22] !== g || e[23] !== v ? (m = {
|
|
93
93
|
snapshot: d.data,
|
|
@@ -134,13 +134,28 @@ const Z = {
|
|
|
134
134
|
VALIDATION: "omniview:validation",
|
|
135
135
|
NOT_IMPLEMENTED: "omniview:not-implemented"
|
|
136
136
|
};
|
|
137
|
+
function rn(t) {
|
|
138
|
+
const e = t.startsWith("#") ? t.slice(1) : t;
|
|
139
|
+
return /^\/settings\/?(?:[?#]|$)/.test(e) ? e : null;
|
|
140
|
+
}
|
|
141
|
+
function Ur(t = "") {
|
|
142
|
+
const e = t === "" ? "" : rn(t);
|
|
143
|
+
return e === null ? Promise.reject(new Error("Settings requires a local settings route.")) : On(e === "/settings" || e === "/settings/" ? "" : e);
|
|
144
|
+
}
|
|
137
145
|
let Ge = null;
|
|
138
|
-
function
|
|
146
|
+
function fo(t) {
|
|
139
147
|
return Ge = t, () => {
|
|
140
148
|
Ge === t && (Ge = null);
|
|
141
149
|
};
|
|
142
150
|
}
|
|
143
|
-
function
|
|
151
|
+
function Wr(t) {
|
|
152
|
+
const e = rn(t);
|
|
153
|
+
if (e !== null) {
|
|
154
|
+
Ur(e).catch((r) => {
|
|
155
|
+
console.error("[settings] opening the settings window failed", r);
|
|
156
|
+
});
|
|
157
|
+
return;
|
|
158
|
+
}
|
|
144
159
|
if (!Ge)
|
|
145
160
|
throw new Error(`cannot navigate to "${t}": this window has no page navigator`);
|
|
146
161
|
Ge(t);
|
|
@@ -244,14 +259,14 @@ function he(t) {
|
|
|
244
259
|
function Ve(t) {
|
|
245
260
|
return he(t).type === Z.CANCELLED;
|
|
246
261
|
}
|
|
247
|
-
function
|
|
262
|
+
function Qr(t) {
|
|
248
263
|
switch (t.type) {
|
|
249
264
|
case "navigate":
|
|
250
265
|
return {
|
|
251
266
|
label: t.label,
|
|
252
|
-
//
|
|
267
|
+
// Settings targets activate their dedicated window; other routes use the active page.
|
|
253
268
|
onClick: () => {
|
|
254
|
-
|
|
269
|
+
Wr((t.target ?? "/").replace(/^#/, ""));
|
|
255
270
|
}
|
|
256
271
|
};
|
|
257
272
|
case "open-url":
|
|
@@ -282,34 +297,34 @@ function Mr(t) {
|
|
|
282
297
|
};
|
|
283
298
|
}
|
|
284
299
|
}
|
|
285
|
-
function
|
|
300
|
+
function sn(t, e) {
|
|
286
301
|
const r = [t.detail, ...t.suggestions?.map((s) => `• ${s}`) ?? []].join(`
|
|
287
302
|
`);
|
|
288
303
|
return {
|
|
289
304
|
message: e || (t.title !== "Error" ? t.title : "Operation failed"),
|
|
290
305
|
status: "error",
|
|
291
306
|
details: r,
|
|
292
|
-
actions: t.actions?.map(
|
|
307
|
+
actions: t.actions?.map(Qr)
|
|
293
308
|
};
|
|
294
309
|
}
|
|
295
310
|
function Le(t, e, r) {
|
|
296
311
|
if (Ve(e)) return;
|
|
297
312
|
const n = he(e);
|
|
298
|
-
t(
|
|
313
|
+
t(sn(n, r));
|
|
299
314
|
}
|
|
300
315
|
function se(t, e) {
|
|
301
316
|
return (r) => {
|
|
302
317
|
if (Ve(r)) return;
|
|
303
318
|
const n = he(r);
|
|
304
|
-
t(
|
|
319
|
+
t(sn(n, n.title !== "Error" ? n.title : e));
|
|
305
320
|
};
|
|
306
321
|
}
|
|
307
|
-
function
|
|
322
|
+
function po(t) {
|
|
308
323
|
const e = q(2);
|
|
309
324
|
let r;
|
|
310
|
-
return e[0] !== t ? (r = /* @__PURE__ */ P(
|
|
325
|
+
return e[0] !== t ? (r = /* @__PURE__ */ P(jr, { ...t }, t.pluginId), e[0] = t, e[1] = r) : r = e[1], r;
|
|
311
326
|
}
|
|
312
|
-
function
|
|
327
|
+
function jr(t) {
|
|
313
328
|
const e = q(40), {
|
|
314
329
|
children: r,
|
|
315
330
|
pluginId: n,
|
|
@@ -324,13 +339,13 @@ function Ur(t) {
|
|
|
324
339
|
categories: c
|
|
325
340
|
} = nn(o);
|
|
326
341
|
let u;
|
|
327
|
-
e[2] !== c.plugin?.settings || e[3] !== n ? (u = Object.fromEntries(Object.entries(c.plugin?.settings ?? {}).filter(
|
|
342
|
+
e[2] !== c.plugin?.settings || e[3] !== n ? (u = Object.fromEntries(Object.entries(c.plugin?.settings ?? {}).filter(Kr).map((D) => {
|
|
328
343
|
const [A, N] = D;
|
|
329
344
|
return [`${n}.${A}`, N.value];
|
|
330
345
|
})), e[2] = c.plugin?.settings, e[3] = n, e[4] = u) : u = e[4];
|
|
331
346
|
const a = u;
|
|
332
347
|
let d;
|
|
333
|
-
e[5] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (d = new
|
|
348
|
+
e[5] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (d = new Ar(), e[5] = d) : d = e[5];
|
|
334
349
|
const [l, f] = L.useState(d), [p, v] = L.useState(!1), [h, g] = L.useState(null), m = L.useRef(0);
|
|
335
350
|
console.debug("[PluginContextProvider] render", {
|
|
336
351
|
pluginId: n,
|
|
@@ -344,7 +359,7 @@ function Ur(t) {
|
|
|
344
359
|
return;
|
|
345
360
|
}
|
|
346
361
|
const D = m.current = m.current + 1;
|
|
347
|
-
console.debug(`[PluginContextProvider] fetching meta for "${n}"`),
|
|
362
|
+
console.debug(`[PluginContextProvider] fetching meta for "${n}"`), Tn(n).then((A) => {
|
|
348
363
|
D === m.current && (console.debug(`[PluginContextProvider] meta loaded for "${n}"`, {
|
|
349
364
|
name: A?.name,
|
|
350
365
|
version: A?.version
|
|
@@ -471,17 +486,17 @@ function Ur(t) {
|
|
|
471
486
|
let R;
|
|
472
487
|
return e[37] !== r || e[38] !== I ? (R = /* @__PURE__ */ P(_t.Provider, { value: I, children: r }), e[37] = r, e[38] = I, e[39] = R) : R = e[39], R;
|
|
473
488
|
}
|
|
474
|
-
function
|
|
489
|
+
function Kr(t) {
|
|
475
490
|
const [, e] = t;
|
|
476
491
|
return e !== void 0;
|
|
477
492
|
}
|
|
478
|
-
function
|
|
493
|
+
function on() {
|
|
479
494
|
const t = $e(_t);
|
|
480
495
|
if (!t)
|
|
481
496
|
throw new Error("usePluginContext must be used within a PluginContextProvider");
|
|
482
497
|
return t;
|
|
483
498
|
}
|
|
484
|
-
const
|
|
499
|
+
const cn = Ze(void 0), go = (t) => {
|
|
485
500
|
const e = q(7), {
|
|
486
501
|
children: r
|
|
487
502
|
} = t, {
|
|
@@ -492,7 +507,7 @@ const on = Ze(void 0), uo = (t) => {
|
|
|
492
507
|
s = {};
|
|
493
508
|
for (const [u, a] of Object.entries(n))
|
|
494
509
|
for (const [d, l] of Object.entries(a?.settings ?? {}))
|
|
495
|
-
l && (s[
|
|
510
|
+
l && (s[Mr(gt, u, d)] = l.value);
|
|
496
511
|
e[0] = n, e[1] = s;
|
|
497
512
|
} else
|
|
498
513
|
s = e[1];
|
|
@@ -502,8 +517,8 @@ const on = Ze(void 0), uo = (t) => {
|
|
|
502
517
|
settings: i
|
|
503
518
|
}, e[2] = i, e[3] = o) : o = e[3];
|
|
504
519
|
let c;
|
|
505
|
-
return e[4] !== r || e[5] !== o ? (c = /* @__PURE__ */ P(
|
|
506
|
-
},
|
|
520
|
+
return e[4] !== r || e[5] !== o ? (c = /* @__PURE__ */ P(cn.Provider, { value: o, children: r }), e[4] = r, e[5] = o, e[6] = c) : c = e[6], c;
|
|
521
|
+
}, Gr = {
|
|
507
522
|
height: 32,
|
|
508
523
|
focused: 0,
|
|
509
524
|
tabs: [],
|
|
@@ -527,7 +542,7 @@ const on = Ze(void 0), uo = (t) => {
|
|
|
527
542
|
},
|
|
528
543
|
fullscreenDrawer: () => {
|
|
529
544
|
}
|
|
530
|
-
},
|
|
545
|
+
}, zr = L.createContext(Gr), Br = Ze(void 0), Jr = L.createContext(void 0), an = L.createContext(void 0), Hr = 3e4, ho = (t) => {
|
|
531
546
|
const e = q(12), {
|
|
532
547
|
children: r
|
|
533
548
|
} = t;
|
|
@@ -557,7 +572,7 @@ const on = Ze(void 0), uo = (t) => {
|
|
|
557
572
|
const m = [];
|
|
558
573
|
for (const y of s)
|
|
559
574
|
if (y.status !== "running") {
|
|
560
|
-
const b = Date.now() - (y.completedAt ?? y.startedAt), w = Math.max(0,
|
|
575
|
+
const b = Date.now() - (y.completedAt ?? y.startedAt), w = Math.max(0, Hr - b);
|
|
561
576
|
m.push(setTimeout(() => l(y.id), w));
|
|
562
577
|
}
|
|
563
578
|
return () => m.forEach(clearTimeout);
|
|
@@ -571,8 +586,8 @@ const on = Ze(void 0), uo = (t) => {
|
|
|
571
586
|
}, e[7] = s, e[8] = v) : v = e[8];
|
|
572
587
|
const h = v;
|
|
573
588
|
let g;
|
|
574
|
-
return e[9] !== r || e[10] !== h ? (g = /* @__PURE__ */ P(
|
|
575
|
-
}, Dt = L.createContext(null),
|
|
589
|
+
return e[9] !== r || e[10] !== h ? (g = /* @__PURE__ */ P(an.Provider, { value: h, children: r }), e[9] = r, e[10] = h, e[11] = g) : g = e[11], g;
|
|
590
|
+
}, Dt = L.createContext(null), yo = (t) => {
|
|
576
591
|
const e = q(3), {
|
|
577
592
|
actions: r,
|
|
578
593
|
children: n
|
|
@@ -580,7 +595,7 @@ const on = Ze(void 0), uo = (t) => {
|
|
|
580
595
|
let s;
|
|
581
596
|
return e[0] !== r || e[1] !== n ? (s = /* @__PURE__ */ P(Dt.Provider, { value: r, children: n }), e[0] = r, e[1] = n, e[2] = s) : s = e[2], s;
|
|
582
597
|
};
|
|
583
|
-
function
|
|
598
|
+
function mo() {
|
|
584
599
|
const t = L.useContext(Dt);
|
|
585
600
|
if (!t)
|
|
586
601
|
throw new Error("useWindowActions must be used inside a workspace window (WindowActionsProvider)");
|
|
@@ -593,7 +608,7 @@ var ht = function(t, e) {
|
|
|
593
608
|
for (var s in n) Object.prototype.hasOwnProperty.call(n, s) && (r[s] = n[s]);
|
|
594
609
|
}, ht(t, e);
|
|
595
610
|
};
|
|
596
|
-
function
|
|
611
|
+
function Vr(t, e) {
|
|
597
612
|
if (typeof e != "function" && e !== null)
|
|
598
613
|
throw new TypeError("Class extends value " + String(e) + " is not a constructor or null");
|
|
599
614
|
ht(t, e);
|
|
@@ -602,28 +617,28 @@ function Br(t, e) {
|
|
|
602
617
|
}
|
|
603
618
|
t.prototype = e === null ? Object.create(e) : (r.prototype = e.prototype, new r());
|
|
604
619
|
}
|
|
605
|
-
var ot = "Invariant Violation", Ut = Object.setPrototypeOf,
|
|
620
|
+
var ot = "Invariant Violation", Ut = Object.setPrototypeOf, Yr = Ut === void 0 ? function(t, e) {
|
|
606
621
|
return t.__proto__ = e, t;
|
|
607
|
-
} : Ut,
|
|
622
|
+
} : Ut, Zr = (
|
|
608
623
|
/** @class */
|
|
609
624
|
(function(t) {
|
|
610
|
-
|
|
625
|
+
Vr(e, t);
|
|
611
626
|
function e(r) {
|
|
612
627
|
r === void 0 && (r = ot);
|
|
613
628
|
var n = t.call(this, typeof r == "number" ? ot + ": " + r + " (see https://github.com/apollographql/invariant-packages)" : r) || this;
|
|
614
|
-
return n.framesToPop = 1, n.name = ot,
|
|
629
|
+
return n.framesToPop = 1, n.name = ot, Yr(n, e.prototype), n;
|
|
615
630
|
}
|
|
616
631
|
return e;
|
|
617
632
|
})(Error)
|
|
618
633
|
);
|
|
619
634
|
function yt(t, e) {
|
|
620
635
|
if (!t)
|
|
621
|
-
throw new
|
|
636
|
+
throw new Zr(e);
|
|
622
637
|
}
|
|
623
|
-
var
|
|
638
|
+
var ln = ["debug", "log", "warn", "error", "silent"], Xr = ln.indexOf("log");
|
|
624
639
|
function Je(t) {
|
|
625
640
|
return function() {
|
|
626
|
-
if (
|
|
641
|
+
if (ln.indexOf(t) >= Xr) {
|
|
627
642
|
var e = console[t] || console.log;
|
|
628
643
|
return e.apply(console, arguments);
|
|
629
644
|
}
|
|
@@ -632,9 +647,9 @@ function Je(t) {
|
|
|
632
647
|
(function(t) {
|
|
633
648
|
t.debug = Je("debug"), t.log = Je("log"), t.warn = Je("warn"), t.error = Je("error");
|
|
634
649
|
})(yt || (yt = {}));
|
|
635
|
-
const
|
|
636
|
-
function
|
|
637
|
-
const e = q(6), r =
|
|
650
|
+
const un = Ze(void 0), es = () => $e(un);
|
|
651
|
+
function dn(t) {
|
|
652
|
+
const e = q(6), r = es(), n = L.useRef(null);
|
|
638
653
|
let s;
|
|
639
654
|
e[0] !== t || e[1] !== r ? (s = (u) => {
|
|
640
655
|
let a = r?.getExtensionPoint(t), d = a?.subscribe(u);
|
|
@@ -662,10 +677,10 @@ function un(t) {
|
|
|
662
677
|
const c = o;
|
|
663
678
|
return Me(i, c, c);
|
|
664
679
|
}
|
|
665
|
-
function
|
|
666
|
-
return
|
|
680
|
+
function vo(t) {
|
|
681
|
+
return dn(t).store;
|
|
667
682
|
}
|
|
668
|
-
const
|
|
683
|
+
const bo = (t) => {
|
|
669
684
|
const e = q(5), {
|
|
670
685
|
registry: r,
|
|
671
686
|
children: n
|
|
@@ -675,13 +690,13 @@ const yo = (t) => {
|
|
|
675
690
|
const [i] = L.useState(s);
|
|
676
691
|
yt(i === r, "You can't change the extension registry after it has been rendered");
|
|
677
692
|
let o;
|
|
678
|
-
return e[2] !== n || e[3] !== i ? (o = /* @__PURE__ */ P(
|
|
693
|
+
return e[2] !== n || e[3] !== i ? (o = /* @__PURE__ */ P(un.Provider, { value: i, children: n }), e[2] = n, e[3] = i, e[4] = o) : o = e[4], o;
|
|
679
694
|
}, it = (t) => {
|
|
680
695
|
if (!t || typeof t != "string")
|
|
681
696
|
throw new TypeError(`extensionName is required to be a string and can't be: "${t}" (${typeof t})`);
|
|
682
697
|
return t.trim();
|
|
683
698
|
};
|
|
684
|
-
class
|
|
699
|
+
class ts {
|
|
685
700
|
id;
|
|
686
701
|
mode;
|
|
687
702
|
_pluginId;
|
|
@@ -799,7 +814,7 @@ class Zr {
|
|
|
799
814
|
e();
|
|
800
815
|
}
|
|
801
816
|
}
|
|
802
|
-
class
|
|
817
|
+
class wo {
|
|
803
818
|
_stores = /* @__PURE__ */ new Map();
|
|
804
819
|
_storeUnsubs = /* @__PURE__ */ new Map();
|
|
805
820
|
_listeners = /* @__PURE__ */ new Set();
|
|
@@ -818,7 +833,7 @@ class mo {
|
|
|
818
833
|
const s = this._stores.get(r);
|
|
819
834
|
throw new Error(`Extension point "${r}" already exists (owned by "${s.pluginId ?? "unknown"}")`);
|
|
820
835
|
}
|
|
821
|
-
const n = new
|
|
836
|
+
const n = new ts({
|
|
822
837
|
...e,
|
|
823
838
|
id: r
|
|
824
839
|
});
|
|
@@ -951,18 +966,18 @@ const ae = {
|
|
|
951
966
|
padding: "var(--ov-space-3)",
|
|
952
967
|
borderTop: "1px solid var(--ov-color-border-muted)"
|
|
953
968
|
}
|
|
954
|
-
},
|
|
969
|
+
}, fn = Ze(void 0), ns = {
|
|
955
970
|
default: "info",
|
|
956
971
|
info: "info",
|
|
957
972
|
success: "success",
|
|
958
973
|
warning: "warning",
|
|
959
974
|
error: "danger"
|
|
960
|
-
},
|
|
975
|
+
}, Eo = ({
|
|
961
976
|
children: t
|
|
962
977
|
}) => {
|
|
963
978
|
const {
|
|
964
979
|
toast: e
|
|
965
|
-
} =
|
|
980
|
+
} = Rr(), [r, n] = L.useState([]), [s, i] = L.useState([]), [o, c] = L.useState(!1), [u, a] = L.useState(), [d, l] = L.useState(""), f = L.useRef(0), p = L.useRef(null);
|
|
966
981
|
L.useEffect(() => {
|
|
967
982
|
if (!o)
|
|
968
983
|
return;
|
|
@@ -1006,13 +1021,13 @@ const ae = {
|
|
|
1006
1021
|
};
|
|
1007
1022
|
}
|
|
1008
1023
|
e(E === "error" ? w : _ ?? w, {
|
|
1009
|
-
severity:
|
|
1024
|
+
severity: ns[E] ?? "info",
|
|
1010
1025
|
title: E !== "error" && _ ? w : void 0,
|
|
1011
1026
|
duration: C,
|
|
1012
1027
|
action: R ?? I?.[0]
|
|
1013
1028
|
});
|
|
1014
1029
|
};
|
|
1015
|
-
return /* @__PURE__ */ te(
|
|
1030
|
+
return /* @__PURE__ */ te(fn.Provider, { value: {
|
|
1016
1031
|
showSnackbar: h,
|
|
1017
1032
|
openNotifications: () => {
|
|
1018
1033
|
c(!0);
|
|
@@ -1020,7 +1035,7 @@ const ae = {
|
|
|
1020
1035
|
notificationCount: s.length
|
|
1021
1036
|
}, children: [
|
|
1022
1037
|
t,
|
|
1023
|
-
o && /* @__PURE__ */ te(
|
|
1038
|
+
o && /* @__PURE__ */ te(Nr, { ref: p, style: ae.Panel, size: "sm", variant: "outline", surface: "overlay", elevation: 3, "aria-label": "Notifications", tabIndex: -1, children: [
|
|
1024
1039
|
/* @__PURE__ */ te($t, { size: "sm", style: ae.Header, children: [
|
|
1025
1040
|
/* @__PURE__ */ P(_e, { size: "sm", weight: "semibold", children: "Notifications" }),
|
|
1026
1041
|
/* @__PURE__ */ P(_e, { size: "xs", tone: "muted", children: s.length }),
|
|
@@ -1034,7 +1049,7 @@ const ae = {
|
|
|
1034
1049
|
] })
|
|
1035
1050
|
] }),
|
|
1036
1051
|
/* @__PURE__ */ te("div", { style: ae.List, children: [
|
|
1037
|
-
s.length === 0 && /* @__PURE__ */ P(
|
|
1052
|
+
s.length === 0 && /* @__PURE__ */ P(kr, { size: "sm", title: "No recent errors", description: "Error details will appear here." }),
|
|
1038
1053
|
s.slice().reverse().map((g) => {
|
|
1039
1054
|
const m = u === g.id;
|
|
1040
1055
|
return /* @__PURE__ */ te("div", { style: ae.Notice, children: [
|
|
@@ -1055,7 +1070,7 @@ const ae = {
|
|
|
1055
1070
|
] }),
|
|
1056
1071
|
/* @__PURE__ */ P("div", { id: `notification-${g.id}`, hidden: !m, style: ae.Details, children: m && /* @__PURE__ */ te(Ct, { children: [
|
|
1057
1072
|
/* @__PURE__ */ P(_e, { size: "xs", tone: "muted", children: /* @__PURE__ */ P("time", { dateTime: g.created, children: new Date(g.created).toLocaleString() }) }),
|
|
1058
|
-
/* @__PURE__ */ P(
|
|
1073
|
+
/* @__PURE__ */ P(Or, { size: "sm", style: ae.Code, children: g.details?.length ? g.details : g.message }),
|
|
1059
1074
|
/* @__PURE__ */ te("div", { style: ae.Actions, children: [
|
|
1060
1075
|
/* @__PURE__ */ P(Oe, { size: "sm", variant: "ghost", onClick: async () => {
|
|
1061
1076
|
l("");
|
|
@@ -1077,7 +1092,7 @@ ${g.details ?? ""}`);
|
|
|
1077
1092
|
] })
|
|
1078
1093
|
] });
|
|
1079
1094
|
}, ye = () => {
|
|
1080
|
-
const t = $e(
|
|
1095
|
+
const t = $e(fn);
|
|
1081
1096
|
if (t === void 0)
|
|
1082
1097
|
throw new Error("useCustomSnackbar must be used within a CustomSnackbarProvider");
|
|
1083
1098
|
return t;
|
|
@@ -1096,7 +1111,7 @@ function Q(t) {
|
|
|
1096
1111
|
}
|
|
1097
1112
|
const de = /* @__PURE__ */ new Map(), Ue = /* @__PURE__ */ new Map();
|
|
1098
1113
|
let ct = 0, Pe = [], Rt = 0;
|
|
1099
|
-
const
|
|
1114
|
+
const pn = {
|
|
1100
1115
|
phase: "checking"
|
|
1101
1116
|
};
|
|
1102
1117
|
function De(t, e) {
|
|
@@ -1106,7 +1121,7 @@ function De(t, e) {
|
|
|
1106
1121
|
pluginID: t,
|
|
1107
1122
|
connectionID: e,
|
|
1108
1123
|
key: r,
|
|
1109
|
-
snapshot:
|
|
1124
|
+
snapshot: pn,
|
|
1110
1125
|
listeners: /* @__PURE__ */ new Set(),
|
|
1111
1126
|
users: 0,
|
|
1112
1127
|
version: 0,
|
|
@@ -1121,7 +1136,7 @@ function Qe(t, e) {
|
|
|
1121
1136
|
function Re(t, e, r = !1) {
|
|
1122
1137
|
t.generation = ++Rt, t.version++, r || (t.operation = void 0), Qe(t, e);
|
|
1123
1138
|
}
|
|
1124
|
-
function
|
|
1139
|
+
function rs(t) {
|
|
1125
1140
|
switch (t) {
|
|
1126
1141
|
case "CONNECTED":
|
|
1127
1142
|
return "connected";
|
|
@@ -1144,15 +1159,15 @@ function Nt(t) {
|
|
|
1144
1159
|
if (e)
|
|
1145
1160
|
return e.startsWith("{") || e.startsWith("[") || e.length > 512 || /[\r\n]|\bgoroutine\b|\bat\s+\S+\s+\(.*:\d+:\d+\)/.test(e) ? "The connection operation could not be completed." : e;
|
|
1146
1161
|
}
|
|
1147
|
-
function
|
|
1148
|
-
const r =
|
|
1162
|
+
function gn(t, e) {
|
|
1163
|
+
const r = rs(t.status);
|
|
1149
1164
|
return {
|
|
1150
1165
|
phase: r,
|
|
1151
1166
|
connection: e,
|
|
1152
1167
|
message: Nt(t.error || t.details) || (r === "error" ? "The connection is not ready." : void 0)
|
|
1153
1168
|
};
|
|
1154
1169
|
}
|
|
1155
|
-
function
|
|
1170
|
+
function hn(t, e) {
|
|
1156
1171
|
const r = he(t);
|
|
1157
1172
|
return {
|
|
1158
1173
|
phase: r.status === 401 ? "unauthorized" : r.status === 403 ? "forbidden" : r.status === 404 ? "not-found" : "error",
|
|
@@ -1184,12 +1199,12 @@ function Ae() {
|
|
|
1184
1199
|
t.users && !Ue.has(t.pluginID) && Se(t, "check", !0).catch(() => {
|
|
1185
1200
|
});
|
|
1186
1201
|
}
|
|
1187
|
-
function
|
|
1202
|
+
function ss() {
|
|
1188
1203
|
Pe.length || (Pe = [W("connection/status", ({
|
|
1189
1204
|
data: t
|
|
1190
1205
|
}) => {
|
|
1191
1206
|
const e = de.get(JSON.stringify([t.pluginID, t.connectionID]));
|
|
1192
|
-
!e || Ue.has(t.pluginID) || e.stop && t.status !== "DISCONNECTED" || t.status !== "DISCONNECTED" && e.starts.size && e.operation?.kind !== "start" || Re(e,
|
|
1207
|
+
!e || Ue.has(t.pluginID) || e.stop && t.status !== "DISCONNECTED" || t.status !== "DISCONNECTED" && e.starts.size && e.operation?.kind !== "start" || Re(e, gn({
|
|
1193
1208
|
status: t.status,
|
|
1194
1209
|
error: "",
|
|
1195
1210
|
details: ""
|
|
@@ -1209,8 +1224,8 @@ function ts() {
|
|
|
1209
1224
|
})), typeof document < "u" && (document.addEventListener("visibilitychange", Ae), Pe.push(() => document.removeEventListener("visibilitychange", Ae))));
|
|
1210
1225
|
}
|
|
1211
1226
|
function Te(t) {
|
|
1212
|
-
return de.set(t.key, t), t.users++, ct++,
|
|
1213
|
-
if (t.users--, ct--, t.users || (Re(t,
|
|
1227
|
+
return de.set(t.key, t), t.users++, ct++, ss(), () => {
|
|
1228
|
+
if (t.users--, ct--, t.users || (Re(t, pn), de.get(t.key) === t && de.delete(t.key)), !ct) {
|
|
1214
1229
|
for (const e of Pe) e();
|
|
1215
1230
|
Pe = [], Ue.clear();
|
|
1216
1231
|
}
|
|
@@ -1233,9 +1248,9 @@ function Se(t, e, r = !1) {
|
|
|
1233
1248
|
}), e === "start" && t.starts.add(s);
|
|
1234
1249
|
const i = Promise.resolve().then(() => {
|
|
1235
1250
|
if (t.version !== s) throw new Error("Connection readiness changed before the operation began.");
|
|
1236
|
-
return e === "start" ?
|
|
1237
|
-
}).then((o) => (t.version === s && Qe(t,
|
|
1238
|
-
throw t.version === s && Qe(t,
|
|
1251
|
+
return e === "start" ? xn(t.pluginID, t.connectionID) : An(t.pluginID, t.connectionID);
|
|
1252
|
+
}).then((o) => (t.version === s && Qe(t, gn(o, o.connection ?? t.snapshot.connection)), o), (o) => {
|
|
1253
|
+
throw t.version === s && Qe(t, hn(o, t.snapshot.connection)), o;
|
|
1239
1254
|
}).finally(() => {
|
|
1240
1255
|
e === "start" && t.starts.delete(s), t.operation?.version === s && (t.operation = void 0);
|
|
1241
1256
|
});
|
|
@@ -1288,7 +1303,7 @@ async function et(t, e) {
|
|
|
1288
1303
|
n();
|
|
1289
1304
|
}
|
|
1290
1305
|
}
|
|
1291
|
-
async function
|
|
1306
|
+
async function So(t, e, r) {
|
|
1292
1307
|
const n = De(t, e), s = Te(n);
|
|
1293
1308
|
try {
|
|
1294
1309
|
try {
|
|
@@ -1312,7 +1327,7 @@ function je(t, e, r) {
|
|
|
1312
1327
|
const n = de.get(JSON.stringify([t, e]));
|
|
1313
1328
|
return r !== void 0 && n?.generation === r && n.snapshot.phase === "connected";
|
|
1314
1329
|
}
|
|
1315
|
-
async function
|
|
1330
|
+
async function os(t, e) {
|
|
1316
1331
|
const r = De(t, e), n = Te(r);
|
|
1317
1332
|
try {
|
|
1318
1333
|
return await Se(r, "start");
|
|
@@ -1320,14 +1335,14 @@ async function ns(t, e) {
|
|
|
1320
1335
|
n();
|
|
1321
1336
|
}
|
|
1322
1337
|
}
|
|
1323
|
-
function
|
|
1338
|
+
function yn(t, e) {
|
|
1324
1339
|
const r = De(t, e);
|
|
1325
1340
|
if (r.stop) return r.stop;
|
|
1326
|
-
const n = Te(r), s = Promise.resolve().then(() =>
|
|
1341
|
+
const n = Te(r), s = Promise.resolve().then(() => Pn(t, e)).then((i) => (Re(r, {
|
|
1327
1342
|
phase: "disconnected",
|
|
1328
1343
|
connection: i
|
|
1329
1344
|
}), i), (i) => {
|
|
1330
|
-
throw Re(r,
|
|
1345
|
+
throw Re(r, hn(i, r.snapshot.connection)), i;
|
|
1331
1346
|
}).finally(() => {
|
|
1332
1347
|
r.stop = void 0, n();
|
|
1333
1348
|
});
|
|
@@ -1349,7 +1364,7 @@ function lt(t) {
|
|
|
1349
1364
|
if (!t.applied) throw new Error("Connection profile was not applied");
|
|
1350
1365
|
return t;
|
|
1351
1366
|
}
|
|
1352
|
-
const
|
|
1367
|
+
const Co = (t) => {
|
|
1353
1368
|
const e = q(89), {
|
|
1354
1369
|
pluginID: r,
|
|
1355
1370
|
connectionID: n,
|
|
@@ -1377,7 +1392,7 @@ const wo = (t) => {
|
|
|
1377
1392
|
}, e[6] = n, e[7] = f, e[8] = o, e[9] = p) : p = e[9];
|
|
1378
1393
|
const v = p;
|
|
1379
1394
|
let h;
|
|
1380
|
-
e[10] !== n || e[11] !== o ? (h = () =>
|
|
1395
|
+
e[10] !== n || e[11] !== o ? (h = () => os(o, n), e[10] = n, e[11] = o, e[12] = h) : h = e[12];
|
|
1381
1396
|
let g;
|
|
1382
1397
|
e[13] !== u ? (g = se(u, "Failed to start connection"), e[13] = u, e[14] = g) : g = e[14];
|
|
1383
1398
|
let m;
|
|
@@ -1390,7 +1405,7 @@ const wo = (t) => {
|
|
|
1390
1405
|
mutateAsync: y
|
|
1391
1406
|
} = ee(m);
|
|
1392
1407
|
let b;
|
|
1393
|
-
e[19] !== n || e[20] !== o ? (b = () =>
|
|
1408
|
+
e[19] !== n || e[20] !== o ? (b = () => yn(o, n), e[19] = n, e[20] = o, e[21] = b) : b = e[21];
|
|
1394
1409
|
let w;
|
|
1395
1410
|
e[22] !== u ? (w = se(u, "Failed to stop connection"), e[22] = u, e[23] = w) : w = e[23];
|
|
1396
1411
|
let E;
|
|
@@ -1403,7 +1418,7 @@ const wo = (t) => {
|
|
|
1403
1418
|
mutateAsync: _
|
|
1404
1419
|
} = ee(E);
|
|
1405
1420
|
let C;
|
|
1406
|
-
e[28] !== o ? (C = (Ce) =>
|
|
1421
|
+
e[28] !== o ? (C = (Ce) => Ln(o, Ce).then(lt), e[28] = o, e[29] = C) : C = e[29];
|
|
1407
1422
|
let I, R;
|
|
1408
1423
|
e[30] !== u ? (I = () => {
|
|
1409
1424
|
u("Connection profile saved", "success");
|
|
@@ -1419,7 +1434,7 @@ const wo = (t) => {
|
|
|
1419
1434
|
mutateAsync: A
|
|
1420
1435
|
} = ee(D);
|
|
1421
1436
|
let N;
|
|
1422
|
-
e[38] !== n || e[39] !== o ? (N = () =>
|
|
1437
|
+
e[38] !== n || e[39] !== o ? (N = () => Fn(o, n).then(lt), e[38] = n, e[39] = o, e[40] = N) : N = e[40];
|
|
1423
1438
|
let $, S;
|
|
1424
1439
|
e[41] !== u ? ($ = () => {
|
|
1425
1440
|
u("Connection profile imported", "success");
|
|
@@ -1435,7 +1450,7 @@ const wo = (t) => {
|
|
|
1435
1450
|
mutateAsync: O
|
|
1436
1451
|
} = ee(k);
|
|
1437
1452
|
let F;
|
|
1438
|
-
e[49] !== n || e[50] !== o ? (F = () =>
|
|
1453
|
+
e[49] !== n || e[50] !== o ? (F = () => qn(o, n).then(lt), e[49] = n, e[50] = o, e[51] = F) : F = e[51];
|
|
1439
1454
|
let T, x;
|
|
1440
1455
|
e[52] !== u ? (T = () => {
|
|
1441
1456
|
u("Connection profile reset", "success");
|
|
@@ -1451,7 +1466,7 @@ const wo = (t) => {
|
|
|
1451
1466
|
mutateAsync: J
|
|
1452
1467
|
} = ee(M);
|
|
1453
1468
|
let K;
|
|
1454
|
-
e[60] !== n || e[61] !== o ? (K = () =>
|
|
1469
|
+
e[60] !== n || e[61] !== o ? (K = () => $n(o, n), e[60] = n, e[61] = o, e[62] = K) : K = e[62];
|
|
1455
1470
|
let z;
|
|
1456
1471
|
e[63] !== n || e[64] !== o || e[65] !== u ? (z = () => {
|
|
1457
1472
|
Qt(o, n, !0), u("Connection disabled", "success");
|
|
@@ -1469,7 +1484,7 @@ const wo = (t) => {
|
|
|
1469
1484
|
mutateAsync: X
|
|
1470
1485
|
} = ee(B);
|
|
1471
1486
|
let U;
|
|
1472
|
-
e[74] !== n || e[75] !== o ? (U = () =>
|
|
1487
|
+
e[74] !== n || e[75] !== o ? (U = () => Mn(o, n), e[74] = n, e[75] = o, e[76] = U) : U = e[76];
|
|
1473
1488
|
const V = i && !!n;
|
|
1474
1489
|
let me;
|
|
1475
1490
|
e[77] !== d || e[78] !== U || e[79] !== V ? (me = {
|
|
@@ -1488,14 +1503,14 @@ const wo = (t) => {
|
|
|
1488
1503
|
resetConnectionProfile: J,
|
|
1489
1504
|
removeConnection: X
|
|
1490
1505
|
}, e[81] = ve, e[82] = O, e[83] = X, e[84] = J, e[85] = A, e[86] = y, e[87] = _, e[88] = be) : be = e[88], be;
|
|
1491
|
-
},
|
|
1506
|
+
}, is = (t) => [t, "connection", "list"], Io = (t) => {
|
|
1492
1507
|
const e = q(33), {
|
|
1493
1508
|
plugin: r
|
|
1494
1509
|
} = t, n = Q(r), s = ce(), {
|
|
1495
1510
|
showSnackbar: i
|
|
1496
1511
|
} = ye();
|
|
1497
1512
|
let o;
|
|
1498
|
-
e[0] !== n ? (o =
|
|
1513
|
+
e[0] !== n ? (o = is(n), e[0] = n, e[1] = o) : o = e[1];
|
|
1499
1514
|
const c = o;
|
|
1500
1515
|
let u;
|
|
1501
1516
|
e[2] !== n ? (u = (I) => Ht(n, I), e[2] = n, e[3] = u) : u = e[3];
|
|
@@ -1510,7 +1525,7 @@ const wo = (t) => {
|
|
|
1510
1525
|
mutateAsync: l
|
|
1511
1526
|
} = ee(d);
|
|
1512
1527
|
let f;
|
|
1513
|
-
e[9] !== n ? (f = (I) =>
|
|
1528
|
+
e[9] !== n ? (f = (I) => Un(n, I), e[9] = n, e[10] = f) : f = e[10];
|
|
1514
1529
|
let p;
|
|
1515
1530
|
e[11] !== i ? (p = se(i, "Failed to stop connection watch"), e[11] = i, e[12] = p) : p = e[12];
|
|
1516
1531
|
let v;
|
|
@@ -1537,7 +1552,7 @@ const wo = (t) => {
|
|
|
1537
1552
|
let w;
|
|
1538
1553
|
e[23] !== n || e[24] !== i ? (w = async () => {
|
|
1539
1554
|
try {
|
|
1540
|
-
return await
|
|
1555
|
+
return await Wn(n);
|
|
1541
1556
|
} catch (I) {
|
|
1542
1557
|
const R = I;
|
|
1543
1558
|
console.log(R), se(i, "Failed to load connections")(R);
|
|
@@ -1558,10 +1573,10 @@ const wo = (t) => {
|
|
|
1558
1573
|
startWatch: l,
|
|
1559
1574
|
stopWatch: h
|
|
1560
1575
|
}, e[29] = _, e[30] = l, e[31] = h, e[32] = C) : C = e[32], C;
|
|
1561
|
-
},
|
|
1576
|
+
}, cs = {
|
|
1562
1577
|
phase: "checking"
|
|
1563
|
-
},
|
|
1564
|
-
getSnapshot: () =>
|
|
1578
|
+
}, as = {
|
|
1579
|
+
getSnapshot: () => cs,
|
|
1565
1580
|
subscribe: () => () => {
|
|
1566
1581
|
},
|
|
1567
1582
|
connect: async () => {
|
|
@@ -1576,7 +1591,7 @@ function le(t) {
|
|
|
1576
1591
|
enabled: s
|
|
1577
1592
|
} = t, i = s === void 0 ? !0 : s, o = Q(r);
|
|
1578
1593
|
let c;
|
|
1579
|
-
e[0] !== n || e[1] !== i || e[2] !== o ? (c = i ? Xe(o, n) :
|
|
1594
|
+
e[0] !== n || e[1] !== i || e[2] !== o ? (c = i ? Xe(o, n) : as, e[0] = n, e[1] = i, e[2] = o, e[3] = c) : c = e[3];
|
|
1580
1595
|
const u = c, a = Me(u.subscribe, u.getSnapshot, u.getSnapshot);
|
|
1581
1596
|
let d;
|
|
1582
1597
|
return e[4] !== a || e[5] !== u.connect || e[6] !== u.retry ? (d = {
|
|
@@ -1625,7 +1640,7 @@ function ue(t, e) {
|
|
|
1625
1640
|
}
|
|
1626
1641
|
}, [t, e, r]);
|
|
1627
1642
|
}
|
|
1628
|
-
const
|
|
1643
|
+
const _o = (t) => {
|
|
1629
1644
|
const e = q(20), {
|
|
1630
1645
|
pluginID: r,
|
|
1631
1646
|
route: n,
|
|
@@ -1647,7 +1662,7 @@ const So = (t) => {
|
|
|
1647
1662
|
signal: b,
|
|
1648
1663
|
queryKey: w
|
|
1649
1664
|
} = y;
|
|
1650
|
-
return l(w, b, () =>
|
|
1665
|
+
return l(w, b, () => Qn(c, n, s));
|
|
1651
1666
|
} : ie, e[8] = s, e[9] = l, e[10] = c, e[11] = f, e[12] = n, e[13] = v) : v = e[13];
|
|
1652
1667
|
let h;
|
|
1653
1668
|
e[14] !== f || e[15] !== p || e[16] !== v ? (h = {
|
|
@@ -1683,10 +1698,10 @@ function vt(t) {
|
|
|
1683
1698
|
function tt(t) {
|
|
1684
1699
|
return t.watchedTotal > 0 && t.doneCount >= t.watchedTotal;
|
|
1685
1700
|
}
|
|
1686
|
-
function
|
|
1701
|
+
function mn(t) {
|
|
1687
1702
|
return t.some((e) => !tt(e));
|
|
1688
1703
|
}
|
|
1689
|
-
function
|
|
1704
|
+
function vn(t) {
|
|
1690
1705
|
const e = t.reduce((n, s) => n + s.watchedTotal, 0);
|
|
1691
1706
|
return e === 0 ? 0 : t.reduce((n, s) => n + s.doneCount, 0) / e;
|
|
1692
1707
|
}
|
|
@@ -1703,7 +1718,7 @@ function bt(t, e, r) {
|
|
|
1703
1718
|
const s = t.get(n);
|
|
1704
1719
|
return s.states[r.type] = r.state, s;
|
|
1705
1720
|
}
|
|
1706
|
-
function
|
|
1721
|
+
function Do() {
|
|
1707
1722
|
const [t, e] = pe(/* @__PURE__ */ new Map()), r = ne(t), n = ne(/* @__PURE__ */ new Map()), s = ne(/* @__PURE__ */ new Map()), [i, o] = pe(!0), [c, u] = pe(), a = ne({
|
|
1708
1723
|
generation: 0
|
|
1709
1724
|
}), [d, l] = pe({}), [f, p] = pe(/* @__PURE__ */ new Map()), v = ne(/* @__PURE__ */ new Map()), [h, g] = pe(/* @__PURE__ */ new Map());
|
|
@@ -1731,7 +1746,7 @@ function Co() {
|
|
|
1731
1746
|
n.current.clear(), s.current.clear();
|
|
1732
1747
|
let k;
|
|
1733
1748
|
try {
|
|
1734
|
-
k =
|
|
1749
|
+
k = jn();
|
|
1735
1750
|
} catch (O) {
|
|
1736
1751
|
k = Promise.reject(O);
|
|
1737
1752
|
}
|
|
@@ -1789,7 +1804,7 @@ function Co() {
|
|
|
1789
1804
|
return X.delete(x), X;
|
|
1790
1805
|
}), v.current.delete(x), s.current.delete(x));
|
|
1791
1806
|
const z = ++k, H = a.current.generation;
|
|
1792
|
-
|
|
1807
|
+
Gn().then((B) => {
|
|
1793
1808
|
if (!S || z !== k || H !== a.current.generation || !B) return;
|
|
1794
1809
|
const X = {};
|
|
1795
1810
|
for (const [U, V] of Object.entries(B))
|
|
@@ -1816,7 +1831,7 @@ function Co() {
|
|
|
1816
1831
|
}, []);
|
|
1817
1832
|
ge(() => W("watch/STATE", b), [b]);
|
|
1818
1833
|
const w = we(async (S, k) => {
|
|
1819
|
-
await
|
|
1834
|
+
await yn(S, k);
|
|
1820
1835
|
}, []), E = we(async (S, k) => {
|
|
1821
1836
|
if (r.current.get(JSON.stringify([S, k]))?.readiness !== "CONNECTED") return;
|
|
1822
1837
|
const O = {
|
|
@@ -1836,7 +1851,7 @@ function Co() {
|
|
|
1836
1851
|
return F.delete(S), F;
|
|
1837
1852
|
});
|
|
1838
1853
|
try {
|
|
1839
|
-
await
|
|
1854
|
+
await Kn(S);
|
|
1840
1855
|
} catch (O) {
|
|
1841
1856
|
throw g((F) => {
|
|
1842
1857
|
const T = new Map(F);
|
|
@@ -1880,14 +1895,14 @@ function Co() {
|
|
|
1880
1895
|
syncingCount: A.length,
|
|
1881
1896
|
errorCount: N.length,
|
|
1882
1897
|
failedCount: $.length,
|
|
1883
|
-
hasSyncing:
|
|
1884
|
-
aggregateProgress:
|
|
1898
|
+
hasSyncing: mn(D),
|
|
1899
|
+
aggregateProgress: vn(D),
|
|
1885
1900
|
disconnect: w,
|
|
1886
1901
|
retryWatch: E,
|
|
1887
1902
|
retryPlugin: _
|
|
1888
1903
|
};
|
|
1889
1904
|
}
|
|
1890
|
-
function
|
|
1905
|
+
function Ro(t) {
|
|
1891
1906
|
const e = q(9), {
|
|
1892
1907
|
pluginID: r
|
|
1893
1908
|
} = t, n = Q(r);
|
|
@@ -1897,7 +1912,7 @@ function Io(t) {
|
|
|
1897
1912
|
signal: l
|
|
1898
1913
|
} = d;
|
|
1899
1914
|
l.throwIfAborted();
|
|
1900
|
-
const f =
|
|
1915
|
+
const f = zn(n), p = () => {
|
|
1901
1916
|
f.cancel();
|
|
1902
1917
|
};
|
|
1903
1918
|
return l.addEventListener("abort", p, {
|
|
@@ -1918,7 +1933,7 @@ function Io(t) {
|
|
|
1918
1933
|
profiles: u
|
|
1919
1934
|
}, e[7] = u, e[8] = a) : a = e[8], a;
|
|
1920
1935
|
}
|
|
1921
|
-
const
|
|
1936
|
+
const ls = {
|
|
1922
1937
|
display: "flex",
|
|
1923
1938
|
alignItems: "center",
|
|
1924
1939
|
justifyContent: "center",
|
|
@@ -1927,22 +1942,22 @@ const is = {
|
|
|
1927
1942
|
padding: 24,
|
|
1928
1943
|
boxSizing: "border-box",
|
|
1929
1944
|
color: "var(--ov-color-fg-default)"
|
|
1930
|
-
},
|
|
1945
|
+
}, us = {
|
|
1931
1946
|
width: "100%",
|
|
1932
1947
|
maxWidth: 560,
|
|
1933
1948
|
minWidth: 0,
|
|
1934
1949
|
display: "flex",
|
|
1935
1950
|
flexDirection: "column",
|
|
1936
1951
|
gap: 16
|
|
1937
|
-
},
|
|
1952
|
+
}, ds = {
|
|
1938
1953
|
display: "flex",
|
|
1939
1954
|
alignItems: "center",
|
|
1940
1955
|
gap: 12
|
|
1941
|
-
},
|
|
1956
|
+
}, fs = {
|
|
1942
1957
|
margin: 0,
|
|
1943
1958
|
fontSize: "1.125rem",
|
|
1944
1959
|
fontWeight: 600
|
|
1945
|
-
},
|
|
1960
|
+
}, ps = {
|
|
1946
1961
|
display: "flex",
|
|
1947
1962
|
flexWrap: "wrap",
|
|
1948
1963
|
gap: 8
|
|
@@ -1950,11 +1965,11 @@ const is = {
|
|
|
1950
1965
|
margin: 0,
|
|
1951
1966
|
whiteSpace: "pre-wrap",
|
|
1952
1967
|
overflowWrap: "anywhere"
|
|
1953
|
-
},
|
|
1968
|
+
}, gs = {
|
|
1954
1969
|
width: 20,
|
|
1955
1970
|
height: 20,
|
|
1956
1971
|
flexShrink: 0
|
|
1957
|
-
},
|
|
1972
|
+
}, hs = {
|
|
1958
1973
|
checking: {
|
|
1959
1974
|
title: "Checking connection",
|
|
1960
1975
|
description: "Checking whether this connection is ready before loading resources."
|
|
@@ -1984,7 +1999,7 @@ const is = {
|
|
|
1984
1999
|
description: "Check the connection settings and network, then connect again or retry the check."
|
|
1985
2000
|
}
|
|
1986
2001
|
};
|
|
1987
|
-
function
|
|
2002
|
+
function ys(t) {
|
|
1988
2003
|
const e = q(44), {
|
|
1989
2004
|
state: r,
|
|
1990
2005
|
connectionName: n,
|
|
@@ -1992,18 +2007,18 @@ function ps(t) {
|
|
|
1992
2007
|
onEditConnection: i,
|
|
1993
2008
|
onBack: o,
|
|
1994
2009
|
backLabel: c
|
|
1995
|
-
} = t, u = c === void 0 ? "Back to connections" : c, a =
|
|
2010
|
+
} = t, u = c === void 0 ? "Back to connections" : c, a = Cn();
|
|
1996
2011
|
if (r.phase === "connected")
|
|
1997
2012
|
return null;
|
|
1998
|
-
const d = r.phase === "checking" || r.phase === "connecting", l =
|
|
2013
|
+
const d = r.phase === "checking" || r.phase === "connecting", l = hs[r.phase], f = n ?? r.connection?.name;
|
|
1999
2014
|
let p;
|
|
2000
2015
|
e[0] !== s || e[1] !== f ? (p = s ?? (f && /* @__PURE__ */ P(_e, { size: "sm", tone: "muted", style: ut, children: f })), e[0] = s, e[1] = f, e[2] = p) : p = e[2];
|
|
2001
2016
|
let v;
|
|
2002
|
-
e[3] !== d ? (v = d && /* @__PURE__ */ P(
|
|
2017
|
+
e[3] !== d ? (v = d && /* @__PURE__ */ P(Tr, { style: gs, "aria-hidden": "true" }), e[3] = d, e[4] = v) : v = e[4];
|
|
2003
2018
|
let h;
|
|
2004
|
-
e[5] !== a || e[6] !== l.title ? (h = /* @__PURE__ */ P("h2", { id: a, style:
|
|
2019
|
+
e[5] !== a || e[6] !== l.title ? (h = /* @__PURE__ */ P("h2", { id: a, style: fs, children: l.title }), e[5] = a, e[6] = l.title, e[7] = h) : h = e[7];
|
|
2005
2020
|
let g;
|
|
2006
|
-
e[8] !== v || e[9] !== h ? (g = /* @__PURE__ */ te("div", { style:
|
|
2021
|
+
e[8] !== v || e[9] !== h ? (g = /* @__PURE__ */ te("div", { style: ds, role: "status", "aria-live": "polite", children: [
|
|
2007
2022
|
v,
|
|
2008
2023
|
h
|
|
2009
2024
|
] }), e[8] = v, e[9] = h, e[10] = g) : g = e[10];
|
|
@@ -2027,14 +2042,14 @@ function ps(t) {
|
|
|
2027
2042
|
let I;
|
|
2028
2043
|
e[26] !== u || e[27] !== o ? (I = o && /* @__PURE__ */ P(Oe, { size: "sm", variant: "outline", color: "neutral", onClick: o, children: u }), e[26] = u, e[27] = o, e[28] = I) : I = e[28];
|
|
2029
2044
|
let R;
|
|
2030
|
-
e[29] !== _ || e[30] !== C || e[31] !== I || e[32] !== b ? (R = /* @__PURE__ */ te("div", { style:
|
|
2045
|
+
e[29] !== _ || e[30] !== C || e[31] !== I || e[32] !== b ? (R = /* @__PURE__ */ te("div", { style: ps, children: [
|
|
2031
2046
|
b,
|
|
2032
2047
|
_,
|
|
2033
2048
|
C,
|
|
2034
2049
|
I
|
|
2035
2050
|
] }), e[29] = _, e[30] = C, e[31] = I, e[32] = b, e[33] = R) : R = e[33];
|
|
2036
2051
|
let D;
|
|
2037
|
-
e[34] !== R || e[35] !== p || e[36] !== g || e[37] !== m || e[38] !== y ? (D = /* @__PURE__ */ te("div", { style:
|
|
2052
|
+
e[34] !== R || e[35] !== p || e[36] !== g || e[37] !== m || e[38] !== y ? (D = /* @__PURE__ */ te("div", { style: us, children: [
|
|
2038
2053
|
p,
|
|
2039
2054
|
g,
|
|
2040
2055
|
m,
|
|
@@ -2042,9 +2057,9 @@ function ps(t) {
|
|
|
2042
2057
|
R
|
|
2043
2058
|
] }), e[34] = R, e[35] = p, e[36] = g, e[37] = m, e[38] = y, e[39] = D) : D = e[39];
|
|
2044
2059
|
let A;
|
|
2045
|
-
return e[40] !== d || e[41] !== a || e[42] !== D ? (A = /* @__PURE__ */ P("section", { style:
|
|
2060
|
+
return e[40] !== d || e[41] !== a || e[42] !== D ? (A = /* @__PURE__ */ P("section", { style: ls, "aria-labelledby": a, "aria-busy": d, children: D }), e[40] = d, e[41] = a, e[42] = D, e[43] = A) : A = e[43], A;
|
|
2046
2061
|
}
|
|
2047
|
-
function
|
|
2062
|
+
function ms(t) {
|
|
2048
2063
|
const e = q(9), {
|
|
2049
2064
|
pluginID: r,
|
|
2050
2065
|
connectionID: n,
|
|
@@ -2059,17 +2074,17 @@ function gs(t) {
|
|
|
2059
2074
|
const c = le(o);
|
|
2060
2075
|
if (c.phase !== "connected") {
|
|
2061
2076
|
let a;
|
|
2062
|
-
return e[3] !== n || e[4] !== i || e[5] !== c ? (a = i ? i(c) : /* @__PURE__ */ P(
|
|
2077
|
+
return e[3] !== n || e[4] !== i || e[5] !== c ? (a = i ? i(c) : /* @__PURE__ */ P(ys, { state: c, connectionName: c.connection?.name || n }), e[3] = n, e[4] = i, e[5] = c, e[6] = a) : a = e[6], a;
|
|
2063
2078
|
}
|
|
2064
2079
|
let u;
|
|
2065
2080
|
return e[7] !== s ? (u = /* @__PURE__ */ P(Ct, { children: s }), e[7] = s, e[8] = u) : u = e[8], u;
|
|
2066
2081
|
}
|
|
2067
|
-
function
|
|
2082
|
+
function No(t) {
|
|
2068
2083
|
const e = q(7), r = Q(t.pluginID);
|
|
2069
2084
|
let n;
|
|
2070
2085
|
e[0] !== r || e[1] !== t.connectionID ? (n = JSON.stringify([r, t.connectionID]), e[0] = r, e[1] = t.connectionID, e[2] = n) : n = e[2];
|
|
2071
2086
|
let s;
|
|
2072
|
-
return e[3] !== r || e[4] !== t || e[5] !== n ? (s = /* @__PURE__ */
|
|
2087
|
+
return e[3] !== r || e[4] !== t || e[5] !== n ? (s = /* @__PURE__ */ Sn(ms, { ...t, pluginID: r, key: n }), e[3] = r, e[4] = t, e[5] = n, e[6] = s) : s = e[6], s;
|
|
2073
2088
|
}
|
|
2074
2089
|
const ze = {
|
|
2075
2090
|
supported: void 0,
|
|
@@ -2100,29 +2115,29 @@ function qe(t, e) {
|
|
|
2100
2115
|
eventVersion: 0
|
|
2101
2116
|
}, r.connections.set(e, n)), n;
|
|
2102
2117
|
}
|
|
2103
|
-
function
|
|
2118
|
+
function vs(t) {
|
|
2104
2119
|
return t && /^[0-9]+$/.test(t) ? BigInt(t) : void 0;
|
|
2105
2120
|
}
|
|
2106
|
-
function
|
|
2121
|
+
function bn(t, e) {
|
|
2107
2122
|
if (Object.is(t, e)) return !0;
|
|
2108
2123
|
if (t === null || e === null || typeof t != "object" || typeof e != "object" || Array.isArray(t) !== Array.isArray(e)) return !1;
|
|
2109
2124
|
const r = t, n = e, s = Object.keys(r);
|
|
2110
|
-
return s.length !== Object.keys(n).length ? !1 : s.every((i) => Object.prototype.hasOwnProperty.call(n, i) &&
|
|
2125
|
+
return s.length !== Object.keys(n).length ? !1 : s.every((i) => Object.prototype.hasOwnProperty.call(n, i) && bn(r[i], n[i]));
|
|
2111
2126
|
}
|
|
2112
|
-
function
|
|
2127
|
+
function bs(t, e) {
|
|
2113
2128
|
if (!t) return e;
|
|
2114
2129
|
const r = {
|
|
2115
2130
|
...e.entries
|
|
2116
2131
|
};
|
|
2117
2132
|
let n = Object.keys(t.entries).length === Object.keys(r).length;
|
|
2118
2133
|
for (const s of Object.keys(r))
|
|
2119
|
-
|
|
2134
|
+
bn(t.entries[s], r[s]) ? r[s] = t.entries[s] : n = !1;
|
|
2120
2135
|
return {
|
|
2121
2136
|
...e,
|
|
2122
2137
|
entries: n ? t.entries : r
|
|
2123
2138
|
};
|
|
2124
2139
|
}
|
|
2125
|
-
function
|
|
2140
|
+
function wn(t, e) {
|
|
2126
2141
|
const r = Fe.get(t.pluginID);
|
|
2127
2142
|
if (!r || r.retired.has(t.registrationID)) return;
|
|
2128
2143
|
if (r.registrationID !== t.registrationID) {
|
|
@@ -2141,9 +2156,9 @@ function bn(t, e) {
|
|
|
2141
2156
|
const n = t.snapshot?.connectionID ?? t.connectionID, s = n === void 0 ? [...r.connections.values()] : [r.connections.get(n)].filter((i) => !!i);
|
|
2142
2157
|
for (const i of s) {
|
|
2143
2158
|
e && i.eventVersion++;
|
|
2144
|
-
const o = i.state.transportAvailable, c =
|
|
2159
|
+
const o = i.state.transportAvailable, c = vs(t.snapshot?.revision ?? t.revision);
|
|
2145
2160
|
if (c !== void 0 && (i.revision === void 0 || c > i.revision) && (i.revision = c, Ee(i, {
|
|
2146
|
-
snapshot: t.removed ? void 0 : t.snapshot ?
|
|
2161
|
+
snapshot: t.removed ? void 0 : t.snapshot ? bs(i.state.snapshot, t.snapshot) : i.state.snapshot
|
|
2147
2162
|
})), !t.transportAvailable) {
|
|
2148
2163
|
i.epoch++, i.pending = void 0, Ee(i, {
|
|
2149
2164
|
supported: t.supported,
|
|
@@ -2178,13 +2193,13 @@ function Ye(t, e) {
|
|
|
2178
2193
|
isLoading: !0,
|
|
2179
2194
|
error: void 0
|
|
2180
2195
|
});
|
|
2181
|
-
const s = e ?
|
|
2196
|
+
const s = e ? Jn : Bn, i = Promise.resolve().then(() => {
|
|
2182
2197
|
if (!(t.epoch !== r || !t.listeners.size || t.state.supported === !1))
|
|
2183
2198
|
return s(t.pluginID, t.connectionID);
|
|
2184
2199
|
}).then((o) => {
|
|
2185
2200
|
if (!o || t.epoch !== r || !t.listeners.size || o.pluginID !== t.pluginID) return;
|
|
2186
2201
|
const c = o.snapshot?.connectionID ?? o.connectionID;
|
|
2187
|
-
c !== void 0 && c !== t.connectionID ||
|
|
2202
|
+
c !== void 0 && c !== t.connectionID || wn({
|
|
2188
2203
|
...o,
|
|
2189
2204
|
connectionID: t.connectionID
|
|
2190
2205
|
}, !1);
|
|
@@ -2201,18 +2216,18 @@ function Ye(t, e) {
|
|
|
2201
2216
|
return e || (t.pending = i), i;
|
|
2202
2217
|
}
|
|
2203
2218
|
function Ot(t, e) {
|
|
2204
|
-
return t.listeners.add(e), jt++ === 0 && (dt = W("resource/connection/metadata", (r) =>
|
|
2219
|
+
return t.listeners.add(e), jt++ === 0 && (dt = W("resource/connection/metadata", (r) => wn(r.data, !0))), t.listeners.size === 1 && Ye(t, !1), () => {
|
|
2205
2220
|
t.listeners.delete(e), t.listeners.size || (t.epoch++, t.pending = void 0, Fe.get(t.pluginID)?.connections.delete(t.connectionID)), --jt === 0 && (dt?.(), dt = void 0, Fe.clear());
|
|
2206
2221
|
};
|
|
2207
2222
|
}
|
|
2208
|
-
function
|
|
2223
|
+
function ko(t, e) {
|
|
2209
2224
|
const r = q(15), n = Q(t), s = n !== void 0 && e !== void 0;
|
|
2210
2225
|
let i;
|
|
2211
|
-
r[0] !== e || r[1] !== s || r[2] !== n ? (i = (p) => s ? Ot(qe(n, e), p) :
|
|
2226
|
+
r[0] !== e || r[1] !== s || r[2] !== n ? (i = (p) => s ? Ot(qe(n, e), p) : Es, r[0] = e, r[1] = s, r[2] = n, r[3] = i) : i = r[3];
|
|
2212
2227
|
const o = i;
|
|
2213
2228
|
let c;
|
|
2214
2229
|
r[4] !== e || r[5] !== s || r[6] !== n ? (c = () => s ? qe(n, e).state : ze, r[4] = e, r[5] = s, r[6] = n, r[7] = c) : c = r[7];
|
|
2215
|
-
const a = Me(o, c,
|
|
2230
|
+
const a = Me(o, c, ws);
|
|
2216
2231
|
let d;
|
|
2217
2232
|
r[8] !== e || r[9] !== s || r[10] !== n ? (d = () => {
|
|
2218
2233
|
const p = s ? Fe.get(n)?.connections.get(e) : void 0;
|
|
@@ -2225,12 +2240,12 @@ function Do(t, e) {
|
|
|
2225
2240
|
refresh: l
|
|
2226
2241
|
}, r[12] = l, r[13] = a, r[14] = f) : f = r[14], f;
|
|
2227
2242
|
}
|
|
2228
|
-
function
|
|
2243
|
+
function ws() {
|
|
2229
2244
|
return ze;
|
|
2230
2245
|
}
|
|
2231
|
-
function
|
|
2246
|
+
function Es() {
|
|
2232
2247
|
}
|
|
2233
|
-
function
|
|
2248
|
+
function Ss(t, e) {
|
|
2234
2249
|
const r = JSON.parse(e);
|
|
2235
2250
|
let n = /* @__PURE__ */ new Map();
|
|
2236
2251
|
return {
|
|
@@ -2244,17 +2259,17 @@ function bs(t, e) {
|
|
|
2244
2259
|
}
|
|
2245
2260
|
};
|
|
2246
2261
|
}
|
|
2247
|
-
function
|
|
2262
|
+
function Oo(t, e) {
|
|
2248
2263
|
const r = q(5), n = Q(t);
|
|
2249
2264
|
let s;
|
|
2250
2265
|
r[0] !== e ? (s = JSON.stringify([...new Set(e)]), r[0] = e, r[1] = s) : s = r[1];
|
|
2251
2266
|
const i = s;
|
|
2252
2267
|
let o;
|
|
2253
|
-
r[2] !== i || r[3] !== n ? (o =
|
|
2268
|
+
r[2] !== i || r[3] !== n ? (o = Ss(n, i), r[2] = i, r[3] = n, r[4] = o) : o = r[4];
|
|
2254
2269
|
const c = o;
|
|
2255
2270
|
return Me(c.subscribe, c.read, c.read);
|
|
2256
2271
|
}
|
|
2257
|
-
function
|
|
2272
|
+
function Cs(t, e, r) {
|
|
2258
2273
|
let n, s;
|
|
2259
2274
|
return {
|
|
2260
2275
|
read() {
|
|
@@ -2263,35 +2278,35 @@ function ws(t, e, r) {
|
|
|
2263
2278
|
}
|
|
2264
2279
|
};
|
|
2265
2280
|
}
|
|
2266
|
-
function
|
|
2281
|
+
function To(t, e, r) {
|
|
2267
2282
|
const n = q(7), s = Q(t);
|
|
2268
2283
|
let i;
|
|
2269
|
-
n[0] !== e || n[1] !== s ? (i = (a) => e === void 0 ?
|
|
2284
|
+
n[0] !== e || n[1] !== s ? (i = (a) => e === void 0 ? Is : Ot(qe(s, e), a), n[0] = e, n[1] = s, n[2] = i) : i = n[2];
|
|
2270
2285
|
const o = i;
|
|
2271
2286
|
let c;
|
|
2272
|
-
n[3] !== e || n[4] !== s || n[5] !== r ? (c =
|
|
2287
|
+
n[3] !== e || n[4] !== s || n[5] !== r ? (c = Cs(s, e, r), n[3] = e, n[4] = s, n[5] = r, n[6] = c) : c = n[6];
|
|
2273
2288
|
const u = c;
|
|
2274
2289
|
return Me(o, u.read, u.read);
|
|
2275
2290
|
}
|
|
2276
|
-
function
|
|
2291
|
+
function Is() {
|
|
2277
2292
|
}
|
|
2278
|
-
function
|
|
2293
|
+
function Ao(t, e, r) {
|
|
2279
2294
|
if (!e || !t?.active) return;
|
|
2280
2295
|
const n = t.entries[r];
|
|
2281
2296
|
return n?.state === "current" && typeof n.value == "string" ? n.value : void 0;
|
|
2282
2297
|
}
|
|
2283
|
-
function
|
|
2298
|
+
function _s(t, e) {
|
|
2284
2299
|
return e === null ? t === null : Array.isArray(e) ? Array.isArray(t) : typeof e == "object" ? typeof t == "object" && t !== null && !Array.isArray(t) : typeof t == typeof e;
|
|
2285
2300
|
}
|
|
2286
|
-
function
|
|
2301
|
+
function Po(t, e, r) {
|
|
2287
2302
|
const n = q(29), s = Q(t), i = ce();
|
|
2288
2303
|
let o;
|
|
2289
2304
|
n[0] !== e || n[1] !== s ? (o = [s, "data", e], n[0] = e, n[1] = s, n[2] = o) : o = n[2];
|
|
2290
2305
|
const c = o;
|
|
2291
2306
|
let u;
|
|
2292
2307
|
n[3] !== r || n[4] !== e || n[5] !== s ? (u = async () => {
|
|
2293
|
-
const w = await
|
|
2294
|
-
return w == null ? r :
|
|
2308
|
+
const w = await Hn(s, e);
|
|
2309
|
+
return w == null ? r : _s(w, r) ? w : (console.warn(`[usePluginData] stored value for "${e}" has unexpected type (expected ${Array.isArray(r) ? "array" : typeof r}, got ${Array.isArray(w) ? "array" : typeof w}). Using default.`), r);
|
|
2295
2310
|
}, n[3] = r, n[4] = e, n[5] = s, n[6] = u) : u = n[6];
|
|
2296
2311
|
let a;
|
|
2297
2312
|
n[7] !== c || n[8] !== u ? (a = {
|
|
@@ -2301,7 +2316,7 @@ function Oo(t, e, r) {
|
|
|
2301
2316
|
const d = G(a);
|
|
2302
2317
|
let l;
|
|
2303
2318
|
n[10] !== e || n[11] !== s ? (l = async (w) => {
|
|
2304
|
-
await
|
|
2319
|
+
await Vn(s, e, w);
|
|
2305
2320
|
}, n[10] = e, n[11] = s, n[12] = l) : l = n[12];
|
|
2306
2321
|
let f, p, v;
|
|
2307
2322
|
n[13] !== i || n[14] !== c ? (f = async (w) => {
|
|
@@ -2338,17 +2353,17 @@ function Oo(t, e, r) {
|
|
|
2338
2353
|
isLoading: d.isLoading
|
|
2339
2354
|
}, n[25] = d.isLoading, n[26] = m, n[27] = y, n[28] = b) : b = n[28], b;
|
|
2340
2355
|
}
|
|
2341
|
-
const
|
|
2342
|
-
const t = $e(
|
|
2356
|
+
const xo = () => {
|
|
2357
|
+
const t = $e(Br);
|
|
2343
2358
|
if (!t)
|
|
2344
2359
|
throw new Error("useRightDrawer must be used within a RightDrawerProvider");
|
|
2345
2360
|
return t;
|
|
2346
|
-
},
|
|
2347
|
-
const t = $e(
|
|
2361
|
+
}, En = () => {
|
|
2362
|
+
const t = $e(zr);
|
|
2348
2363
|
if (t === void 0)
|
|
2349
2364
|
throw new Error("useBottomDrawer must be used within a BottomDrawerProvider");
|
|
2350
2365
|
return t;
|
|
2351
|
-
},
|
|
2366
|
+
}, Lo = ({
|
|
2352
2367
|
pluginID: t
|
|
2353
2368
|
}) => {
|
|
2354
2369
|
const e = Q(t), {
|
|
@@ -2356,7 +2371,7 @@ const To = () => {
|
|
|
2356
2371
|
} = ye(), {
|
|
2357
2372
|
createTab: n,
|
|
2358
2373
|
updateTab: s
|
|
2359
|
-
} =
|
|
2374
|
+
} = En();
|
|
2360
2375
|
return {
|
|
2361
2376
|
createSession: ee({
|
|
2362
2377
|
mutationFn: async ({
|
|
@@ -2382,13 +2397,13 @@ const To = () => {
|
|
|
2382
2397
|
recovery: d
|
|
2383
2398
|
}
|
|
2384
2399
|
});
|
|
2385
|
-
const f =
|
|
2400
|
+
const f = Pr.createFrom({
|
|
2386
2401
|
command: ["/bin/bash"],
|
|
2387
2402
|
tty: !0,
|
|
2388
2403
|
...a
|
|
2389
2404
|
});
|
|
2390
2405
|
try {
|
|
2391
|
-
const p = await
|
|
2406
|
+
const p = await Yn(e, o, f);
|
|
2392
2407
|
if (!p) throw new Error("Failed to create session: null response");
|
|
2393
2408
|
return s({
|
|
2394
2409
|
id: l
|
|
@@ -2430,14 +2445,14 @@ const To = () => {
|
|
|
2430
2445
|
}
|
|
2431
2446
|
}).mutateAsync
|
|
2432
2447
|
};
|
|
2433
|
-
},
|
|
2448
|
+
}, Fo = (t) => {
|
|
2434
2449
|
const e = q(15), {
|
|
2435
2450
|
pluginID: r
|
|
2436
2451
|
} = t, n = Q(r), {
|
|
2437
2452
|
showSnackbar: s
|
|
2438
2453
|
} = ye(), {
|
|
2439
2454
|
createTab: i
|
|
2440
|
-
} =
|
|
2455
|
+
} = En();
|
|
2441
2456
|
let o;
|
|
2442
2457
|
e[0] !== i || e[1] !== n ? (o = async (v) => {
|
|
2443
2458
|
const {
|
|
@@ -2453,7 +2468,7 @@ const To = () => {
|
|
|
2453
2468
|
follow: I,
|
|
2454
2469
|
tailLines: R,
|
|
2455
2470
|
params: D
|
|
2456
|
-
} = v, S = await
|
|
2471
|
+
} = v, S = await Zn(n, h, {
|
|
2457
2472
|
resource_key: g,
|
|
2458
2473
|
resource_id: m,
|
|
2459
2474
|
resource_data: y,
|
|
@@ -2492,7 +2507,7 @@ const To = () => {
|
|
|
2492
2507
|
e[8] !== s ? (d = se(s, "Failed to close log session"), e[8] = s, e[9] = d) : d = e[9];
|
|
2493
2508
|
let l;
|
|
2494
2509
|
e[10] !== d ? (l = {
|
|
2495
|
-
mutationFn:
|
|
2510
|
+
mutationFn: Ds,
|
|
2496
2511
|
onError: d
|
|
2497
2512
|
}, e[10] = d, e[11] = l) : l = e[11];
|
|
2498
2513
|
const f = ee(l);
|
|
@@ -2502,21 +2517,21 @@ const To = () => {
|
|
|
2502
2517
|
closeLogSession: f.mutateAsync
|
|
2503
2518
|
}, e[12] = f.mutateAsync, e[13] = a.mutateAsync, e[14] = p) : p = e[14], p;
|
|
2504
2519
|
};
|
|
2505
|
-
async function
|
|
2506
|
-
await
|
|
2520
|
+
async function Ds(t) {
|
|
2521
|
+
await Xn(t);
|
|
2507
2522
|
}
|
|
2508
|
-
const
|
|
2523
|
+
const qo = () => {
|
|
2509
2524
|
const t = q(1);
|
|
2510
2525
|
let e;
|
|
2511
2526
|
return t[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (e = {
|
|
2512
2527
|
queryKey: ["metric", "providers"],
|
|
2513
|
-
queryFn:
|
|
2528
|
+
queryFn: er,
|
|
2514
2529
|
staleTime: 3e4
|
|
2515
2530
|
}, t[0] = e) : e = t[0], G(e);
|
|
2516
|
-
},
|
|
2531
|
+
}, Rs = (t) => {
|
|
2517
2532
|
const e = q(7);
|
|
2518
2533
|
let r, n;
|
|
2519
|
-
e[0] !== t ? (r = ["metric", "providers", t], n = () =>
|
|
2534
|
+
e[0] !== t ? (r = ["metric", "providers", t], n = () => tr(t), e[0] = t, e[1] = r, e[2] = n) : (r = e[1], n = e[2]);
|
|
2520
2535
|
const s = !!t;
|
|
2521
2536
|
let i;
|
|
2522
2537
|
return e[3] !== r || e[4] !== n || e[5] !== s ? (i = {
|
|
@@ -2525,7 +2540,7 @@ const xo = () => {
|
|
|
2525
2540
|
enabled: s,
|
|
2526
2541
|
staleTime: 3e4
|
|
2527
2542
|
}, e[3] = r, e[4] = n, e[5] = s, e[6] = i) : i = e[6], G(i);
|
|
2528
|
-
},
|
|
2543
|
+
}, $o = (t) => {
|
|
2529
2544
|
const e = q(45), {
|
|
2530
2545
|
connectionID: r,
|
|
2531
2546
|
resourceKey: n,
|
|
@@ -2546,7 +2561,7 @@ const xo = () => {
|
|
|
2546
2561
|
const m = g, y = l === void 0 ? 0 : l, b = p === void 0 ? 0 : p, w = v === void 0 ? !0 : v, {
|
|
2547
2562
|
data: E,
|
|
2548
2563
|
isLoading: _
|
|
2549
|
-
} =
|
|
2564
|
+
} = Rs(n);
|
|
2550
2565
|
let C;
|
|
2551
2566
|
e[2] !== E ? (C = E ?? [], e[2] = E, e[3] = C) : C = e[3];
|
|
2552
2567
|
const I = C, R = f ? Math.max(Math.floor((f.end.getTime() - f.start.getTime()) / 250), 15e3) * 1e6 : 0;
|
|
@@ -2558,7 +2573,7 @@ const xo = () => {
|
|
|
2558
2573
|
e[8] !== r || e[9] !== m || e[10] !== a || e[11] !== c || e[12] !== s || e[13] !== n || e[14] !== h || e[15] !== u || e[16] !== y || e[17] !== D || e[18] !== A ? (N = ["metric", "query", r, n, s, h, c, u, a, m, y, D, A], e[8] = r, e[9] = m, e[10] = a, e[11] = c, e[12] = s, e[13] = n, e[14] = h, e[15] = u, e[16] = y, e[17] = D, e[18] = A, e[19] = N) : N = e[19];
|
|
2559
2574
|
let $;
|
|
2560
2575
|
e[20] !== r || e[21] !== m || e[22] !== a || e[23] !== c || e[24] !== o || e[25] !== s || e[26] !== n || e[27] !== h || e[28] !== u || e[29] !== y || e[30] !== R || e[31] !== f?.end || e[32] !== f?.start ? ($ = async () => {
|
|
2561
|
-
const K = await
|
|
2576
|
+
const K = await nr(r, {
|
|
2562
2577
|
resource_key: n,
|
|
2563
2578
|
resource_id: s,
|
|
2564
2579
|
resource_namespace: h,
|
|
@@ -2595,7 +2610,7 @@ const xo = () => {
|
|
|
2595
2610
|
error: M,
|
|
2596
2611
|
refetch: F.refetch
|
|
2597
2612
|
}, e[39] = F.refetch, e[40] = I, e[41] = T, e[42] = x, e[43] = M, e[44] = J) : J = e[44], J;
|
|
2598
|
-
},
|
|
2613
|
+
}, Mo = (t) => {
|
|
2599
2614
|
const {
|
|
2600
2615
|
pluginID: e,
|
|
2601
2616
|
connectionID: r,
|
|
@@ -2612,7 +2627,7 @@ const xo = () => {
|
|
|
2612
2627
|
} = t, p = Q(e), [v, h] = pe(null), [g, m] = pe(null), [y, b] = pe(!1), [w, E] = pe(null), _ = ne(null), C = we(async () => {
|
|
2613
2628
|
if (!(!f || !p || !r || !n))
|
|
2614
2629
|
try {
|
|
2615
|
-
const R = await
|
|
2630
|
+
const R = await rr(p, r, {
|
|
2616
2631
|
resource_key: n,
|
|
2617
2632
|
resource_id: s,
|
|
2618
2633
|
resource_namespace: i,
|
|
@@ -2673,14 +2688,14 @@ const xo = () => {
|
|
|
2673
2688
|
stop: I
|
|
2674
2689
|
};
|
|
2675
2690
|
}, xe = ["networker", "portforward", "all-sessions"];
|
|
2676
|
-
function
|
|
2691
|
+
function Uo() {
|
|
2677
2692
|
const t = q(17), {
|
|
2678
2693
|
showSnackbar: e
|
|
2679
2694
|
} = ye(), r = ce();
|
|
2680
2695
|
let n;
|
|
2681
2696
|
t[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (n = {
|
|
2682
2697
|
queryKey: [...xe],
|
|
2683
|
-
queryFn:
|
|
2698
|
+
queryFn: Os,
|
|
2684
2699
|
retry: !1
|
|
2685
2700
|
}, t[0] = n) : n = t[0];
|
|
2686
2701
|
const s = G(n);
|
|
@@ -2712,7 +2727,7 @@ function qo() {
|
|
|
2712
2727
|
}, t[8] = r, t[9] = d) : d = t[9];
|
|
2713
2728
|
let l;
|
|
2714
2729
|
t[10] !== a || t[11] !== d ? (l = {
|
|
2715
|
-
mutationFn:
|
|
2730
|
+
mutationFn: ks,
|
|
2716
2731
|
onError: a,
|
|
2717
2732
|
onSuccess: d
|
|
2718
2733
|
}, t[10] = a, t[11] = d, t[12] = l) : l = t[12];
|
|
@@ -2722,24 +2737,24 @@ function qo() {
|
|
|
2722
2737
|
sessions: s,
|
|
2723
2738
|
activeSessions: u,
|
|
2724
2739
|
closeSession: f.mutateAsync,
|
|
2725
|
-
openInBrowser:
|
|
2740
|
+
openInBrowser: Ns
|
|
2726
2741
|
}, t[13] = u, t[14] = f.mutateAsync, t[15] = s, t[16] = p) : p = t[16], p;
|
|
2727
2742
|
}
|
|
2728
|
-
function
|
|
2743
|
+
function Ns(t) {
|
|
2729
2744
|
return en(`http://localhost:${t}`);
|
|
2730
2745
|
}
|
|
2731
|
-
async function
|
|
2746
|
+
async function ks(t) {
|
|
2732
2747
|
return Yt(t);
|
|
2733
2748
|
}
|
|
2734
|
-
async function
|
|
2735
|
-
return
|
|
2749
|
+
async function Os() {
|
|
2750
|
+
return sr().catch(Ts);
|
|
2736
2751
|
}
|
|
2737
|
-
function
|
|
2752
|
+
function Ts(t) {
|
|
2738
2753
|
if (he(t).detail.includes("not found"))
|
|
2739
2754
|
return [];
|
|
2740
2755
|
throw t;
|
|
2741
2756
|
}
|
|
2742
|
-
function
|
|
2757
|
+
function Wo(t) {
|
|
2743
2758
|
const e = q(36), {
|
|
2744
2759
|
pluginID: r,
|
|
2745
2760
|
connectionID: n,
|
|
@@ -2751,7 +2766,7 @@ function $o(t) {
|
|
|
2751
2766
|
showSnackbar: u
|
|
2752
2767
|
} = ye(), a = ce();
|
|
2753
2768
|
let d;
|
|
2754
|
-
e[4] !== n || e[5] !== i || e[6] !== s || e[7] !== u ? (d = async () =>
|
|
2769
|
+
e[4] !== n || e[5] !== i || e[6] !== s || e[7] !== u ? (d = async () => or(i, n, xr.createFrom({
|
|
2755
2770
|
resource_id: s,
|
|
2756
2771
|
connection_id: n
|
|
2757
2772
|
})).catch((C) => {
|
|
@@ -2789,7 +2804,7 @@ function $o(t) {
|
|
|
2789
2804
|
},
|
|
2790
2805
|
labels: I.labels ?? {},
|
|
2791
2806
|
params: I.parameters ?? {}
|
|
2792
|
-
}, D = await
|
|
2807
|
+
}, D = await ir(i, n, R);
|
|
2793
2808
|
if (!D)
|
|
2794
2809
|
throw new Error("Failed to start port forwarding: null response");
|
|
2795
2810
|
return I.openInBrowser && en(`http://localhost:${D.local_port}`), D;
|
|
@@ -2823,7 +2838,7 @@ function $o(t) {
|
|
|
2823
2838
|
}, e[26] = a, e[27] = c, e[28] = b) : b = e[28];
|
|
2824
2839
|
let w;
|
|
2825
2840
|
e[29] !== y || e[30] !== b ? (w = {
|
|
2826
|
-
mutationFn:
|
|
2841
|
+
mutationFn: As,
|
|
2827
2842
|
onError: y,
|
|
2828
2843
|
onSuccess: b
|
|
2829
2844
|
}, e[29] = y, e[30] = b, e[31] = w) : w = e[31];
|
|
@@ -2835,18 +2850,18 @@ function $o(t) {
|
|
|
2835
2850
|
close: E.mutateAsync
|
|
2836
2851
|
}, e[32] = E.mutateAsync, e[33] = m.mutateAsync, e[34] = f, e[35] = _) : _ = e[35], _;
|
|
2837
2852
|
}
|
|
2838
|
-
async function
|
|
2853
|
+
async function As(t) {
|
|
2839
2854
|
const {
|
|
2840
2855
|
opts: e
|
|
2841
2856
|
} = t;
|
|
2842
2857
|
return Yt(e.sessionID);
|
|
2843
2858
|
}
|
|
2844
|
-
const
|
|
2845
|
-
const t = L.useContext(
|
|
2859
|
+
const Qo = () => {
|
|
2860
|
+
const t = L.useContext(Jr);
|
|
2846
2861
|
if (!t)
|
|
2847
2862
|
throw new Error("useConfirmationModal must be used within a ConfirmationModalProvider");
|
|
2848
2863
|
return t;
|
|
2849
|
-
},
|
|
2864
|
+
}, jo = (t) => {
|
|
2850
2865
|
const e = q(31), {
|
|
2851
2866
|
pluginID: r,
|
|
2852
2867
|
request: n,
|
|
@@ -2897,7 +2912,7 @@ const Mo = () => {
|
|
|
2897
2912
|
signal: A,
|
|
2898
2913
|
queryKey: N
|
|
2899
2914
|
} = D;
|
|
2900
|
-
return l(N, A, () =>
|
|
2915
|
+
return l(N, A, () => cr(o, n));
|
|
2901
2916
|
} : ie, e[19] = l, e[20] = o, e[21] = g, e[22] = n, e[23] = _) : _ = e[23];
|
|
2902
2917
|
let C;
|
|
2903
2918
|
e[24] !== g || e[25] !== h || e[26] !== _ ? (C = {
|
|
@@ -2912,13 +2927,13 @@ const Mo = () => {
|
|
|
2912
2927
|
resource: I,
|
|
2913
2928
|
mutate: E
|
|
2914
2929
|
}, e[28] = E, e[29] = I, e[30] = R) : R = e[30], R;
|
|
2915
|
-
},
|
|
2930
|
+
}, Ko = (t) => {
|
|
2916
2931
|
const e = q(11);
|
|
2917
2932
|
let r;
|
|
2918
2933
|
e[0] !== t.area || e[1] !== t.plugin || e[2] !== t.resource ? (r = ["component", t.plugin, t.resource, t.area], e[0] = t.area, e[1] = t.plugin, e[2] = t.resource, e[3] = r) : r = e[3];
|
|
2919
2934
|
const n = r;
|
|
2920
2935
|
let s;
|
|
2921
|
-
e[4] !== t ? (s = async () =>
|
|
2936
|
+
e[4] !== t ? (s = async () => ar(t), e[4] = t, e[5] = s) : s = e[5];
|
|
2922
2937
|
let i;
|
|
2923
2938
|
e[6] !== n || e[7] !== s ? (i = {
|
|
2924
2939
|
queryKey: n,
|
|
@@ -2929,7 +2944,7 @@ const Mo = () => {
|
|
|
2929
2944
|
return e[9] !== o ? (c = {
|
|
2930
2945
|
component: o
|
|
2931
2946
|
}, e[9] = o, e[10] = c) : c = e[10], c;
|
|
2932
|
-
},
|
|
2947
|
+
}, Go = (t) => {
|
|
2933
2948
|
const e = q(18), {
|
|
2934
2949
|
pluginID: r,
|
|
2935
2950
|
route: n,
|
|
@@ -2950,7 +2965,7 @@ const Mo = () => {
|
|
|
2950
2965
|
signal: m,
|
|
2951
2966
|
queryKey: y
|
|
2952
2967
|
} = g;
|
|
2953
|
-
return a(y, m, () =>
|
|
2968
|
+
return a(y, m, () => lr(o, n));
|
|
2954
2969
|
} : ie, e[7] = a, e[8] = o, e[9] = d, e[10] = n, e[11] = f) : f = e[11];
|
|
2955
2970
|
let p;
|
|
2956
2971
|
e[12] !== d || e[13] !== l || e[14] !== f ? (p = {
|
|
@@ -2964,14 +2979,14 @@ const Mo = () => {
|
|
|
2964
2979
|
return e[16] !== v ? (h = {
|
|
2965
2980
|
groups: v
|
|
2966
2981
|
}, e[16] = v, e[17] = h) : h = e[17], h;
|
|
2967
|
-
},
|
|
2982
|
+
}, zo = (t) => {
|
|
2968
2983
|
const e = q(28), {
|
|
2969
2984
|
pluginID: r,
|
|
2970
2985
|
searches: n,
|
|
2971
2986
|
enabled: s
|
|
2972
2987
|
} = t, i = s === void 0 ? !0 : s, o = Q(r);
|
|
2973
2988
|
let c;
|
|
2974
|
-
e[0] !== i || e[1] !== n ? (c = JSON.stringify(i ? [...new Set(n.map(
|
|
2989
|
+
e[0] !== i || e[1] !== n ? (c = JSON.stringify(i ? [...new Set(n.map(Ps))].sort() : []), e[0] = i, e[1] = n, e[2] = c) : c = e[2];
|
|
2975
2990
|
const u = c;
|
|
2976
2991
|
let a;
|
|
2977
2992
|
if (e[3] !== u || e[4] !== o) {
|
|
@@ -2982,7 +2997,7 @@ const Mo = () => {
|
|
|
2982
2997
|
a = e[5];
|
|
2983
2998
|
const d = a;
|
|
2984
2999
|
let l, f;
|
|
2985
|
-
e[8] !== d ? (l = () => JSON.stringify([...d.values()].map(
|
|
3000
|
+
e[8] !== d ? (l = () => JSON.stringify([...d.values()].map(xs)), f = (y) => {
|
|
2986
3001
|
const b = [...d.values()].map((w) => w.subscribe(y));
|
|
2987
3002
|
return () => {
|
|
2988
3003
|
for (const w of b)
|
|
@@ -3010,7 +3025,7 @@ const Mo = () => {
|
|
|
3010
3025
|
signal: C,
|
|
3011
3026
|
queryKey: I
|
|
3012
3027
|
} = _;
|
|
3013
|
-
return h(I, C, () =>
|
|
3028
|
+
return h(I, C, () => ur(o, b), w);
|
|
3014
3029
|
} : ie,
|
|
3015
3030
|
retry: !1,
|
|
3016
3031
|
enabled: E
|
|
@@ -3021,15 +3036,15 @@ const Mo = () => {
|
|
|
3021
3036
|
let m;
|
|
3022
3037
|
return e[26] !== g ? (m = {
|
|
3023
3038
|
queries: g
|
|
3024
|
-
}, e[26] = g, e[27] = m) : m = e[27],
|
|
3039
|
+
}, e[26] = g, e[27] = m) : m = e[27], Dn(m);
|
|
3025
3040
|
};
|
|
3026
|
-
function
|
|
3041
|
+
function Ps(t) {
|
|
3027
3042
|
return t.request.target.route.connection;
|
|
3028
3043
|
}
|
|
3029
|
-
function
|
|
3044
|
+
function xs(t) {
|
|
3030
3045
|
return t.getSnapshot().phase;
|
|
3031
3046
|
}
|
|
3032
|
-
const
|
|
3047
|
+
const Bo = (t) => {
|
|
3033
3048
|
const e = q(21), {
|
|
3034
3049
|
pluginID: r,
|
|
3035
3050
|
route: n,
|
|
@@ -3069,7 +3084,7 @@ const Ko = (t) => {
|
|
|
3069
3084
|
return e[19] !== h ? (g = {
|
|
3070
3085
|
resourceType: h
|
|
3071
3086
|
}, e[19] = h, e[20] = g) : g = e[20], g;
|
|
3072
|
-
},
|
|
3087
|
+
}, Jo = (t) => {
|
|
3073
3088
|
const e = q(18), {
|
|
3074
3089
|
pluginID: r,
|
|
3075
3090
|
route: n,
|
|
@@ -3098,7 +3113,7 @@ const Ko = (t) => {
|
|
|
3098
3113
|
e[12] !== d || e[13] !== l || e[14] !== f ? (p = {
|
|
3099
3114
|
queryKey: l,
|
|
3100
3115
|
queryFn: f,
|
|
3101
|
-
select:
|
|
3116
|
+
select: Ls,
|
|
3102
3117
|
enabled: d,
|
|
3103
3118
|
retry: !1
|
|
3104
3119
|
}, e[12] = d, e[13] = l, e[14] = f, e[15] = p) : p = e[15];
|
|
@@ -3108,7 +3123,7 @@ const Ko = (t) => {
|
|
|
3108
3123
|
resourceTypes: v
|
|
3109
3124
|
}, e[16] = v, e[17] = h) : h = e[17], h;
|
|
3110
3125
|
};
|
|
3111
|
-
function
|
|
3126
|
+
function Ls(t) {
|
|
3112
3127
|
return t.types;
|
|
3113
3128
|
}
|
|
3114
3129
|
function Kt(t, e, r = !1, n = !1) {
|
|
@@ -3150,7 +3165,7 @@ function Kt(t, e, r = !1, n = !1) {
|
|
|
3150
3165
|
}
|
|
3151
3166
|
};
|
|
3152
3167
|
}
|
|
3153
|
-
function
|
|
3168
|
+
function Fs(t, e, r, n) {
|
|
3154
3169
|
const s = q(36);
|
|
3155
3170
|
let i;
|
|
3156
3171
|
s[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (i = /* @__PURE__ */ new Map(), s[0] = i) : i = s[0];
|
|
@@ -3224,12 +3239,12 @@ function Ps(t, e, r, n) {
|
|
|
3224
3239
|
};
|
|
3225
3240
|
}, A = [t, e, C, l, h, y, p], s[27] = p, s[28] = y, s[29] = l, s[30] = C, s[31] = t, s[32] = e, s[33] = h, s[34] = D, s[35] = A) : (D = s[34], A = s[35]), ft(D, A), R;
|
|
3226
3241
|
}
|
|
3227
|
-
const
|
|
3242
|
+
const qs = {
|
|
3228
3243
|
getSnapshot: () => {
|
|
3229
3244
|
},
|
|
3230
3245
|
subscribe: () => () => {
|
|
3231
3246
|
}
|
|
3232
|
-
},
|
|
3247
|
+
}, Ho = ({
|
|
3233
3248
|
pluginID: t,
|
|
3234
3249
|
request: e,
|
|
3235
3250
|
enabled: r = !0,
|
|
@@ -3257,7 +3272,7 @@ const xs = {
|
|
|
3257
3272
|
}), g = L.useMemo(() => v ? {
|
|
3258
3273
|
subscribe: Xe(i, p).subscribe,
|
|
3259
3274
|
getSnapshot: () => mt(i, p)
|
|
3260
|
-
} :
|
|
3275
|
+
} : qs, [i, p, v]), m = L.useSyncExternalStore(g.subscribe, g.getSnapshot, g.getSnapshot), y = ue(i, p), b = v && h.phase === "connected", w = f ? pt([i, f.targetId, f.request.target, s]) : void 0, E = L.useCallback((U) => s ? [...Ne.list(i, U), "collection"] : Ne.list(i, U), [i, s]), _ = L.useCallback(async (U, V, me) => {
|
|
3261
3276
|
if (!s) return y(me, V, () => Ft(i, U));
|
|
3262
3277
|
const ve = mt(i, p), be = /* @__PURE__ */ new Map(), Ce = /* @__PURE__ */ new Set();
|
|
3263
3278
|
let oe, Ie;
|
|
@@ -3338,7 +3353,7 @@ const xs = {
|
|
|
3338
3353
|
acquiredRequest: N,
|
|
3339
3354
|
generation: m,
|
|
3340
3355
|
enabled: O
|
|
3341
|
-
}), [i, N, m, O]), [T, x] = L.useState(), M = O && T?.scope === F ? T.state : j.WatchStateIdle, J = O && T?.scope === F ? T.error : void 0, K = O && T?.scope === F && T.live, z = L.useCallback(() => m !== void 0 && je(i, p, m), [i, p, m]), H =
|
|
3356
|
+
}), [i, N, m, O]), [T, x] = L.useState(), M = O && T?.scope === F ? T.state : j.WatchStateIdle, J = O && T?.scope === F ? T.error : void 0, K = O && T?.scope === F && T.live, z = L.useCallback(() => m !== void 0 && je(i, p, m), [i, p, m]), H = Fs(o, $, M, {
|
|
3342
3357
|
enabled: O,
|
|
3343
3358
|
isCurrent: z,
|
|
3344
3359
|
collection: s
|
|
@@ -3393,7 +3408,7 @@ const xs = {
|
|
|
3393
3408
|
error: Y
|
|
3394
3409
|
}));
|
|
3395
3410
|
const xt = B.current.then(async () => {
|
|
3396
|
-
oe() && (await
|
|
3411
|
+
oe() && (await dr(i, V), ve = !0, oe() && (Ce = fr(i, U), await Ce, Ie({
|
|
3397
3412
|
live: !0
|
|
3398
3413
|
})));
|
|
3399
3414
|
}).catch((Y) => {
|
|
@@ -3405,7 +3420,7 @@ const xs = {
|
|
|
3405
3420
|
});
|
|
3406
3421
|
return B.current = xt, () => {
|
|
3407
3422
|
me = !1, At(), Pt.cancel(), Ce?.cancel(), B.current = xt.then(async () => {
|
|
3408
|
-
ve && await
|
|
3423
|
+
ve && await pr(i, V);
|
|
3409
3424
|
}).catch((Y) => {
|
|
3410
3425
|
Le(u.current, Y, "Failed to unsubscribe from resource updates");
|
|
3411
3426
|
});
|
|
@@ -3429,7 +3444,7 @@ const xs = {
|
|
|
3429
3444
|
watchError: X ? J ?? (M === j.WatchStateError || M === j.WatchStateFailed || M === j.WatchStateForbidden ? !0 : void 0) : void 0,
|
|
3430
3445
|
guarantee: X && K ? "bestEffort" : void 0
|
|
3431
3446
|
};
|
|
3432
|
-
},
|
|
3447
|
+
}, Vo = (t) => {
|
|
3433
3448
|
const e = q(13), {
|
|
3434
3449
|
pluginID: r
|
|
3435
3450
|
} = t, n = Q(r), s = ce(), {
|
|
@@ -3457,7 +3472,7 @@ const xs = {
|
|
|
3457
3472
|
mutate: d.mutateAsync,
|
|
3458
3473
|
mutation: d
|
|
3459
3474
|
}, e[11] = d, e[12] = l) : l = e[12], l;
|
|
3460
|
-
},
|
|
3475
|
+
}, Yo = (t) => {
|
|
3461
3476
|
const e = q(25), {
|
|
3462
3477
|
pluginID: r,
|
|
3463
3478
|
route: n,
|
|
@@ -3479,7 +3494,7 @@ const xs = {
|
|
|
3479
3494
|
signal: E,
|
|
3480
3495
|
queryKey: _
|
|
3481
3496
|
} = w;
|
|
3482
|
-
return f(_, E, () =>
|
|
3497
|
+
return f(_, E, () => gr(c, n, s));
|
|
3483
3498
|
} : ie, e[8] = o, e[9] = f, e[10] = c, e[11] = l, e[12] = n, e[13] = s, e[14] = v) : v = e[14];
|
|
3484
3499
|
const h = o && !!c && !!n.connection && !!s && l.phase === "connected";
|
|
3485
3500
|
let g;
|
|
@@ -3498,14 +3513,14 @@ const xs = {
|
|
|
3498
3513
|
isLoading: m.isLoading,
|
|
3499
3514
|
error: m.error
|
|
3500
3515
|
}, e[21] = m.error, e[22] = m.isLoading, e[23] = y, e[24] = b) : b = e[24], b;
|
|
3501
|
-
},
|
|
3516
|
+
}, Zo = (t) => {
|
|
3502
3517
|
const e = q(15), {
|
|
3503
3518
|
pluginID: r
|
|
3504
3519
|
} = t, n = Q(r), s = ce(), {
|
|
3505
3520
|
showSnackbar: i
|
|
3506
3521
|
} = ye();
|
|
3507
3522
|
let o;
|
|
3508
|
-
e[0] !== n ? (o = async (f) => (await et(n, f.route.connection),
|
|
3523
|
+
e[0] !== n ? (o = async (f) => (await et(n, f.route.connection), hr(n, f)), e[0] = n, e[1] = o) : o = e[1];
|
|
3509
3524
|
let c;
|
|
3510
3525
|
e[2] !== n || e[3] !== s ? (c = async () => {
|
|
3511
3526
|
await s.invalidateQueries({
|
|
@@ -3529,7 +3544,7 @@ const xs = {
|
|
|
3529
3544
|
isExecuting: d.isPending,
|
|
3530
3545
|
error: d.error
|
|
3531
3546
|
}, e[11] = d.error, e[12] = d.isPending, e[13] = d.mutateAsync, e[14] = l) : l = e[14], l;
|
|
3532
|
-
},
|
|
3547
|
+
}, Xo = (t) => {
|
|
3533
3548
|
const e = q(27), {
|
|
3534
3549
|
pluginID: r,
|
|
3535
3550
|
route: n,
|
|
@@ -3551,7 +3566,7 @@ const xs = {
|
|
|
3551
3566
|
queryKey: E
|
|
3552
3567
|
} = b;
|
|
3553
3568
|
return d(E, w, async () => {
|
|
3554
|
-
const _ = await d(E, w, () =>
|
|
3569
|
+
const _ = await d(E, w, () => yr(o, n)), C = [], I = /* @__PURE__ */ new Set();
|
|
3555
3570
|
for (const R of _) {
|
|
3556
3571
|
const D = R.binding.documentRef;
|
|
3557
3572
|
if (!D)
|
|
@@ -3564,7 +3579,7 @@ const xs = {
|
|
|
3564
3579
|
signal: $,
|
|
3565
3580
|
queryKey: S
|
|
3566
3581
|
} = N;
|
|
3567
|
-
return d(S, AbortSignal.any([w, $]), () =>
|
|
3582
|
+
return d(S, AbortSignal.any([w, $]), () => mr(o, n, D));
|
|
3568
3583
|
},
|
|
3569
3584
|
staleTime: 1 / 0
|
|
3570
3585
|
})), I.add(A));
|
|
@@ -3606,7 +3621,7 @@ function Gt(t) {
|
|
|
3606
3621
|
errorCount: e.filter((r) => r === j.WatchStateError || r === j.WatchStateFailed).length
|
|
3607
3622
|
};
|
|
3608
3623
|
}
|
|
3609
|
-
const
|
|
3624
|
+
const ei = (t) => {
|
|
3610
3625
|
const e = q(38), {
|
|
3611
3626
|
pluginID: r,
|
|
3612
3627
|
route: n,
|
|
@@ -3652,7 +3667,7 @@ const Yo = (t) => {
|
|
|
3652
3667
|
queryKey: l,
|
|
3653
3668
|
queryFn: m,
|
|
3654
3669
|
enabled: y,
|
|
3655
|
-
refetchInterval:
|
|
3670
|
+
refetchInterval: Ms
|
|
3656
3671
|
}, e[12] = l, e[13] = m, e[14] = y, e[15] = b) : b = e[15];
|
|
3657
3672
|
const w = G(b);
|
|
3658
3673
|
let E, _;
|
|
@@ -3681,7 +3696,7 @@ const Yo = (t) => {
|
|
|
3681
3696
|
e[26] !== w.data?.resources ? (R = Object.values(w.data?.resources ?? {}), e[26] = w.data?.resources, e[27] = R) : R = e[27];
|
|
3682
3697
|
const D = R;
|
|
3683
3698
|
let A;
|
|
3684
|
-
e[28] !== D ? (A = D.filter(
|
|
3699
|
+
e[28] !== D ? (A = D.filter(Us), e[28] = D, e[29] = A) : A = e[29];
|
|
3685
3700
|
const N = A.length;
|
|
3686
3701
|
let $;
|
|
3687
3702
|
e[30] !== w.data?.resources ? ($ = (T) => w.data?.resources[T], e[30] = w.data?.resources, e[31] = $) : $ = e[31];
|
|
@@ -3696,17 +3711,17 @@ const Yo = (t) => {
|
|
|
3696
3711
|
guarantee: "bestEffort"
|
|
3697
3712
|
}, e[32] = w, e[33] = $, e[34] = S, e[35] = k, e[36] = O, e[37] = F) : F = e[37], F;
|
|
3698
3713
|
};
|
|
3699
|
-
function
|
|
3714
|
+
function $s(t) {
|
|
3700
3715
|
return t !== j.WatchStateIdle && t !== j.WatchStateSyncing;
|
|
3701
3716
|
}
|
|
3702
|
-
function
|
|
3717
|
+
function Ms(t) {
|
|
3703
3718
|
const e = Object.values(t.state.data?.resources ?? {});
|
|
3704
|
-
return e.length && e.every(
|
|
3719
|
+
return e.length && e.every($s) ? !1 : 3e3;
|
|
3705
3720
|
}
|
|
3706
|
-
function
|
|
3721
|
+
function Us(t) {
|
|
3707
3722
|
return t !== j.WatchStateIdle && t !== j.WatchStateSyncing;
|
|
3708
3723
|
}
|
|
3709
|
-
const
|
|
3724
|
+
const ti = () => {
|
|
3710
3725
|
const t = q(16);
|
|
3711
3726
|
let e;
|
|
3712
3727
|
t[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (e = /* @__PURE__ */ new Map(), t[0] = e) : e = t[0];
|
|
@@ -3745,7 +3760,7 @@ const Zo = () => {
|
|
|
3745
3760
|
};
|
|
3746
3761
|
}, l = [a], t[4] = d, t[5] = l) : (d = t[4], l = t[5]), ge(d, l);
|
|
3747
3762
|
let f, p, v, h;
|
|
3748
|
-
t[6] !== r ? (v = Array.from(r.values()), f =
|
|
3763
|
+
t[6] !== r ? (v = Array.from(r.values()), f = mn(v), p = v.find(Ws) ?? v[0] ?? null, h = vn(v), t[6] = r, t[7] = f, t[8] = p, t[9] = v, t[10] = h) : (f = t[7], p = t[8], v = t[9], h = t[10]);
|
|
3749
3764
|
const g = h;
|
|
3750
3765
|
let m;
|
|
3751
3766
|
return t[11] !== g || t[12] !== f || t[13] !== p || t[14] !== v ? (m = {
|
|
@@ -3755,11 +3770,11 @@ const Zo = () => {
|
|
|
3755
3770
|
aggregateProgress: g
|
|
3756
3771
|
}, t[11] = g, t[12] = f, t[13] = p, t[14] = v, t[15] = m) : m = t[15], m;
|
|
3757
3772
|
};
|
|
3758
|
-
function
|
|
3773
|
+
function Ws(t) {
|
|
3759
3774
|
return !tt(t);
|
|
3760
3775
|
}
|
|
3761
|
-
const
|
|
3762
|
-
const t = L.useContext(
|
|
3776
|
+
const Qs = () => {
|
|
3777
|
+
const t = L.useContext(an);
|
|
3763
3778
|
if (!t)
|
|
3764
3779
|
throw new Error("useOperations must be used within an OperationsProvider");
|
|
3765
3780
|
return t;
|
|
@@ -3865,7 +3880,7 @@ function Bt(t) {
|
|
|
3865
3880
|
return `{${Object.entries(t.value).map(([e, r]) => `${JSON.stringify(e)}:${Bt(r)}`).join(",")}}`;
|
|
3866
3881
|
}
|
|
3867
3882
|
}
|
|
3868
|
-
function
|
|
3883
|
+
function ni(t) {
|
|
3869
3884
|
let e = 0;
|
|
3870
3885
|
const r = () => {
|
|
3871
3886
|
throw new SyntaxError(`Invalid resource JSON at offset ${e}`);
|
|
@@ -3953,7 +3968,7 @@ function Xo(t) {
|
|
|
3953
3968
|
}, o = i(0);
|
|
3954
3969
|
return n(), e !== t.length ? r() : o;
|
|
3955
3970
|
}
|
|
3956
|
-
const
|
|
3971
|
+
const ri = ({
|
|
3957
3972
|
pluginID: t
|
|
3958
3973
|
}) => {
|
|
3959
3974
|
const e = Q(t), {
|
|
@@ -3961,7 +3976,7 @@ const ei = ({
|
|
|
3961
3976
|
} = ye(), {
|
|
3962
3977
|
addOperation: n,
|
|
3963
3978
|
updateOperation: s
|
|
3964
|
-
} =
|
|
3979
|
+
} = Qs(), i = L.useRef(/* @__PURE__ */ new Set()), o = L.useCallback((a, d = !1) => {
|
|
3965
3980
|
a.disposed || (a.disposed = !0, a.unsubscribe?.(), a.open?.cancel(), a.attach?.cancel(), a.handle && (qt(a.handle).catch(() => {
|
|
3966
3981
|
}), d && s(a.handle, {
|
|
3967
3982
|
status: "cancelled",
|
|
@@ -3984,7 +3999,7 @@ const ei = ({
|
|
|
3984
3999
|
i.current.add(l);
|
|
3985
4000
|
try {
|
|
3986
4001
|
if (await et(e, a.route.connection), l.disposed) throw new Error("Stream action was cancelled before the connection became ready");
|
|
3987
|
-
l.open =
|
|
4002
|
+
l.open = vr(e, a);
|
|
3988
4003
|
const f = await l.open;
|
|
3989
4004
|
if (l.open = void 0, l.disposed)
|
|
3990
4005
|
return qt(f).catch(() => {
|
|
@@ -4027,7 +4042,7 @@ const ei = ({
|
|
|
4027
4042
|
} : void 0
|
|
4028
4043
|
});
|
|
4029
4044
|
};
|
|
4030
|
-
l.unsubscribe = W(`action/stream/${f}`, (h) => p(h.data)), l.attach =
|
|
4045
|
+
l.unsubscribe = W(`action/stream/${f}`, (h) => p(h.data)), l.attach = br(f);
|
|
4031
4046
|
const v = await l.attach;
|
|
4032
4047
|
return l.attach = void 0, p(v), f;
|
|
4033
4048
|
} catch (f) {
|
|
@@ -4049,7 +4064,7 @@ const ei = ({
|
|
|
4049
4064
|
cancelStreamAction: u
|
|
4050
4065
|
};
|
|
4051
4066
|
};
|
|
4052
|
-
function
|
|
4067
|
+
function js(t, e) {
|
|
4053
4068
|
return `${t}/${e}/graph/CHANGED`;
|
|
4054
4069
|
}
|
|
4055
4070
|
function Tt(t, e, r, n) {
|
|
@@ -4065,7 +4080,7 @@ function Tt(t, e, r, n) {
|
|
|
4065
4080
|
s[5] !== e || s[6] !== n || s[7] !== t || s[8] !== i ? (l = () => {
|
|
4066
4081
|
if (!n || !t || !e)
|
|
4067
4082
|
return;
|
|
4068
|
-
const p = W(
|
|
4083
|
+
const p = W(js(t, e), () => {
|
|
4069
4084
|
i.invalidateQueries({
|
|
4070
4085
|
queryKey: o.current,
|
|
4071
4086
|
exact: !0
|
|
@@ -4078,7 +4093,7 @@ function Tt(t, e, r, n) {
|
|
|
4078
4093
|
let f;
|
|
4079
4094
|
s[10] !== e || s[11] !== n || s[12] !== d || s[13] !== t || s[14] !== i ? (f = [i, t, e, d, n], s[10] = e, s[11] = n, s[12] = d, s[13] = t, s[14] = i, s[15] = f) : f = s[15], ge(l, f);
|
|
4080
4095
|
}
|
|
4081
|
-
const
|
|
4096
|
+
const Ks = {
|
|
4082
4097
|
owns: {
|
|
4083
4098
|
outgoing: "Owns",
|
|
4084
4099
|
incoming: "Owned by"
|
|
@@ -4108,16 +4123,16 @@ const Ws = {
|
|
|
4108
4123
|
incoming: "Selected by"
|
|
4109
4124
|
}
|
|
4110
4125
|
};
|
|
4111
|
-
function
|
|
4112
|
-
const r =
|
|
4126
|
+
function si(t, e) {
|
|
4127
|
+
const r = Ks[t];
|
|
4113
4128
|
if (r)
|
|
4114
4129
|
return r[e];
|
|
4115
4130
|
const n = t.replace(/_/g, " ");
|
|
4116
4131
|
return e === "outgoing" ? n : `${n} (incoming)`;
|
|
4117
4132
|
}
|
|
4118
|
-
function
|
|
4133
|
+
function Gs(t, e) {
|
|
4119
4134
|
return e.map((r) => {
|
|
4120
|
-
const n =
|
|
4135
|
+
const n = _n(r.source, t);
|
|
4121
4136
|
return {
|
|
4122
4137
|
resource: n ? r.target : r.source,
|
|
4123
4138
|
type: r.type,
|
|
@@ -4126,7 +4141,7 @@ function Qs(t, e) {
|
|
|
4126
4141
|
};
|
|
4127
4142
|
});
|
|
4128
4143
|
}
|
|
4129
|
-
const
|
|
4144
|
+
const oi = (t) => {
|
|
4130
4145
|
const e = q(38), {
|
|
4131
4146
|
pluginID: r,
|
|
4132
4147
|
reference: n,
|
|
@@ -4153,7 +4168,7 @@ const ni = (t) => {
|
|
|
4153
4168
|
signal: N,
|
|
4154
4169
|
queryKey: $
|
|
4155
4170
|
} = A;
|
|
4156
|
-
return b($, N, () =>
|
|
4171
|
+
return b($, N, () => wr(f, n, s, a, o ?? null));
|
|
4157
4172
|
} : ie, e[10] = a, e[11] = b, e[12] = f, e[13] = w, e[14] = n, e[15] = o, e[16] = s, e[17] = E) : E = e[17];
|
|
4158
4173
|
let _;
|
|
4159
4174
|
e[18] !== w || e[19] !== h || e[20] !== l || e[21] !== E ? (_ = {
|
|
@@ -4170,7 +4185,7 @@ const ni = (t) => {
|
|
|
4170
4185
|
reference: n
|
|
4171
4186
|
};
|
|
4172
4187
|
let N;
|
|
4173
|
-
e[29] !== C.data ? (N = C.data ?? [], e[29] = C.data, e[30] = N) : N = e[30], I = N, R =
|
|
4188
|
+
e[29] !== C.data ? (N = C.data ?? [], e[29] = C.data, e[30] = N) : N = e[30], I = N, R = Gs(A, I), e[23] = f, e[24] = C.data, e[25] = n, e[26] = s, e[27] = I, e[28] = R;
|
|
4174
4189
|
} else
|
|
4175
4190
|
I = e[27], R = e[28];
|
|
4176
4191
|
let D;
|
|
@@ -4182,7 +4197,7 @@ const ni = (t) => {
|
|
|
4182
4197
|
error: C.error,
|
|
4183
4198
|
refetch: C.refetch
|
|
4184
4199
|
}, e[31] = I, e[32] = C.error, e[33] = C.isFetching, e[34] = C.isLoading, e[35] = C.refetch, e[36] = R, e[37] = D) : D = e[37], D;
|
|
4185
|
-
},
|
|
4200
|
+
}, ii = (t) => {
|
|
4186
4201
|
const e = q(27), {
|
|
4187
4202
|
pluginID: r,
|
|
4188
4203
|
reference: n,
|
|
@@ -4208,7 +4223,7 @@ const ni = (t) => {
|
|
|
4208
4223
|
signal: R,
|
|
4209
4224
|
queryKey: D
|
|
4210
4225
|
} = I;
|
|
4211
|
-
return m(D, R, () =>
|
|
4226
|
+
return m(D, R, () => Er(l, n, s, u));
|
|
4212
4227
|
} : ie, e[9] = m, e[10] = u, e[11] = l, e[12] = y, e[13] = n, e[14] = s, e[15] = b) : b = e[15];
|
|
4213
4228
|
let w;
|
|
4214
4229
|
e[16] !== y || e[17] !== p || e[18] !== d || e[19] !== b ? (w = {
|
|
@@ -4226,7 +4241,7 @@ const ni = (t) => {
|
|
|
4226
4241
|
error: E.error,
|
|
4227
4242
|
refetch: E.refetch
|
|
4228
4243
|
}, e[21] = E.error, e[22] = E.isFetching, e[23] = E.isLoading, e[24] = E.refetch, e[25] = _, e[26] = C) : C = e[26], C;
|
|
4229
|
-
},
|
|
4244
|
+
}, ci = (t) => {
|
|
4230
4245
|
const e = q(28), {
|
|
4231
4246
|
pluginID: r,
|
|
4232
4247
|
reference: n,
|
|
@@ -4252,7 +4267,7 @@ const ni = (t) => {
|
|
|
4252
4267
|
signal: R,
|
|
4253
4268
|
queryKey: D
|
|
4254
4269
|
} = I;
|
|
4255
|
-
return m(D, R, () =>
|
|
4270
|
+
return m(D, R, () => Sr(l, n, s, u, a));
|
|
4256
4271
|
} : ie, e[10] = a, e[11] = m, e[12] = l, e[13] = y, e[14] = n, e[15] = s, e[16] = u, e[17] = b) : b = e[17];
|
|
4257
4272
|
let w;
|
|
4258
4273
|
e[18] !== y || e[19] !== p || e[20] !== b ? (w = {
|
|
@@ -4270,12 +4285,12 @@ const ni = (t) => {
|
|
|
4270
4285
|
error: E.error,
|
|
4271
4286
|
refetch: E.refetch
|
|
4272
4287
|
}, e[22] = E.error, e[23] = E.isFetching, e[24] = E.isLoading, e[25] = E.refetch, e[26] = _, e[27] = C) : C = e[27], C;
|
|
4273
|
-
},
|
|
4274
|
-
const t = L.useContext(
|
|
4288
|
+
}, ai = () => {
|
|
4289
|
+
const t = L.useContext(cn);
|
|
4275
4290
|
if (!t)
|
|
4276
4291
|
throw new Error("useSettings must be used within a SettingsProvider");
|
|
4277
4292
|
return t;
|
|
4278
|
-
},
|
|
4293
|
+
}, zs = 1, li = (t) => {
|
|
4279
4294
|
const e = q(19);
|
|
4280
4295
|
let r, n, s, i;
|
|
4281
4296
|
if (e[0] !== t) {
|
|
@@ -4291,7 +4306,7 @@ const ni = (t) => {
|
|
|
4291
4306
|
r = e[1], n = e[2], s = e[3], i = e[4];
|
|
4292
4307
|
const {
|
|
4293
4308
|
pluginId: o
|
|
4294
|
-
} =
|
|
4309
|
+
} = on(), c = L.useContext(Dt);
|
|
4295
4310
|
o || console.error("Link used outside of a plugin context");
|
|
4296
4311
|
const u = `/_plugin/${o}${i.startsWith("/") ? "" : "/"}${i}`;
|
|
4297
4312
|
let a;
|
|
@@ -4303,7 +4318,7 @@ const ni = (t) => {
|
|
|
4303
4318
|
const d = a;
|
|
4304
4319
|
let l;
|
|
4305
4320
|
e[9] !== r || e[10] !== u || e[11] !== c ? (l = (h) => {
|
|
4306
|
-
r?.(h), !(h.defaultPrevented || !c || h.button !==
|
|
4321
|
+
r?.(h), !(h.defaultPrevented || !c || h.button !== zs) && (h.preventDefault(), c.openInNewTab(u, {
|
|
4307
4322
|
background: !0
|
|
4308
4323
|
}));
|
|
4309
4324
|
}, e[9] = r, e[10] = u, e[11] = c, e[12] = l) : l = e[12];
|
|
@@ -4314,12 +4329,12 @@ const ni = (t) => {
|
|
|
4314
4329
|
color: "inherit"
|
|
4315
4330
|
}, e[13] = p) : p = e[13];
|
|
4316
4331
|
let v;
|
|
4317
|
-
return e[14] !== f || e[15] !== d || e[16] !== s || e[17] !== u ? (v = /* @__PURE__ */ P(
|
|
4332
|
+
return e[14] !== f || e[15] !== d || e[16] !== s || e[17] !== u ? (v = /* @__PURE__ */ P(Cr, { style: p, ...s, to: u, onClick: d, onAuxClick: f }), e[14] = f, e[15] = d, e[16] = s, e[17] = u, e[18] = v) : v = e[18], v;
|
|
4318
4333
|
};
|
|
4319
|
-
function
|
|
4320
|
-
const t = q(10), e =
|
|
4334
|
+
function ui() {
|
|
4335
|
+
const t = q(10), e = Ir(), r = _r(), {
|
|
4321
4336
|
pluginId: n
|
|
4322
|
-
} =
|
|
4337
|
+
} = on();
|
|
4323
4338
|
n || console.error("usePluginRouter used outside of a plugin context");
|
|
4324
4339
|
const s = `/_plugin/${n}`;
|
|
4325
4340
|
let i;
|
|
@@ -4340,9 +4355,9 @@ function ci() {
|
|
|
4340
4355
|
pluginPath: o
|
|
4341
4356
|
}, t[6] = r, t[7] = u, t[8] = o, t[9] = a) : a = t[9], a;
|
|
4342
4357
|
}
|
|
4343
|
-
class
|
|
4358
|
+
class di {
|
|
4344
4359
|
}
|
|
4345
|
-
class
|
|
4360
|
+
class fi {
|
|
4346
4361
|
_extensions;
|
|
4347
4362
|
/**
|
|
4348
4363
|
* The root component to render for the application window.
|
|
@@ -4399,8 +4414,8 @@ class li {
|
|
|
4399
4414
|
get Window() {
|
|
4400
4415
|
if (!this._routes && this.root)
|
|
4401
4416
|
return /* @__PURE__ */ P(this.root, {});
|
|
4402
|
-
const e =
|
|
4403
|
-
return /* @__PURE__ */ P(
|
|
4417
|
+
const e = Dr(this._routes || []);
|
|
4418
|
+
return /* @__PURE__ */ P(Lr, { router: e });
|
|
4404
4419
|
}
|
|
4405
4420
|
/**
|
|
4406
4421
|
* Register extension points for other plugins to extend the functionality
|
|
@@ -4430,15 +4445,15 @@ class li {
|
|
|
4430
4445
|
return this._routes = e, this;
|
|
4431
4446
|
}
|
|
4432
4447
|
}
|
|
4433
|
-
var
|
|
4434
|
-
const
|
|
4435
|
-
function
|
|
4436
|
-
window.dispatchEvent(new CustomEvent(
|
|
4448
|
+
var Bs = /* @__PURE__ */ ((t) => (t.MISSING_MANIFEST = "MISSING_MANIFEST", t.MISSING_PLUGIN = "MISSING_PLUGIN", t.MISSING_ENTRYPOINT = "MISSING_ENTRYPOINT", t))(Bs || {});
|
|
4449
|
+
const Js = "omniview/global-search/open";
|
|
4450
|
+
function pi(t = {}) {
|
|
4451
|
+
window.dispatchEvent(new CustomEvent(Js, {
|
|
4437
4452
|
detail: t
|
|
4438
4453
|
}));
|
|
4439
4454
|
}
|
|
4440
|
-
const
|
|
4441
|
-
class
|
|
4455
|
+
const Hs = "omniview/resource/icons";
|
|
4456
|
+
class Vs extends In {
|
|
4442
4457
|
state = {
|
|
4443
4458
|
failed: !1,
|
|
4444
4459
|
resetToken: this.props.resetToken
|
|
@@ -4458,14 +4473,14 @@ class Bs extends Cn {
|
|
|
4458
4473
|
return this.state.failed ? this.props.fallback : this.props.children;
|
|
4459
4474
|
}
|
|
4460
4475
|
}
|
|
4461
|
-
function
|
|
4476
|
+
function Ys(t, e) {
|
|
4462
4477
|
try {
|
|
4463
4478
|
return t?.schemaVersion !== 1 || typeof t.resolve != "function" ? void 0 : t.resolve(e);
|
|
4464
4479
|
} catch {
|
|
4465
4480
|
return;
|
|
4466
4481
|
}
|
|
4467
4482
|
}
|
|
4468
|
-
function
|
|
4483
|
+
function Zs(t) {
|
|
4469
4484
|
const e = q(7);
|
|
4470
4485
|
let r, n;
|
|
4471
4486
|
e[0] !== t ? ({
|
|
@@ -4476,7 +4491,7 @@ function Hs(t) {
|
|
|
4476
4491
|
let i;
|
|
4477
4492
|
return e[3] !== r || e[4] !== n || e[5] !== s ? (i = /* @__PURE__ */ P(r, { ...n, "aria-hidden": s }), e[3] = r, e[4] = n, e[5] = s, e[6] = i) : i = e[6], i;
|
|
4478
4493
|
}
|
|
4479
|
-
function
|
|
4494
|
+
function gi(t) {
|
|
4480
4495
|
const e = q(17);
|
|
4481
4496
|
let r, n, s, i;
|
|
4482
4497
|
e[0] !== t ? ({
|
|
@@ -4488,7 +4503,7 @@ function di(t) {
|
|
|
4488
4503
|
const {
|
|
4489
4504
|
version: o,
|
|
4490
4505
|
contributions: c
|
|
4491
|
-
} =
|
|
4506
|
+
} = dn(Hs);
|
|
4492
4507
|
let u;
|
|
4493
4508
|
e[5] !== r || e[6] !== s ? (u = r === void 0 ? /* @__PURE__ */ P("svg", { width: s.size ?? 16, height: s.size ?? 16, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", className: s.className, "aria-hidden": s["aria-hidden"] ?? !0, children: /* @__PURE__ */ P("path", { d: "m12 3 9 5v8l-9 5-9-5V8l9-5Zm0 9 9-4M12 12 3 8m9 4v9" }) }) : r, e[5] = r, e[6] = s, e[7] = u) : u = e[7];
|
|
4494
4509
|
const a = u;
|
|
@@ -4498,9 +4513,9 @@ function di(t) {
|
|
|
4498
4513
|
e: for (const f of c) {
|
|
4499
4514
|
if (f.plugin !== n)
|
|
4500
4515
|
continue;
|
|
4501
|
-
const p =
|
|
4516
|
+
const p = Ys(f.value, i);
|
|
4502
4517
|
if (p) {
|
|
4503
|
-
d = /* @__PURE__ */ P(
|
|
4518
|
+
d = /* @__PURE__ */ P(Vs, { resetToken: f, fallback: a, children: /* @__PURE__ */ P(L.Suspense, { fallback: a, children: /* @__PURE__ */ P(Zs, { icon: p, ...s }) }) }, JSON.stringify([n, i, o, f.id]));
|
|
4504
4519
|
break e;
|
|
4505
4520
|
}
|
|
4506
4521
|
}
|
|
@@ -4512,7 +4527,8 @@ function di(t) {
|
|
|
4512
4527
|
let l;
|
|
4513
4528
|
return e[15] !== a ? (l = /* @__PURE__ */ P(Ct, { children: a }), e[15] = a, e[16] = l) : l = e[16], l;
|
|
4514
4529
|
}
|
|
4515
|
-
|
|
4530
|
+
const hi = "omniview/settings/editor";
|
|
4531
|
+
function yi(t) {
|
|
4516
4532
|
const e = q(23);
|
|
4517
4533
|
let r, n, s;
|
|
4518
4534
|
e[0] !== t ? ({
|
|
@@ -4555,109 +4571,112 @@ function fi(t) {
|
|
|
4555
4571
|
}
|
|
4556
4572
|
export {
|
|
4557
4573
|
xe as ALL_SESSIONS_KEY,
|
|
4558
|
-
|
|
4559
|
-
|
|
4560
|
-
|
|
4561
|
-
|
|
4574
|
+
zr as BottomDrawerContext,
|
|
4575
|
+
Jr as ConfirmationModalContext,
|
|
4576
|
+
No as ConnectionBoundary,
|
|
4577
|
+
ys as ConnectionBoundaryFallback,
|
|
4562
4578
|
Z as ErrorTypes,
|
|
4563
|
-
|
|
4564
|
-
|
|
4565
|
-
|
|
4566
|
-
|
|
4579
|
+
wo as ExtensionPointRegistry,
|
|
4580
|
+
ts as ExtensionPointStore,
|
|
4581
|
+
bo as ExtensionProvider,
|
|
4582
|
+
Js as GLOBAL_SEARCH_OPEN_EVENT,
|
|
4567
4583
|
gt as HOST_SETTINGS_SCOPE,
|
|
4568
|
-
|
|
4569
|
-
|
|
4570
|
-
|
|
4584
|
+
li as Link,
|
|
4585
|
+
an as OperationsContext,
|
|
4586
|
+
ho as OperationsProvider,
|
|
4571
4587
|
_t as PluginContext,
|
|
4572
|
-
|
|
4573
|
-
|
|
4574
|
-
|
|
4575
|
-
|
|
4576
|
-
|
|
4577
|
-
|
|
4578
|
-
|
|
4579
|
-
|
|
4580
|
-
|
|
4581
|
-
|
|
4582
|
-
|
|
4588
|
+
po as PluginContextProvider,
|
|
4589
|
+
Bs as PluginErrorCode,
|
|
4590
|
+
fi as PluginWindow,
|
|
4591
|
+
di as PluginWindowRootProps,
|
|
4592
|
+
Hs as RESOURCE_ICON_EXTENSION_POINT_ID,
|
|
4593
|
+
gi as ResourceIcon,
|
|
4594
|
+
Br as RightDrawerContext,
|
|
4595
|
+
hi as SETTINGS_EDITOR_EXTENSION_POINT_ID,
|
|
4596
|
+
cn as SettingsContext,
|
|
4597
|
+
go as SettingsProvider,
|
|
4598
|
+
Eo as SnackbarProvider,
|
|
4599
|
+
bi as SyncPolicy,
|
|
4583
4600
|
j as WatchState,
|
|
4584
4601
|
Dt as WindowActionsContext,
|
|
4585
|
-
|
|
4586
|
-
|
|
4602
|
+
yo as WindowActionsProvider,
|
|
4603
|
+
Qr as actionToSnackbar,
|
|
4587
4604
|
Kt as applyBatch,
|
|
4588
|
-
|
|
4605
|
+
is as connectionListQueryKey,
|
|
4589
4606
|
se as createErrorHandler,
|
|
4590
|
-
|
|
4591
|
-
|
|
4607
|
+
Gr as defaultState,
|
|
4608
|
+
js as graphChangedEvent,
|
|
4592
4609
|
Ve as isCancelledError,
|
|
4593
|
-
|
|
4610
|
+
ni as jsonTextToValue,
|
|
4594
4611
|
zt as jsonToValue,
|
|
4595
|
-
|
|
4596
|
-
|
|
4612
|
+
Wr as navigateActivePage,
|
|
4613
|
+
pi as openGlobalSearch,
|
|
4614
|
+
Ur as openSettings,
|
|
4597
4615
|
he as parseAppError,
|
|
4598
|
-
|
|
4599
|
-
|
|
4600
|
-
|
|
4616
|
+
Ao as readCurrentConnectionMetadataString,
|
|
4617
|
+
fo as registerActivePageNavigator,
|
|
4618
|
+
si as relationshipLabel,
|
|
4601
4619
|
et as requireConnectionReady,
|
|
4602
4620
|
Ne as resourceQueryKeys,
|
|
4603
|
-
|
|
4604
|
-
|
|
4605
|
-
|
|
4621
|
+
_n as sameGraphNode,
|
|
4622
|
+
Mr as scopedSettingID,
|
|
4623
|
+
Fr as settingsQueryKey,
|
|
4624
|
+
rn as settingsWindowTarget,
|
|
4606
4625
|
Le as showAppError,
|
|
4607
|
-
|
|
4608
|
-
|
|
4609
|
-
|
|
4610
|
-
|
|
4611
|
-
|
|
4612
|
-
|
|
4613
|
-
|
|
4614
|
-
|
|
4615
|
-
|
|
4626
|
+
Gs as toRelatedResources,
|
|
4627
|
+
ti as useActiveSyncs,
|
|
4628
|
+
En as useBottomDrawer,
|
|
4629
|
+
Qo as useConfirmationModal,
|
|
4630
|
+
Co as useConnection,
|
|
4631
|
+
ko as useConnectionMetadata,
|
|
4632
|
+
Oo as useConnectionMetadataConnections,
|
|
4633
|
+
To as useConnectionMetadataSelector,
|
|
4634
|
+
Ro as useConnectionProfiles,
|
|
4616
4635
|
le as useConnectionReadiness,
|
|
4617
|
-
|
|
4618
|
-
|
|
4619
|
-
|
|
4620
|
-
|
|
4621
|
-
|
|
4622
|
-
|
|
4623
|
-
|
|
4624
|
-
|
|
4625
|
-
|
|
4626
|
-
|
|
4627
|
-
|
|
4628
|
-
|
|
4629
|
-
|
|
4630
|
-
|
|
4631
|
-
|
|
4632
|
-
|
|
4633
|
-
|
|
4634
|
-
|
|
4635
|
-
|
|
4636
|
+
Do as useConnectionStatus,
|
|
4637
|
+
Io as useConnections,
|
|
4638
|
+
ii as useDependencyTree,
|
|
4639
|
+
Xo as useEditorSchemas,
|
|
4640
|
+
Fs as useEventBatcher,
|
|
4641
|
+
Lo as useExec,
|
|
4642
|
+
Zo as useExecuteAction,
|
|
4643
|
+
vo as useExtensionPoint,
|
|
4644
|
+
dn as useExtensionPointSnapshot,
|
|
4645
|
+
es as useExtensionRegistry,
|
|
4646
|
+
Fo as useLogs,
|
|
4647
|
+
qo as useMetricProviders,
|
|
4648
|
+
Rs as useMetricProvidersForResource,
|
|
4649
|
+
Mo as useMetricStream,
|
|
4650
|
+
Qs as useOperations,
|
|
4651
|
+
on as usePluginContext,
|
|
4652
|
+
Po as usePluginData,
|
|
4653
|
+
ui as usePluginRouter,
|
|
4654
|
+
Uo as usePortForwardSessions,
|
|
4636
4655
|
Tt as useRefetchOnGraphChange,
|
|
4637
|
-
|
|
4656
|
+
oi as useRelatedResources,
|
|
4638
4657
|
Q as useResolvedPluginId,
|
|
4639
|
-
|
|
4640
|
-
|
|
4641
|
-
|
|
4642
|
-
|
|
4643
|
-
|
|
4644
|
-
|
|
4645
|
-
|
|
4646
|
-
|
|
4647
|
-
|
|
4648
|
-
|
|
4649
|
-
|
|
4650
|
-
|
|
4651
|
-
|
|
4652
|
-
|
|
4653
|
-
|
|
4658
|
+
yi as useResolvedResourceTarget,
|
|
4659
|
+
jo as useResource,
|
|
4660
|
+
Yo as useResourceActions,
|
|
4661
|
+
Ko as useResourceAreaComponent,
|
|
4662
|
+
ci as useResourceGraph,
|
|
4663
|
+
Go as useResourceGroups,
|
|
4664
|
+
$o as useResourceMetrics,
|
|
4665
|
+
Vo as useResourceMutations,
|
|
4666
|
+
Wo as useResourcePortForwarder,
|
|
4667
|
+
zo as useResourceSearch,
|
|
4668
|
+
Bo as useResourceType,
|
|
4669
|
+
Jo as useResourceTypes,
|
|
4670
|
+
Ho as useResources,
|
|
4671
|
+
xo as useRightDrawer,
|
|
4672
|
+
_o as useScopeValues,
|
|
4654
4673
|
nn as useScopedSettings,
|
|
4655
|
-
|
|
4674
|
+
ai as useSettings,
|
|
4656
4675
|
ye as useSnackbar,
|
|
4657
|
-
|
|
4658
|
-
|
|
4659
|
-
|
|
4676
|
+
ri as useStreamAction,
|
|
4677
|
+
ei as useWatchState,
|
|
4678
|
+
mo as useWindowActions,
|
|
4660
4679
|
wt as valueToJSON,
|
|
4661
4680
|
Bt as valueToJSONText,
|
|
4662
|
-
|
|
4681
|
+
So as withConnectionReady
|
|
4663
4682
|
};
|