@omniviewdev/runtime 0.4.0 → 0.4.1

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/index.js CHANGED
@@ -2,16 +2,16 @@ var it = Object.defineProperty;
2
2
  var at = (t, e, n) => e in t ? it(t, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : t[e] = n;
3
3
  var T = (t, e, n) => at(t, typeof e != "symbol" ? e + "" : e, n);
4
4
  import { jsx as A, jsxs as X } from "react/jsx-runtime";
5
- import v, { useContext as Y, createContext as re, useState as q, useCallback as M, useSyncExternalStore as ct, useRef as W, useEffect as G, useMemo as ut } from "react";
5
+ import b, { useContext as Y, createContext as re, useState as q, useCallback as k, useSyncExternalStore as ct, useRef as W, useEffect as G, useMemo as ut } from "react";
6
6
  import { Link as lt, useNavigate as dt, useLocation as ft, createMemoryRouter as pt, RouterProvider as yt } from "react-router-dom";
7
- import { P as ht, G as gt, V as mt, S as St, a as Re, U as _t, R as wt, b as Et, c as De, d as Ct, L as vt, e as bt, f as Ft, g as It, h as Rt, i as Dt, j as Pt, C as Ot, k as Tt, l as At, m as xt, n as Nt, Q as kt, o as Mt, p as Ee, q as Lt, r as Pe, F as $t, s as Ut, t as Oe, D as Te, u as qt, v as Wt, w as Gt, x as Ae, y as jt, z as Qt, A as xe, B as Kt, E as Bt, H as Ht, I as zt, J as Yt, K as Jt, M as Zt } from "./servicewrapper-BH5omp-N.js";
8
- import { P as Xt, W as Vt, S as en, C as tn, L as nn, F as rn, a as sn, U as Ne, D as ke, G as on, b as Me, c as Le, A as $e } from "./models-BVKsY9u1.js";
9
- import { useQueryClient as j, useMutation as D, useQuery as O, keepPreviousData as Ue, useQueries as an } from "@tanstack/react-query";
10
- import { useToast as cn } from "@omniviewdev/base-ui";
7
+ import { P as gt, G as ht, V as mt, S as St, a as Ie, U as _t, R as wt, b as Et, c as De, d as Ct, L as bt, e as vt, f as Rt, g as Ft, h as It, i as Dt, j as Pt, C as Ot, k as Tt, l as At, m as xt, n as Nt, Q as Lt, o as kt, p as Ee, q as Mt, r as Pe, F as $t, s as Ut, t as Oe, D as Te, u as qt, v as Wt, w as Gt, x as Ae, y as jt, z as Qt, A as xe, B as Kt, E as Bt, H as Ht, I as zt, J as Yt, K as Jt, M as Zt, N as Xt, O as Vt } from "./graphservice-CXr8ZCEY.js";
8
+ import { P as en, W as tn, S as nn, C as rn, L as sn, F as on, a as an, U as Ne, D as Le, G as cn, b as ke, c as Me, A as $e } from "./models-BvR5jdms.js";
9
+ import { useQueryClient as j, useMutation as P, useQuery as O, keepPreviousData as Ue, useQueries as un } from "@tanstack/react-query";
10
+ import { useToast as ln } from "@omniviewdev/base-ui";
11
11
  import "./index-D2mKAO8s.js";
12
12
  import { O as x, a as qe, b as ae } from "./events-DDTGFACO.js";
13
- import { w as un } from "./legacyEnum-DORXlU_y.js";
14
- const ye = v.createContext(void 0), $ = {
13
+ import { w as dn } from "./legacyEnum-DORXlU_y.js";
14
+ const ye = b.createContext(void 0), $ = {
15
15
  // Plugin
16
16
  PLUGIN_NOT_FOUND: "omniview:plugin/not-found",
17
17
  PLUGIN_NOT_LOADED: "omniview:plugin/not-loaded",
@@ -42,7 +42,7 @@ const ye = v.createContext(void 0), $ = {
42
42
  VALIDATION: "omniview:validation",
43
43
  NOT_IMPLEMENTED: "omniview:not-implemented"
44
44
  };
45
- function ln(t) {
45
+ function fn(t) {
46
46
  switch (t) {
47
47
  case "NOT_FOUND":
48
48
  return { typeUri: $.RESOURCE_NOT_FOUND, status: 404 };
@@ -78,7 +78,7 @@ function Q(t) {
78
78
  if (typeof n.type == "string" && typeof n.title == "string" && typeof n.status == "number" && typeof n.detail == "string")
79
79
  return n;
80
80
  if (typeof n.code == "string" && typeof n.title == "string" && typeof n.message == "string") {
81
- const { typeUri: r, status: s } = ln(n.code);
81
+ const { typeUri: r, status: s } = fn(n.code);
82
82
  return {
83
83
  type: r,
84
84
  title: n.title,
@@ -99,7 +99,7 @@ function Q(t) {
99
99
  function We(t) {
100
100
  return t == null ? !1 : (typeof t == "string" ? t : t instanceof Error ? t.message : String(t)) === "cancelled" ? !0 : Q(t).type === $.CANCELLED;
101
101
  }
102
- function dn(t) {
102
+ function pn(t) {
103
103
  switch (t.type) {
104
104
  case "navigate":
105
105
  return {
@@ -147,7 +147,7 @@ function Ge(t, e) {
147
147
  message: e || (t.title !== "Error" ? t.title : "Operation failed"),
148
148
  status: "error",
149
149
  details: n,
150
- actions: (i = t.actions) == null ? void 0 : i.map(dn)
150
+ actions: (i = t.actions) == null ? void 0 : i.map(pn)
151
151
  };
152
152
  }
153
153
  function z(t, e, n) {
@@ -155,18 +155,18 @@ function z(t, e, n) {
155
155
  const r = Q(e);
156
156
  t(Ge(r, n));
157
157
  }
158
- function k(t, e) {
158
+ function L(t, e) {
159
159
  return (n) => {
160
160
  if (We(n)) return;
161
161
  const r = Q(n);
162
162
  t(Ge(r, r.title !== "Error" ? r.title : e));
163
163
  };
164
164
  }
165
- function qr(t) {
166
- const { children: e, pluginId: n } = t, [r, s] = v.useState({}), [i, o] = v.useState(new Xt()), [a, c] = v.useState(!1), [l, u] = v.useState(null);
165
+ function Br(t) {
166
+ const { children: e, pluginId: n } = t, [r, s] = b.useState({}), [i, o] = b.useState(new en()), [a, c] = b.useState(!1), [l, u] = b.useState(null);
167
167
  console.debug("[PluginContextProvider] render", { pluginId: n, metaLoaded: a, metaError: !!l });
168
168
  const y = () => {
169
- n === void 0 || n === "" || (console.debug(`[PluginContextProvider] fetching settings for "${n}"`), ht(n).then((d) => {
169
+ n === void 0 || n === "" || (console.debug(`[PluginContextProvider] fetching settings for "${n}"`), gt(n).then((d) => {
170
170
  console.debug(`[PluginContextProvider] settings loaded for "${n}"`, Object.keys(d)), s(d);
171
171
  }).catch((d) => {
172
172
  const p = Q(d);
@@ -177,14 +177,14 @@ function qr(t) {
177
177
  console.debug("[PluginContextProvider] skipping meta fetch — empty pluginId");
178
178
  return;
179
179
  }
180
- console.debug(`[PluginContextProvider] fetching meta for "${n}"`), u(null), gt(n).then((d) => {
180
+ console.debug(`[PluginContextProvider] fetching meta for "${n}"`), u(null), ht(n).then((d) => {
181
181
  console.debug(`[PluginContextProvider] meta loaded for "${n}"`, { name: d == null ? void 0 : d.name, version: d == null ? void 0 : d.version }), o(d), c(!0);
182
182
  }).catch((d) => {
183
183
  const p = Q(d);
184
184
  console.error(`[PluginContextProvider] error fetching meta for "${n}":`, p.detail), u(p.detail), c(!1);
185
185
  });
186
186
  };
187
- return v.useEffect(() => {
187
+ return b.useEffect(() => {
188
188
  console.debug(`[PluginContextProvider] useEffect — pluginId changed to "${n}"`), y(), f();
189
189
  }, [n]), l ? /* @__PURE__ */ A("div", { style: {
190
190
  display: "flex",
@@ -244,16 +244,16 @@ function qr(t) {
244
244
  /* @__PURE__ */ A("style", { children: "@keyframes plugin-spin { to { transform: rotate(360deg); } }" })
245
245
  ] });
246
246
  }
247
- function he() {
247
+ function ge() {
248
248
  const t = Y(ye);
249
249
  if (!t)
250
250
  throw new Error("usePluginContext must be used within a PluginContextProvider");
251
251
  return t;
252
252
  }
253
- function Wr() {
254
- return he().settings;
253
+ function Hr() {
254
+ return ge().settings;
255
255
  }
256
- const je = re(void 0), Gr = ({ children: t }) => {
256
+ const je = re(void 0), zr = ({ children: t }) => {
257
257
  const [e, n] = q({}), r = () => {
258
258
  mt().then((i) => {
259
259
  console.log("Fetched settings:", i), n(i);
@@ -261,14 +261,14 @@ const je = re(void 0), Gr = ({ children: t }) => {
261
261
  console.error("Error fetching settings:", i);
262
262
  });
263
263
  };
264
- v.useEffect(() => {
264
+ b.useEffect(() => {
265
265
  r();
266
266
  }, []);
267
267
  const s = () => {
268
268
  r();
269
269
  };
270
270
  return /* @__PURE__ */ A(je.Provider, { value: { settings: e, reload: s }, children: t });
271
- }, fn = {
271
+ }, yn = {
272
272
  height: 32,
273
273
  focused: 0,
274
274
  tabs: [],
@@ -292,26 +292,26 @@ const je = re(void 0), Gr = ({ children: t }) => {
292
292
  },
293
293
  fullscreenDrawer: () => {
294
294
  }
295
- }, pn = v.createContext(fn), yn = re(void 0), hn = v.createContext(void 0), Qe = v.createContext(void 0), gn = 3e4, jr = ({ children: t }) => {
296
- const [e, n] = v.useState([]), r = v.useCallback((a) => {
295
+ }, gn = b.createContext(yn), hn = re(void 0), mn = b.createContext(void 0), Qe = b.createContext(void 0), Sn = 3e4, Yr = ({ children: t }) => {
296
+ const [e, n] = b.useState([]), r = b.useCallback((a) => {
297
297
  n((c) => [a, ...c]);
298
- }, []), s = v.useCallback((a, c) => {
298
+ }, []), s = b.useCallback((a, c) => {
299
299
  n(
300
300
  (l) => l.map((u) => u.id === a ? { ...u, ...c } : u)
301
301
  );
302
- }, []), i = v.useCallback((a) => {
302
+ }, []), i = b.useCallback((a) => {
303
303
  n((c) => c.filter((l) => l.id !== a));
304
304
  }, []);
305
- v.useEffect(() => {
305
+ b.useEffect(() => {
306
306
  const a = [];
307
307
  for (const c of e)
308
308
  if (c.status === "completed" || c.status === "error") {
309
- const l = Date.now() - (c.completedAt ?? c.startedAt), u = Math.max(0, gn - l);
309
+ const l = Date.now() - (c.completedAt ?? c.startedAt), u = Math.max(0, Sn - l);
310
310
  a.push(setTimeout(() => i(c.id), u));
311
311
  }
312
312
  return () => a.forEach(clearTimeout);
313
313
  }, [e, i]);
314
- const o = v.useMemo(
314
+ const o = b.useMemo(
315
315
  () => ({ operations: e, addOperation: r, updateOperation: s, removeOperation: i }),
316
316
  [e, r, s, i]
317
317
  );
@@ -324,7 +324,7 @@ var de = function(t, e) {
324
324
  for (var s in r) Object.prototype.hasOwnProperty.call(r, s) && (n[s] = r[s]);
325
325
  }, de(t, e);
326
326
  };
327
- function mn(t, e) {
327
+ function _n(t, e) {
328
328
  if (typeof e != "function" && e !== null)
329
329
  throw new TypeError("Class extends value " + String(e) + " is not a constructor or null");
330
330
  de(t, e);
@@ -333,28 +333,28 @@ function mn(t, e) {
333
333
  }
334
334
  t.prototype = e === null ? Object.create(e) : (n.prototype = e.prototype, new n());
335
335
  }
336
- var ce = "Invariant Violation", Ce = Object.setPrototypeOf, Sn = Ce === void 0 ? function(t, e) {
336
+ var ce = "Invariant Violation", Ce = Object.setPrototypeOf, wn = Ce === void 0 ? function(t, e) {
337
337
  return t.__proto__ = e, t;
338
- } : Ce, _n = (
338
+ } : Ce, En = (
339
339
  /** @class */
340
340
  function(t) {
341
- mn(e, t);
341
+ _n(e, t);
342
342
  function e(n) {
343
343
  n === void 0 && (n = ce);
344
344
  var r = t.call(this, typeof n == "number" ? ce + ": " + n + " (see https://github.com/apollographql/invariant-packages)" : n) || this;
345
- return r.framesToPop = 1, r.name = ce, Sn(r, e.prototype), r;
345
+ return r.framesToPop = 1, r.name = ce, wn(r, e.prototype), r;
346
346
  }
347
347
  return e;
348
348
  }(Error)
349
349
  );
350
350
  function fe(t, e) {
351
351
  if (!t)
352
- throw new _n(e);
352
+ throw new En(e);
353
353
  }
354
- var Ke = ["debug", "log", "warn", "error", "silent"], wn = Ke.indexOf("log");
354
+ var Ke = ["debug", "log", "warn", "error", "silent"], Cn = Ke.indexOf("log");
355
355
  function V(t) {
356
356
  return function() {
357
- if (Ke.indexOf(t) >= wn) {
357
+ if (Ke.indexOf(t) >= Cn) {
358
358
  var e = console[t] || console.log;
359
359
  return e.apply(console, arguments);
360
360
  }
@@ -363,9 +363,9 @@ function V(t) {
363
363
  (function(t) {
364
364
  t.debug = V("debug"), t.log = V("log"), t.warn = V("warn"), t.error = V("error");
365
365
  })(fe || (fe = {}));
366
- const Be = re(void 0), En = () => Y(Be);
367
- function Qr(t) {
368
- const e = En(), n = v.useRef(null), r = e == null ? void 0 : e.getExtensionPoint(t), s = M(
366
+ const Be = re(void 0), bn = () => Y(Be);
367
+ function Jr(t) {
368
+ const e = bn(), n = b.useRef(null), r = e == null ? void 0 : e.getExtensionPoint(t), s = k(
369
369
  (o) => {
370
370
  const a = [];
371
371
  return e && a.push(e.subscribe(o)), r && a.push(r.subscribe(o)), () => {
@@ -374,7 +374,7 @@ function Qr(t) {
374
374
  };
375
375
  },
376
376
  [e, t, r]
377
- ), i = M(() => {
377
+ ), i = k(() => {
378
378
  const o = e == null ? void 0 : e.getExtensionPoint(t);
379
379
  if (!o) {
380
380
  if (n.current && n.current.store === void 0)
@@ -390,8 +390,8 @@ function Qr(t) {
390
390
  }, [e, t]);
391
391
  return ct(s, i), e == null ? void 0 : e.getExtensionPoint(t);
392
392
  }
393
- const Kr = ({ registry: t, children: e }) => {
394
- const n = v.useRef(t);
393
+ const Zr = ({ registry: t, children: e }) => {
394
+ const n = b.useRef(t);
395
395
  return fe(
396
396
  n.current === t,
397
397
  "You can't change the extension registry after it has been rendered"
@@ -401,7 +401,7 @@ const Kr = ({ registry: t, children: e }) => {
401
401
  throw new TypeError(`extensionName is required to be a string and can't be: "${t}" (${typeof t})`);
402
402
  return t.trim();
403
403
  };
404
- class Cn {
404
+ class vn {
405
405
  constructor(e) {
406
406
  T(this, "id");
407
407
  T(this, "mode");
@@ -521,7 +521,7 @@ class Cn {
521
521
  e();
522
522
  }
523
523
  }
524
- class Br {
524
+ class Xr {
525
525
  constructor(e) {
526
526
  T(this, "_stores", /* @__PURE__ */ new Map());
527
527
  T(this, "_storeUnsubs", /* @__PURE__ */ new Map());
@@ -542,7 +542,7 @@ class Br {
542
542
  `Extension point "${n}" already exists (owned by "${s.pluginId ?? "unknown"}")`
543
543
  );
544
544
  }
545
- const r = new Cn({ ...e, id: n });
545
+ const r = new vn({ ...e, id: n });
546
546
  this._stores.set(n, r), this._storeUnsubs.set(n, r.subscribe(() => this._notify())), this._notify();
547
547
  }
548
548
  /**
@@ -597,14 +597,14 @@ class Br {
597
597
  e();
598
598
  }
599
599
  }
600
- const He = re(void 0), vn = {
600
+ const He = re(void 0), Rn = {
601
601
  default: "info",
602
602
  info: "info",
603
603
  success: "success",
604
604
  warning: "warning",
605
605
  error: "danger"
606
- }, Hr = ({ children: t }) => {
607
- const { toast: e } = cn(), [n, r] = v.useState([]), s = (o) => {
606
+ }, Vr = ({ children: t }) => {
607
+ const { toast: e } = ln(), [n, r] = b.useState([]), s = (o) => {
608
608
  r((a) => [...a, o]);
609
609
  }, i = (o, a, c) => {
610
610
  const l = typeof o == "object";
@@ -619,7 +619,7 @@ const He = re(void 0), vn = {
619
619
  } else
620
620
  u = o, y = a, f = c;
621
621
  e(f ?? u, {
622
- severity: vn[y] ?? "info",
622
+ severity: Rn[y] ?? "info",
623
623
  title: f ? u : void 0,
624
624
  duration: d,
625
625
  action: p == null ? void 0 : p[0]
@@ -632,7 +632,7 @@ const He = re(void 0), vn = {
632
632
  throw new Error("useCustomSnackbar must be used within a CustomSnackbarProvider");
633
633
  return t;
634
634
  };
635
- function P(t) {
635
+ function D(t) {
636
636
  const e = Y(ye), n = (e == null ? void 0 : e.pluginId) ?? t;
637
637
  if (!n)
638
638
  throw new Error(
@@ -640,22 +640,22 @@ function P(t) {
640
640
  );
641
641
  return n;
642
642
  }
643
- const zr = ({ pluginID: t, connectionID: e }) => {
644
- const n = P(t), r = j(), { showSnackbar: s } = U(), i = [n, "connection", "detail", e], { mutateAsync: o } = D({
643
+ const es = ({ pluginID: t, connectionID: e }) => {
644
+ const n = D(t), r = j(), { showSnackbar: s } = U(), i = [n, "connection", "detail", e], { mutateAsync: o } = P({
645
645
  mutationFn: async () => St(n, e),
646
646
  onSuccess(y) {
647
647
  r.setQueryData(i, y), r.invalidateQueries({
648
648
  queryKey: ["EDITOR_SCHEMAS", n, e]
649
649
  });
650
650
  },
651
- onError: k(s, "Failed to start connection")
652
- }), { mutateAsync: a } = D({
653
- mutationFn: async () => Re(n, e),
651
+ onError: L(s, "Failed to start connection")
652
+ }), { mutateAsync: a } = P({
653
+ mutationFn: async () => Ie(n, e),
654
654
  onSuccess(y) {
655
655
  r.setQueryData(i, y);
656
656
  },
657
- onError: k(s, "Failed to stop connection")
658
- }), { mutateAsync: c } = D({
657
+ onError: L(s, "Failed to stop connection")
658
+ }), { mutateAsync: c } = P({
659
659
  mutationFn: async (y) => _t(n, y),
660
660
  onSuccess(y, { name: f }) {
661
661
  s({ message: `Connection ${f} successfully updated`, status: "success" }), r.setQueryData(i, y), r.setQueriesData(
@@ -663,8 +663,8 @@ const zr = ({ pluginID: t, connectionID: e }) => {
663
663
  (d) => d == null ? void 0 : d.map((p) => p.id === e ? y : p)
664
664
  );
665
665
  },
666
- onError: k(s, "Failed to update connection")
667
- }), { mutateAsync: l } = D({
666
+ onError: L(s, "Failed to update connection")
667
+ }), { mutateAsync: l } = P({
668
668
  mutationFn: async () => wt(n, e),
669
669
  onSuccess() {
670
670
  s({ message: "Connection successfully removed", status: "success" }), r.setQueryData(i, void 0), r.setQueriesData(
@@ -672,7 +672,7 @@ const zr = ({ pluginID: t, connectionID: e }) => {
672
672
  (y) => y == null ? void 0 : y.filter((f) => f.id !== e)
673
673
  );
674
674
  },
675
- onError: k(s, "Failed to remove connection")
675
+ onError: L(s, "Failed to remove connection")
676
676
  });
677
677
  return {
678
678
  /**
@@ -699,18 +699,18 @@ const zr = ({ pluginID: t, connectionID: e }) => {
699
699
  */
700
700
  deleteConnection: l
701
701
  };
702
- }, bn = (t) => [t, "connection", "list"], Yr = ({ plugin: t }) => {
703
- const e = P(t), n = j(), { showSnackbar: r } = U(), s = bn(e), { mutateAsync: i } = D({
702
+ }, Fn = (t) => [t, "connection", "list"], ts = ({ plugin: t }) => {
703
+ const e = D(t), n = j(), { showSnackbar: r } = U(), s = Fn(e), { mutateAsync: i } = P({
704
704
  mutationFn: async (l) => De(e, l.id),
705
- onError: k(r, "Failed to start connection watch")
706
- }), { mutateAsync: o } = D({
705
+ onError: L(r, "Failed to start connection watch")
706
+ }), { mutateAsync: o } = P({
707
707
  mutationFn: async (l) => Ct(e, l.id),
708
- onError: k(r, "Failed to stop connection watch")
709
- }), a = v.useCallback((l) => {
708
+ onError: L(r, "Failed to stop connection watch")
709
+ }), a = b.useCallback((l) => {
710
710
  const u = l.data;
711
711
  console.log("got update to connections", u), n.setQueryData(s, u);
712
712
  }, [n, s]);
713
- return v.useEffect(() => {
713
+ return b.useEffect(() => {
714
714
  const l = x(`${e}/connection/sync`, a);
715
715
  return () => {
716
716
  l();
@@ -720,9 +720,9 @@ const zr = ({ pluginID: t, connectionID: e }) => {
720
720
  queryKey: s,
721
721
  queryFn: async () => {
722
722
  try {
723
- return await vt(e);
723
+ return await bt(e);
724
724
  } catch (l) {
725
- console.log(l), k(r, "Failed to load connections")(l);
725
+ console.log(l), L(r, "Failed to load connections")(l);
726
726
  }
727
727
  return [];
728
728
  },
@@ -732,25 +732,25 @@ const zr = ({ pluginID: t, connectionID: e }) => {
732
732
  startWatch: i,
733
733
  stopWatch: o
734
734
  };
735
- }, Jr = ({ pluginID: t, connectionID: e }) => {
736
- const n = P(t);
735
+ }, ns = ({ pluginID: t, connectionID: e }) => {
736
+ const n = D(t);
737
737
  return {
738
738
  /**
739
739
  * Get the connection
740
740
  */
741
741
  namespaces: O({
742
742
  queryKey: [n, "connection", "namespaces", e],
743
- queryFn: async () => bt(n, e)
743
+ queryFn: async () => vt(n, e)
744
744
  })
745
745
  };
746
- }, I = un(Vt, "WatchState");
746
+ }, F = dn(tn, "WatchState");
747
747
  function pe(t) {
748
748
  const e = Object.values(t.states), n = e.length;
749
749
  let r = 0, s = 0, i = 0, o = 0;
750
750
  for (const u of e)
751
- u === I.WatchStateSynced && r++, (u === I.WatchStateError || u === I.WatchStateFailed) && s++, u === I.WatchStateForbidden && i++, u === I.WatchStateSkipped && o++;
751
+ u === F.WatchStateSynced && r++, (u === F.WatchStateError || u === F.WatchStateFailed) && s++, u === F.WatchStateForbidden && i++, u === F.WatchStateSkipped && o++;
752
752
  const a = n - o, c = e.filter(
753
- (u) => u === I.WatchStateSynced || u === I.WatchStateError || u === I.WatchStateStopped || u === I.WatchStateFailed || u === I.WatchStateForbidden
753
+ (u) => u === F.WatchStateSynced || u === F.WatchStateError || u === F.WatchStateStopped || u === F.WatchStateFailed || u === F.WatchStateForbidden
754
754
  ).length, l = a > 0 ? c / a : 0;
755
755
  return {
756
756
  pluginID: t.pluginID,
@@ -775,11 +775,11 @@ function Ye(t) {
775
775
  const e = t.reduce((r, s) => r + s.watchedTotal, 0);
776
776
  return e === 0 ? 0 : t.reduce((r, s) => r + s.doneCount, 0) / e;
777
777
  }
778
- function ge(t) {
778
+ function he(t) {
779
779
  return `${t.pluginId}/${t.connection}`;
780
780
  }
781
781
  function Je(t, e) {
782
- const n = ge(e);
782
+ const n = he(e);
783
783
  t.has(n) || t.set(n, {
784
784
  states: {},
785
785
  pluginID: e.pluginId,
@@ -788,54 +788,54 @@ function Je(t, e) {
788
788
  const r = t.get(n);
789
789
  return r.states[e.resourceKey] = e.state, r;
790
790
  }
791
- function Zr() {
791
+ function rs() {
792
792
  const [t, e] = q(/* @__PURE__ */ new Set()), [n, r] = q({}), [s, i] = q(/* @__PURE__ */ new Map()), o = W(/* @__PURE__ */ new Map()), [a, c] = q(/* @__PURE__ */ new Map());
793
793
  G(() => {
794
- const h = x("plugin/crash_recovery_failed", (F) => {
795
- const w = F.data, S = w == null ? void 0 : w.pluginID;
794
+ const g = x("plugin/crash_recovery_failed", (R) => {
795
+ const w = R.data, S = w == null ? void 0 : w.pluginID;
796
796
  S && c((E) => {
797
- const R = new Map(E);
798
- return R.set(S, w.error ?? "Crash recovery failed"), R;
797
+ const I = new Map(E);
798
+ return I.set(S, w.error ?? "Crash recovery failed"), I;
799
799
  });
800
- }), b = x("plugin/recovered", (F) => {
801
- const w = F.data, S = w == null ? void 0 : w.pluginID;
800
+ }), v = x("plugin/recovered", (R) => {
801
+ const w = R.data, S = w == null ? void 0 : w.pluginID;
802
802
  S && c((E) => {
803
803
  if (!E.has(S)) return E;
804
- const R = new Map(E);
805
- return R.delete(S), R;
804
+ const I = new Map(E);
805
+ return I.delete(S), I;
806
806
  });
807
807
  });
808
808
  return () => {
809
- h(), b();
809
+ g(), v();
810
810
  };
811
811
  }, []), G(() => {
812
- Ft().then((h) => {
813
- if (!h) return;
814
- const b = {}, F = /* @__PURE__ */ new Set(), w = /* @__PURE__ */ new Map();
815
- for (const [S, E] of Object.entries(h))
812
+ Rt().then((g) => {
813
+ if (!g) return;
814
+ const v = {}, R = /* @__PURE__ */ new Set(), w = /* @__PURE__ */ new Map();
815
+ for (const [S, E] of Object.entries(g))
816
816
  if (E) {
817
- b[S] = E.map((R) => R.connection);
818
- for (const R of E) {
819
- if (!R.started) continue;
820
- const L = `${S}/${R.connection.id}`;
821
- F.add(L);
817
+ v[S] = E.map((I) => I.connection);
818
+ for (const I of E) {
819
+ if (!I.started) continue;
820
+ const M = `${S}/${I.connection.id}`;
821
+ R.add(M);
822
822
  const N = {
823
823
  pluginID: S,
824
- connectionID: R.connection.id,
824
+ connectionID: I.connection.id,
825
825
  states: {}
826
826
  };
827
- if (R.resources)
828
- for (const [ie, ot] of Object.entries(R.resources))
827
+ if (I.resources)
828
+ for (const [ie, ot] of Object.entries(I.resources))
829
829
  N.states[ie] = ot;
830
- o.current.set(L, N), w.set(L, pe(N));
830
+ o.current.set(M, N), w.set(M, pe(N));
831
831
  }
832
832
  }
833
- r(b), e(F), i(w);
833
+ r(v), e(R), i(w);
834
834
  }).catch(() => {
835
835
  });
836
- }, []), G(() => x("connection/status", (b) => {
837
- const F = b.data, w = `${F.pluginID}/${F.connectionID}`;
838
- F.status === "DISCONNECTED" ? (e((S) => {
836
+ }, []), G(() => x("connection/status", (v) => {
837
+ const R = v.data, w = `${R.pluginID}/${R.connectionID}`;
838
+ R.status === "DISCONNECTED" ? (e((S) => {
839
839
  const E = new Set(S);
840
840
  return E.delete(w), E;
841
841
  }), i((S) => {
@@ -844,76 +844,76 @@ function Zr() {
844
844
  }), o.current.delete(w)) : e((S) => {
845
845
  const E = new Set(S);
846
846
  return E.add(w), E;
847
- }), Rt().then((S) => {
847
+ }), It().then((S) => {
848
848
  if (!S) return;
849
849
  const E = {};
850
- for (const [R, L] of Object.entries(S))
851
- L != null && (E[R] = L);
850
+ for (const [I, M] of Object.entries(S))
851
+ M != null && (E[I] = M);
852
852
  r(E);
853
853
  }).catch(() => {
854
854
  });
855
855
  }), []);
856
- const l = M((h) => {
857
- const b = h.data, F = ge(b);
856
+ const l = k((g) => {
857
+ const v = g.data, R = he(v);
858
858
  e((E) => {
859
- if (E.has(F)) return E;
860
- const R = new Set(E);
861
- return R.add(F), R;
859
+ if (E.has(R)) return E;
860
+ const I = new Set(E);
861
+ return I.add(R), I;
862
862
  });
863
- const w = Je(o.current, b), S = pe(w);
863
+ const w = Je(o.current, v), S = pe(w);
864
864
  i((E) => {
865
- const R = new Map(E);
866
- return R.set(F, S), R;
865
+ const I = new Map(E);
866
+ return I.set(R, S), I;
867
867
  });
868
868
  }, []);
869
869
  G(() => x("watch/STATE", l), [l]);
870
- const u = M(async (h, b) => {
871
- await Re(h, b);
872
- }, []), y = M(async (h, b) => {
873
- await De(h, b);
874
- }, []), f = M(async (h) => {
875
- const b = a.get(h);
876
- c((F) => {
877
- if (!F.has(h)) return F;
878
- const w = new Map(F);
879
- return w.delete(h), w;
870
+ const u = k(async (g, v) => {
871
+ await Ie(g, v);
872
+ }, []), y = k(async (g, v) => {
873
+ await De(g, v);
874
+ }, []), f = k(async (g) => {
875
+ const v = a.get(g);
876
+ c((R) => {
877
+ if (!R.has(g)) return R;
878
+ const w = new Map(R);
879
+ return w.delete(g), w;
880
880
  });
881
881
  try {
882
- await It(h);
883
- } catch (F) {
882
+ await Ft(g);
883
+ } catch (R) {
884
884
  throw c((w) => {
885
885
  const S = new Map(w);
886
- return S.set(h, b ?? "Reload failed"), S;
887
- }), F;
886
+ return S.set(g, v ?? "Reload failed"), S;
887
+ }), R;
888
888
  }
889
889
  }, [a]), d = [];
890
- for (const h of t) {
891
- const [b, F] = h.split("/", 2), S = (n[b] ?? []).find((ie) => ie.id === F), E = s.get(h), R = E != null && !ne(E), L = E != null && E.errorCount > 0, N = a.get(b);
890
+ for (const g of t) {
891
+ const [v, R] = g.split("/", 2), S = (n[v] ?? []).find((ie) => ie.id === R), E = s.get(g), I = E != null && !ne(E), M = E != null && E.errorCount > 0, N = a.get(v);
892
892
  d.push({
893
- pluginID: b,
894
- connectionID: F,
895
- name: (S == null ? void 0 : S.name) ?? F,
893
+ pluginID: v,
894
+ connectionID: R,
895
+ name: (S == null ? void 0 : S.name) ?? R,
896
896
  avatar: (S == null ? void 0 : S.avatar) ?? "",
897
897
  isStarted: !0,
898
898
  sync: E,
899
- isSyncing: R,
900
- hasErrors: L || N != null,
899
+ isSyncing: I,
900
+ hasErrors: M || N != null,
901
901
  pluginFailed: N != null,
902
902
  pluginError: N
903
903
  });
904
904
  }
905
905
  const p = /* @__PURE__ */ new Map();
906
- for (const h of d) {
907
- const b = p.get(h.pluginID) ?? [];
908
- b.push(h), p.set(h.pluginID, b);
906
+ for (const g of d) {
907
+ const v = p.get(g.pluginID) ?? [];
908
+ v.push(g), p.set(g.pluginID, v);
909
909
  }
910
- const _ = Array.from(s.values()), C = d.filter((h) => h.isSyncing), g = d.filter((h) => h.hasErrors), m = d.filter((h) => h.pluginFailed);
910
+ const _ = Array.from(s.values()), C = d.filter((g) => g.isSyncing), h = d.filter((g) => g.hasErrors), m = d.filter((g) => g.pluginFailed);
911
911
  return {
912
912
  entries: d,
913
913
  grouped: p,
914
914
  connectedCount: d.length,
915
915
  syncingCount: C.length,
916
- errorCount: g.length,
916
+ errorCount: h.length,
917
917
  failedCount: m.length,
918
918
  hasSyncing: ze(_),
919
919
  aggregateProgress: Ye(_),
@@ -922,19 +922,19 @@ function Zr() {
922
922
  retryPlugin: f
923
923
  };
924
924
  }
925
- function Fn(t, e) {
925
+ function In(t, e) {
926
926
  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;
927
927
  }
928
- function Xr(t, e, n) {
929
- const r = P(t), s = j(), i = [r, "data", e], o = O({
928
+ function ss(t, e, n) {
929
+ const r = D(t), s = j(), i = [r, "data", e], o = O({
930
930
  queryKey: i,
931
931
  queryFn: async () => {
932
932
  const c = await Dt(r, e);
933
- return c == null ? n : Fn(c, n) ? c : (console.warn(
933
+ return c == null ? n : In(c, n) ? c : (console.warn(
934
934
  `[usePluginData] stored value for "${e}" has unexpected type (expected ${Array.isArray(n) ? "array" : typeof n}, got ${Array.isArray(c) ? "array" : typeof c}). Using default.`
935
935
  ), n);
936
936
  }
937
- }), a = D({
937
+ }), a = P({
938
938
  mutationFn: async (c) => {
939
939
  await Pt(r, e, c);
940
940
  },
@@ -958,19 +958,19 @@ function Xr(t, e, n) {
958
958
  isLoading: o.isLoading
959
959
  };
960
960
  }
961
- const Vr = () => {
962
- const t = Y(yn);
961
+ const os = () => {
962
+ const t = Y(hn);
963
963
  if (!t) throw new Error("useRightDrawer must be used within a RightDrawerProvider");
964
964
  return t;
965
965
  }, Ze = () => {
966
- const t = Y(pn);
966
+ const t = Y(gn);
967
967
  if (t === void 0)
968
968
  throw new Error("useBottomDrawer must be used within a BottomDrawerProvider");
969
969
  return t;
970
- }, es = ({ pluginID: t }) => {
971
- const e = P(t), { showSnackbar: n } = U(), { createTab: r, updateTab: s } = Ze();
970
+ }, is = ({ pluginID: t }) => {
971
+ const e = D(t), { showSnackbar: n } = U(), { createTab: r, updateTab: s } = Ze();
972
972
  return {
973
- createSession: D({
973
+ createSession: P({
974
974
  mutationFn: async ({ connectionID: o, icon: a, label: c, opts: l }) => {
975
975
  const u = `pending-${crypto.randomUUID()}`;
976
976
  r({
@@ -985,7 +985,7 @@ const Vr = () => {
985
985
  opts: { ...l }
986
986
  }
987
987
  });
988
- const y = en.createFrom({
988
+ const y = nn.createFrom({
989
989
  command: ["/bin/bash"],
990
990
  tty: !0,
991
991
  ...l
@@ -1013,8 +1013,8 @@ const Vr = () => {
1013
1013
  }
1014
1014
  }).mutateAsync
1015
1015
  };
1016
- }, ts = ({ pluginID: t }) => {
1017
- const e = P(t), { showSnackbar: n } = U(), { createTab: r } = Ze(), s = D({
1016
+ }, as = ({ pluginID: t }) => {
1017
+ const e = D(t), { showSnackbar: n } = U(), { createTab: r } = Ze(), s = P({
1018
1018
  mutationFn: async ({
1019
1019
  connectionID: o,
1020
1020
  resourceKey: a,
@@ -1027,11 +1027,11 @@ const Vr = () => {
1027
1027
  tailLines: p = 1e3,
1028
1028
  params: _
1029
1029
  }) => {
1030
- const C = tn.createFrom({
1030
+ const C = rn.createFrom({
1031
1031
  resource_key: a,
1032
1032
  resource_id: c,
1033
1033
  resource_data: l,
1034
- options: nn.createFrom({
1034
+ options: sn.createFrom({
1035
1035
  target: f ?? "",
1036
1036
  follow: d,
1037
1037
  include_previous: !1,
@@ -1042,37 +1042,37 @@ const Vr = () => {
1042
1042
  include_source_events: !0,
1043
1043
  params: _ ?? {}
1044
1044
  })
1045
- }), g = await Tt(e, o, C);
1046
- if (!g) throw new Error("Failed to create log session: null response");
1045
+ }), h = await Tt(e, o, C);
1046
+ if (!h) throw new Error("Failed to create log session: null response");
1047
1047
  return r({
1048
- id: g.id,
1049
- title: y ?? `Logs ${g.id.substring(0, 8)}`,
1048
+ id: h.id,
1049
+ title: y ?? `Logs ${h.id.substring(0, 8)}`,
1050
1050
  variant: "logs",
1051
1051
  icon: u ?? "LuLogs"
1052
- }), g;
1052
+ }), h;
1053
1053
  },
1054
- onError: k(n, "Failed to start log session")
1055
- }), i = D({
1054
+ onError: L(n, "Failed to start log session")
1055
+ }), i = P({
1056
1056
  mutationFn: async (o) => {
1057
1057
  await At(o);
1058
1058
  },
1059
- onError: k(n, "Failed to close log session")
1059
+ onError: L(n, "Failed to close log session")
1060
1060
  });
1061
1061
  return {
1062
1062
  createLogSession: s.mutateAsync,
1063
1063
  closeLogSession: i.mutateAsync
1064
1064
  };
1065
- }, ns = () => O({
1065
+ }, cs = () => O({
1066
1066
  queryKey: ["metric", "providers"],
1067
1067
  queryFn: xt,
1068
1068
  staleTime: 3e4
1069
- }), In = (t) => O({
1069
+ }), Dn = (t) => O({
1070
1070
  queryKey: ["metric", "providers", t],
1071
1071
  queryFn: () => Nt(t),
1072
1072
  enabled: !!t,
1073
1073
  staleTime: 3e4
1074
- }), rs = (t) => {
1075
- var C, g;
1074
+ }), us = (t) => {
1075
+ var C, h;
1076
1076
  const {
1077
1077
  connectionID: e,
1078
1078
  resourceKey: n,
@@ -1088,7 +1088,7 @@ const Vr = () => {
1088
1088
  } = t, {
1089
1089
  data: y,
1090
1090
  isLoading: f
1091
- } = In(n), d = y ?? [], p = c ? Math.max(
1091
+ } = Dn(n), d = y ?? [], p = c ? Math.max(
1092
1092
  Math.floor((c.end.getTime() - c.start.getTime()) / 250),
1093
1093
  15e3
1094
1094
  ) * 1e6 : 0, _ = O({
@@ -1102,10 +1102,10 @@ const Vr = () => {
1102
1102
  o,
1103
1103
  a,
1104
1104
  (C = c == null ? void 0 : c.start) == null ? void 0 : C.getTime(),
1105
- (g = c == null ? void 0 : c.end) == null ? void 0 : g.getTime()
1105
+ (h = c == null ? void 0 : c.end) == null ? void 0 : h.getTime()
1106
1106
  ],
1107
1107
  queryFn: async () => {
1108
- const m = await kt(
1108
+ const m = await Lt(
1109
1109
  e,
1110
1110
  n,
1111
1111
  r,
@@ -1116,10 +1116,10 @@ const Vr = () => {
1116
1116
  ((c == null ? void 0 : c.start) ?? /* @__PURE__ */ new Date(0)).toISOString(),
1117
1117
  ((c == null ? void 0 : c.end) ?? /* @__PURE__ */ new Date(0)).toISOString(),
1118
1118
  p
1119
- ), h = {};
1120
- for (const [b, F] of Object.entries(m))
1121
- F != null && (h[b] = F);
1122
- return h;
1119
+ ), g = {};
1120
+ for (const [v, R] of Object.entries(m))
1121
+ R != null && (g[v] = R);
1122
+ return g;
1123
1123
  },
1124
1124
  enabled: u && !!e && !!n && (n.startsWith("cluster::") || !!r) && d.length > 0,
1125
1125
  refetchInterval: l > 0 ? l : void 0,
@@ -1135,7 +1135,7 @@ const Vr = () => {
1135
1135
  error: _.error,
1136
1136
  refetch: _.refetch
1137
1137
  };
1138
- }, ss = (t) => {
1138
+ }, ls = (t) => {
1139
1139
  const {
1140
1140
  pluginID: e,
1141
1141
  connectionID: n,
@@ -1146,10 +1146,10 @@ const Vr = () => {
1146
1146
  metricIDs: a = [],
1147
1147
  interval: c = 1e4,
1148
1148
  enabled: l = !0
1149
- } = t, u = P(e), [y, f] = q(null), [d, p] = q(null), [_, C] = q(!1), [g, m] = q(null), h = W(null), b = M(async () => {
1149
+ } = t, u = D(e), [y, f] = q(null), [d, p] = q(null), [_, C] = q(!1), [h, m] = q(null), g = W(null), v = k(async () => {
1150
1150
  if (!(!l || !u || !n || !r || !s))
1151
1151
  try {
1152
- const w = await Mt(u, n, {
1152
+ const w = await kt(u, n, {
1153
1153
  resource_key: r,
1154
1154
  resource_id: s,
1155
1155
  resource_namespace: i,
@@ -1159,53 +1159,53 @@ const Vr = () => {
1159
1159
  // ms to nanoseconds for Go time.Duration
1160
1160
  });
1161
1161
  p(w), C(!0), m(null);
1162
- const S = x(`core/metrics/data/${w}`, (R) => {
1163
- const L = R.data;
1162
+ const S = x(`core/metrics/data/${w}`, (I) => {
1163
+ const M = I.data;
1164
1164
  try {
1165
- const N = JSON.parse(L);
1165
+ const N = JSON.parse(M);
1166
1166
  N.results && f(N.results);
1167
1167
  } catch (N) {
1168
1168
  console.error("Failed to parse metric stream data:", N);
1169
1169
  }
1170
- }), E = x(`core/metrics/error/${w}`, (R) => {
1171
- const L = R.data;
1170
+ }), E = x(`core/metrics/error/${w}`, (I) => {
1171
+ const M = I.data;
1172
1172
  try {
1173
- const N = JSON.parse(L);
1173
+ const N = JSON.parse(M);
1174
1174
  m(N.error || "Unknown error");
1175
1175
  } catch {
1176
1176
  m("Failed to parse metric stream error");
1177
1177
  }
1178
1178
  });
1179
- h.current = () => {
1179
+ g.current = () => {
1180
1180
  S(), E();
1181
1181
  };
1182
1182
  } catch (w) {
1183
1183
  m(w instanceof Error ? w.message : String(w));
1184
1184
  }
1185
- }, [u, n, r, s, i, a, c, l]), F = M(async () => {
1185
+ }, [u, n, r, s, i, a, c, l]), R = k(async () => {
1186
1186
  if (d)
1187
1187
  try {
1188
1188
  await Ee(d);
1189
1189
  } catch (w) {
1190
1190
  console.error("Failed to unsubscribe:", w);
1191
1191
  }
1192
- h.current && (h.current(), h.current = null), p(null), C(!1);
1192
+ g.current && (g.current(), g.current = null), p(null), C(!1);
1193
1193
  }, [d]);
1194
1194
  return G(() => () => {
1195
- d && Ee(d).catch(console.error), h.current && h.current();
1195
+ d && Ee(d).catch(console.error), g.current && g.current();
1196
1196
  }, [d]), {
1197
1197
  data: y,
1198
1198
  subscriptionID: d,
1199
1199
  isStreaming: _,
1200
- error: g,
1201
- start: b,
1202
- stop: F
1200
+ error: h,
1201
+ start: v,
1202
+ stop: R
1203
1203
  };
1204
1204
  }, H = ["networker", "portforward", "all-sessions"];
1205
- function os() {
1205
+ function ds() {
1206
1206
  const { showSnackbar: t } = U(), e = j(), n = O({
1207
1207
  queryKey: [...H],
1208
- queryFn: async () => Lt().catch((i) => {
1208
+ queryFn: async () => Mt().catch((i) => {
1209
1209
  if (Q(i).detail.includes("not found")) return [];
1210
1210
  throw i;
1211
1211
  }),
@@ -1221,9 +1221,9 @@ function os() {
1221
1221
  i(), o();
1222
1222
  };
1223
1223
  }, [e]);
1224
- const r = n.data ?? [], s = D({
1224
+ const r = n.data ?? [], s = P({
1225
1225
  mutationFn: async (i) => Pe(i),
1226
- onError: k(t, "Failed to close port forwarding session"),
1226
+ onError: L(t, "Failed to close port forwarding session"),
1227
1227
  onSuccess: async () => {
1228
1228
  await e.invalidateQueries({ queryKey: [...H] });
1229
1229
  }
@@ -1235,10 +1235,10 @@ function os() {
1235
1235
  openInBrowser: (i) => qe(`http://localhost:${i}`)
1236
1236
  };
1237
1237
  }
1238
- function is({ pluginID: t, connectionID: e, resourceID: n }) {
1239
- const r = P(t), s = ["networker", "portforward", "sessions", r, e, n], { showSnackbar: i } = U(), o = j(), a = O({
1238
+ function fs({ pluginID: t, connectionID: e, resourceID: n }) {
1239
+ const r = D(t), s = ["networker", "portforward", "sessions", r, e, n], { showSnackbar: i } = U(), o = j(), a = O({
1240
1240
  queryKey: s,
1241
- queryFn: async () => $t(r, e, rn.createFrom({
1241
+ queryFn: async () => $t(r, e, on.createFrom({
1242
1242
  resource_id: n,
1243
1243
  connection_id: e
1244
1244
  })).catch((u) => {
@@ -1246,9 +1246,9 @@ function is({ pluginID: t, connectionID: e, resourceID: n }) {
1246
1246
  return y.detail.includes("not found") ? [] : (i({ message: "Failed to fetch port forward sessions", status: "error", details: y.detail }), []);
1247
1247
  }),
1248
1248
  retry: !1
1249
- }), c = D({
1249
+ }), c = P({
1250
1250
  mutationFn: async ({ opts: u }) => {
1251
- const y = sn.createFrom({
1251
+ const y = an.createFrom({
1252
1252
  local_port: u.localPort || 0,
1253
1253
  remote_port: u.remotePort,
1254
1254
  protocol: u.protocol || "TCP",
@@ -1266,16 +1266,16 @@ function is({ pluginID: t, connectionID: e, resourceID: n }) {
1266
1266
  if (!f) throw new Error("Failed to start port forwarding: null response");
1267
1267
  return u.openInBrowser && qe(`http://localhost:${f.local_port}`), f;
1268
1268
  },
1269
- onError: k(i, "Failed to start port forwarding session"),
1269
+ onError: L(i, "Failed to start port forwarding session"),
1270
1270
  onSuccess: async () => {
1271
1271
  await Promise.all([
1272
1272
  o.invalidateQueries({ queryKey: s }),
1273
1273
  o.invalidateQueries({ queryKey: [...H] })
1274
1274
  ]);
1275
1275
  }
1276
- }), l = D({
1276
+ }), l = P({
1277
1277
  mutationFn: async ({ opts: u }) => Pe(u.sessionID),
1278
- onError: k(i, "Failed to close port forwarding session"),
1278
+ onError: L(i, "Failed to close port forwarding session"),
1279
1279
  onSuccess: async () => {
1280
1280
  await Promise.all([
1281
1281
  o.invalidateQueries({ queryKey: s }),
@@ -1289,18 +1289,18 @@ function is({ pluginID: t, connectionID: e, resourceID: n }) {
1289
1289
  close: l.mutateAsync
1290
1290
  };
1291
1291
  }
1292
- const as = () => {
1293
- const t = v.useContext(hn);
1292
+ const ps = () => {
1293
+ const t = b.useContext(mn);
1294
1294
  if (!t) throw new Error("useConfirmationModal must be used within a ConfirmationModalProvider");
1295
1295
  return t;
1296
- }, cs = ({
1296
+ }, ys = ({
1297
1297
  pluginID: t,
1298
1298
  connectionID: e,
1299
1299
  resourceKey: n,
1300
1300
  resourceID: r,
1301
1301
  namespace: s = ""
1302
1302
  }) => {
1303
- const i = P(t), o = j(), { showSnackbar: a } = U(), c = ["RESOURCE", i, e, n, r, s], { mutateAsync: l } = D({
1303
+ const i = D(t), o = j(), { showSnackbar: a } = U(), c = ["RESOURCE", i, e, n, r, s], { mutateAsync: l } = P({
1304
1304
  mutationFn: async (f) => Oe(i, e, n, Ne.createFrom({
1305
1305
  input: f.input,
1306
1306
  id: r,
@@ -1309,9 +1309,9 @@ const as = () => {
1309
1309
  onSuccess: async () => {
1310
1310
  a(`Resource ${r} updated`, "success"), await o.invalidateQueries({ queryKey: c });
1311
1311
  },
1312
- onError: k(a, `Failed to update resource ${r}`)
1313
- }), { mutateAsync: u } = D({
1314
- mutationFn: async (f = {}) => Te(i, e, n, ke.createFrom({
1312
+ onError: L(a, `Failed to update resource ${r}`)
1313
+ }), { mutateAsync: u } = P({
1314
+ mutationFn: async (f = {}) => Te(i, e, n, Le.createFrom({
1315
1315
  id: r,
1316
1316
  namespace: s,
1317
1317
  gracePeriodSeconds: f.gracePeriodSeconds
@@ -1319,7 +1319,7 @@ const as = () => {
1319
1319
  onSuccess: async () => {
1320
1320
  a(`Resource ${r} deleted`, "success"), await o.invalidateQueries({ queryKey: c });
1321
1321
  },
1322
- onError: k(a, `Failed to delete resource ${r}`)
1322
+ onError: L(a, `Failed to delete resource ${r}`)
1323
1323
  });
1324
1324
  return {
1325
1325
  /**
@@ -1328,7 +1328,7 @@ const as = () => {
1328
1328
  */
1329
1329
  resource: O({
1330
1330
  queryKey: c,
1331
- queryFn: async () => qt(i, e, n, on.createFrom({
1331
+ queryFn: async () => qt(i, e, n, cn.createFrom({
1332
1332
  id: r,
1333
1333
  namespace: s
1334
1334
  })),
@@ -1349,7 +1349,7 @@ const as = () => {
1349
1349
  */
1350
1350
  remove: u
1351
1351
  };
1352
- }, us = (t) => {
1352
+ }, gs = (t) => {
1353
1353
  const e = ["component", t.plugin, t.resource, t.area];
1354
1354
  return {
1355
1355
  /**
@@ -1361,8 +1361,8 @@ const as = () => {
1361
1361
  queryFn: async () => Wt(t)
1362
1362
  })
1363
1363
  };
1364
- }, ls = ({ pluginID: t, connectionID: e }) => {
1365
- const n = P(t);
1364
+ }, hs = ({ pluginID: t, connectionID: e }) => {
1365
+ const n = D(t);
1366
1366
  return {
1367
1367
  /**
1368
1368
  * The resource groups for the given plugin and connection.
@@ -1373,16 +1373,16 @@ const as = () => {
1373
1373
  retry: !1
1374
1374
  })
1375
1375
  };
1376
- }, ds = ({
1376
+ }, ms = ({
1377
1377
  pluginID: t,
1378
1378
  connectionID: e,
1379
1379
  searches: n
1380
1380
  }) => {
1381
- const r = P(t), s = (o) => [r, e, o.key, o.namespaces, "list"];
1382
- return an({
1381
+ const r = D(t), s = (o) => [r, e, o.key, o.namespaces, "list"];
1382
+ return un({
1383
1383
  queries: n.map((o) => ({
1384
1384
  queryKey: s(o),
1385
- queryFn: async () => Ae(r, e, o.key, Me.createFrom({
1385
+ queryFn: async () => Ae(r, e, o.key, ke.createFrom({
1386
1386
  order: [{ field: "name", descending: !1 }],
1387
1387
  pagination: { page: 1, pageSize: 200 },
1388
1388
  namespaces: o.namespaces
@@ -1390,8 +1390,8 @@ const as = () => {
1390
1390
  retry: !1
1391
1391
  }))
1392
1392
  });
1393
- }, fs = ({ pluginID: t, resourceKey: e }) => {
1394
- const n = P(t);
1393
+ }, Ss = ({ pluginID: t, resourceKey: e }) => {
1394
+ const n = D(t);
1395
1395
  return {
1396
1396
  /**
1397
1397
  * The current settings from the provider.
@@ -1402,8 +1402,8 @@ const as = () => {
1402
1402
  retry: !1
1403
1403
  })
1404
1404
  };
1405
- }, ps = ({ pluginID: t, connectionID: e }) => {
1406
- const n = P(t);
1405
+ }, _s = ({ pluginID: t, connectionID: e }) => {
1406
+ const n = D(t);
1407
1407
  return {
1408
1408
  /**
1409
1409
  * The resource types for the given plugin and connection.
@@ -1416,14 +1416,14 @@ const as = () => {
1416
1416
  };
1417
1417
  };
1418
1418
  var ee = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
1419
- function Rn(t) {
1419
+ function Pn(t) {
1420
1420
  return t && t.__esModule && Object.prototype.hasOwnProperty.call(t, "default") ? t.default : t;
1421
1421
  }
1422
- var Dn = "Expected a function", Xe = "__lodash_hash_undefined__", Pn = "[object Function]", On = "[object GeneratorFunction]", Tn = "[object Symbol]", An = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, xn = /^\w*$/, Nn = /^\./, kn = /[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g, Mn = /[\\^$.*+?()[\]{}|]/g, Ln = /\\(\\)?/g, $n = /^\[object .+?Constructor\]$/, Un = typeof ee == "object" && ee && ee.Object === Object && ee, qn = typeof self == "object" && self && self.Object === Object && self, me = Un || qn || Function("return this")();
1423
- function Wn(t, e) {
1422
+ var On = "Expected a function", Xe = "__lodash_hash_undefined__", Tn = "[object Function]", An = "[object GeneratorFunction]", xn = "[object Symbol]", Nn = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, Ln = /^\w*$/, kn = /^\./, Mn = /[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g, $n = /[\\^$.*+?()[\]{}|]/g, Un = /\\(\\)?/g, qn = /^\[object .+?Constructor\]$/, Wn = typeof ee == "object" && ee && ee.Object === Object && ee, Gn = typeof self == "object" && self && self.Object === Object && self, me = Wn || Gn || Function("return this")();
1423
+ function jn(t, e) {
1424
1424
  return t == null ? void 0 : t[e];
1425
1425
  }
1426
- function Gn(t) {
1426
+ function Qn(t) {
1427
1427
  var e = !1;
1428
1428
  if (t != null && typeof t.toString != "function")
1429
1429
  try {
@@ -1432,12 +1432,12 @@ function Gn(t) {
1432
1432
  }
1433
1433
  return e;
1434
1434
  }
1435
- var jn = Array.prototype, Qn = Function.prototype, Ve = Object.prototype, le = me["__core-js_shared__"], ve = function() {
1435
+ var Kn = Array.prototype, Bn = Function.prototype, Ve = Object.prototype, le = me["__core-js_shared__"], be = function() {
1436
1436
  var t = /[^.]+$/.exec(le && le.keys && le.keys.IE_PROTO || "");
1437
1437
  return t ? "Symbol(src)_1." + t : "";
1438
- }(), et = Qn.toString, Se = Ve.hasOwnProperty, tt = Ve.toString, Kn = RegExp(
1439
- "^" + et.call(Se).replace(Mn, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"
1440
- ), be = me.Symbol, Bn = jn.splice, Hn = nt(me, "Map"), Z = nt(Object, "create"), Fe = be ? be.prototype : void 0, Ie = Fe ? Fe.toString : void 0;
1438
+ }(), et = Bn.toString, Se = Ve.hasOwnProperty, tt = Ve.toString, Hn = RegExp(
1439
+ "^" + et.call(Se).replace($n, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"
1440
+ ), ve = me.Symbol, zn = Kn.splice, Yn = nt(me, "Map"), Z = nt(Object, "create"), Re = ve ? ve.prototype : void 0, Fe = Re ? Re.toString : void 0;
1441
1441
  function K(t) {
1442
1442
  var e = -1, n = t ? t.length : 0;
1443
1443
  for (this.clear(); ++e < n; ) {
@@ -1445,13 +1445,13 @@ function K(t) {
1445
1445
  this.set(r[0], r[1]);
1446
1446
  }
1447
1447
  }
1448
- function zn() {
1448
+ function Jn() {
1449
1449
  this.__data__ = Z ? Z(null) : {};
1450
1450
  }
1451
- function Yn(t) {
1451
+ function Zn(t) {
1452
1452
  return this.has(t) && delete this.__data__[t];
1453
1453
  }
1454
- function Jn(t) {
1454
+ function Xn(t) {
1455
1455
  var e = this.__data__;
1456
1456
  if (Z) {
1457
1457
  var n = e[t];
@@ -1459,19 +1459,19 @@ function Jn(t) {
1459
1459
  }
1460
1460
  return Se.call(e, t) ? e[t] : void 0;
1461
1461
  }
1462
- function Zn(t) {
1462
+ function Vn(t) {
1463
1463
  var e = this.__data__;
1464
1464
  return Z ? e[t] !== void 0 : Se.call(e, t);
1465
1465
  }
1466
- function Xn(t, e) {
1466
+ function er(t, e) {
1467
1467
  var n = this.__data__;
1468
1468
  return n[t] = Z && e === void 0 ? Xe : e, this;
1469
1469
  }
1470
- K.prototype.clear = zn;
1471
- K.prototype.delete = Yn;
1472
- K.prototype.get = Jn;
1473
- K.prototype.has = Zn;
1474
- K.prototype.set = Xn;
1470
+ K.prototype.clear = Jn;
1471
+ K.prototype.delete = Zn;
1472
+ K.prototype.get = Xn;
1473
+ K.prototype.has = Vn;
1474
+ K.prototype.set = er;
1475
1475
  function J(t) {
1476
1476
  var e = -1, n = t ? t.length : 0;
1477
1477
  for (this.clear(); ++e < n; ) {
@@ -1479,32 +1479,32 @@ function J(t) {
1479
1479
  this.set(r[0], r[1]);
1480
1480
  }
1481
1481
  }
1482
- function Vn() {
1482
+ function tr() {
1483
1483
  this.__data__ = [];
1484
1484
  }
1485
- function er(t) {
1485
+ function nr(t) {
1486
1486
  var e = this.__data__, n = se(e, t);
1487
1487
  if (n < 0)
1488
1488
  return !1;
1489
1489
  var r = e.length - 1;
1490
- return n == r ? e.pop() : Bn.call(e, n, 1), !0;
1490
+ return n == r ? e.pop() : zn.call(e, n, 1), !0;
1491
1491
  }
1492
- function tr(t) {
1492
+ function rr(t) {
1493
1493
  var e = this.__data__, n = se(e, t);
1494
1494
  return n < 0 ? void 0 : e[n][1];
1495
1495
  }
1496
- function nr(t) {
1496
+ function sr(t) {
1497
1497
  return se(this.__data__, t) > -1;
1498
1498
  }
1499
- function rr(t, e) {
1499
+ function or(t, e) {
1500
1500
  var n = this.__data__, r = se(n, t);
1501
1501
  return r < 0 ? n.push([t, e]) : n[r][1] = e, this;
1502
1502
  }
1503
- J.prototype.clear = Vn;
1504
- J.prototype.delete = er;
1505
- J.prototype.get = tr;
1506
- J.prototype.has = nr;
1507
- J.prototype.set = rr;
1503
+ J.prototype.clear = tr;
1504
+ J.prototype.delete = nr;
1505
+ J.prototype.get = rr;
1506
+ J.prototype.has = sr;
1507
+ J.prototype.set = or;
1508
1508
  function B(t) {
1509
1509
  var e = -1, n = t ? t.length : 0;
1510
1510
  for (this.clear(); ++e < n; ) {
@@ -1512,94 +1512,94 @@ function B(t) {
1512
1512
  this.set(r[0], r[1]);
1513
1513
  }
1514
1514
  }
1515
- function sr() {
1515
+ function ir() {
1516
1516
  this.__data__ = {
1517
1517
  hash: new K(),
1518
- map: new (Hn || J)(),
1518
+ map: new (Yn || J)(),
1519
1519
  string: new K()
1520
1520
  };
1521
1521
  }
1522
- function or(t) {
1522
+ function ar(t) {
1523
1523
  return oe(this, t).delete(t);
1524
1524
  }
1525
- function ir(t) {
1525
+ function cr(t) {
1526
1526
  return oe(this, t).get(t);
1527
1527
  }
1528
- function ar(t) {
1528
+ function ur(t) {
1529
1529
  return oe(this, t).has(t);
1530
1530
  }
1531
- function cr(t, e) {
1531
+ function lr(t, e) {
1532
1532
  return oe(this, t).set(t, e), this;
1533
1533
  }
1534
- B.prototype.clear = sr;
1535
- B.prototype.delete = or;
1536
- B.prototype.get = ir;
1537
- B.prototype.has = ar;
1538
- B.prototype.set = cr;
1534
+ B.prototype.clear = ir;
1535
+ B.prototype.delete = ar;
1536
+ B.prototype.get = cr;
1537
+ B.prototype.has = ur;
1538
+ B.prototype.set = lr;
1539
1539
  function se(t, e) {
1540
1540
  for (var n = t.length; n--; )
1541
- if (_r(t[n][0], e))
1541
+ if (Er(t[n][0], e))
1542
1542
  return n;
1543
1543
  return -1;
1544
1544
  }
1545
- function ur(t, e) {
1546
- e = pr(e, t) ? [e] : fr(e);
1545
+ function dr(t, e) {
1546
+ e = gr(e, t) ? [e] : yr(e);
1547
1547
  for (var n = 0, r = e.length; t != null && n < r; )
1548
- t = t[mr(e[n++])];
1548
+ t = t[_r(e[n++])];
1549
1549
  return n && n == r ? t : void 0;
1550
1550
  }
1551
- function lr(t) {
1552
- if (!st(t) || hr(t))
1551
+ function fr(t) {
1552
+ if (!st(t) || mr(t))
1553
1553
  return !1;
1554
- var e = wr(t) || Gn(t) ? Kn : $n;
1555
- return e.test(Sr(t));
1554
+ var e = Cr(t) || Qn(t) ? Hn : qn;
1555
+ return e.test(wr(t));
1556
1556
  }
1557
- function dr(t) {
1557
+ function pr(t) {
1558
1558
  if (typeof t == "string")
1559
1559
  return t;
1560
1560
  if (we(t))
1561
- return Ie ? Ie.call(t) : "";
1561
+ return Fe ? Fe.call(t) : "";
1562
1562
  var e = t + "";
1563
1563
  return e == "0" && 1 / t == -1 / 0 ? "-0" : e;
1564
1564
  }
1565
- function fr(t) {
1566
- return rt(t) ? t : gr(t);
1565
+ function yr(t) {
1566
+ return rt(t) ? t : Sr(t);
1567
1567
  }
1568
1568
  function oe(t, e) {
1569
1569
  var n = t.__data__;
1570
- return yr(e) ? n[typeof e == "string" ? "string" : "hash"] : n.map;
1570
+ return hr(e) ? n[typeof e == "string" ? "string" : "hash"] : n.map;
1571
1571
  }
1572
1572
  function nt(t, e) {
1573
- var n = Wn(t, e);
1574
- return lr(n) ? n : void 0;
1573
+ var n = jn(t, e);
1574
+ return fr(n) ? n : void 0;
1575
1575
  }
1576
- function pr(t, e) {
1576
+ function gr(t, e) {
1577
1577
  if (rt(t))
1578
1578
  return !1;
1579
1579
  var n = typeof t;
1580
- return n == "number" || n == "symbol" || n == "boolean" || t == null || we(t) ? !0 : xn.test(t) || !An.test(t) || e != null && t in Object(e);
1580
+ return n == "number" || n == "symbol" || n == "boolean" || t == null || we(t) ? !0 : Ln.test(t) || !Nn.test(t) || e != null && t in Object(e);
1581
1581
  }
1582
- function yr(t) {
1582
+ function hr(t) {
1583
1583
  var e = typeof t;
1584
1584
  return e == "string" || e == "number" || e == "symbol" || e == "boolean" ? t !== "__proto__" : t === null;
1585
1585
  }
1586
- function hr(t) {
1587
- return !!ve && ve in t;
1586
+ function mr(t) {
1587
+ return !!be && be in t;
1588
1588
  }
1589
- var gr = _e(function(t) {
1590
- t = Cr(t);
1589
+ var Sr = _e(function(t) {
1590
+ t = vr(t);
1591
1591
  var e = [];
1592
- return Nn.test(t) && e.push(""), t.replace(kn, function(n, r, s, i) {
1593
- e.push(s ? i.replace(Ln, "$1") : r || n);
1592
+ return kn.test(t) && e.push(""), t.replace(Mn, function(n, r, s, i) {
1593
+ e.push(s ? i.replace(Un, "$1") : r || n);
1594
1594
  }), e;
1595
1595
  });
1596
- function mr(t) {
1596
+ function _r(t) {
1597
1597
  if (typeof t == "string" || we(t))
1598
1598
  return t;
1599
1599
  var e = t + "";
1600
1600
  return e == "0" && 1 / t == -1 / 0 ? "-0" : e;
1601
1601
  }
1602
- function Sr(t) {
1602
+ function wr(t) {
1603
1603
  if (t != null) {
1604
1604
  try {
1605
1605
  return et.call(t);
@@ -1614,7 +1614,7 @@ function Sr(t) {
1614
1614
  }
1615
1615
  function _e(t, e) {
1616
1616
  if (typeof t != "function" || e && typeof e != "function")
1617
- throw new TypeError(Dn);
1617
+ throw new TypeError(On);
1618
1618
  var n = function() {
1619
1619
  var r = arguments, s = e ? e.apply(this, r) : r[0], i = n.cache;
1620
1620
  if (i.has(s))
@@ -1625,34 +1625,34 @@ function _e(t, e) {
1625
1625
  return n.cache = new (_e.Cache || B)(), n;
1626
1626
  }
1627
1627
  _e.Cache = B;
1628
- function _r(t, e) {
1628
+ function Er(t, e) {
1629
1629
  return t === e || t !== t && e !== e;
1630
1630
  }
1631
1631
  var rt = Array.isArray;
1632
- function wr(t) {
1632
+ function Cr(t) {
1633
1633
  var e = st(t) ? tt.call(t) : "";
1634
- return e == Pn || e == On;
1634
+ return e == Tn || e == An;
1635
1635
  }
1636
1636
  function st(t) {
1637
1637
  var e = typeof t;
1638
1638
  return !!t && (e == "object" || e == "function");
1639
1639
  }
1640
- function Er(t) {
1640
+ function br(t) {
1641
1641
  return !!t && typeof t == "object";
1642
1642
  }
1643
1643
  function we(t) {
1644
- return typeof t == "symbol" || Er(t) && tt.call(t) == Tn;
1644
+ return typeof t == "symbol" || br(t) && tt.call(t) == xn;
1645
1645
  }
1646
- function Cr(t) {
1647
- return t == null ? "" : dr(t);
1646
+ function vr(t) {
1647
+ return t == null ? "" : pr(t);
1648
1648
  }
1649
- function vr(t, e, n) {
1650
- var r = t == null ? void 0 : ur(t, e);
1649
+ function Rr(t, e, n) {
1650
+ var r = t == null ? void 0 : dr(t, e);
1651
1651
  return r === void 0 ? n : r;
1652
1652
  }
1653
- var br = vr;
1654
- const te = /* @__PURE__ */ Rn(br);
1655
- function Fr(t, e, n) {
1653
+ var Fr = Rr;
1654
+ const te = /* @__PURE__ */ Pn(Fr);
1655
+ function Ir(t, e, n) {
1656
1656
  const r = t ?? { result: [], success: !0, totalCount: 0 }, s = [...r.result ?? []];
1657
1657
  for (const i of e) {
1658
1658
  const o = te(i.payload.data, n);
@@ -1675,15 +1675,15 @@ function Fr(t, e, n) {
1675
1675
  }
1676
1676
  return { ...r, result: s };
1677
1677
  }
1678
- function Ir(t, e, n, r, s, i) {
1678
+ function Dr(t, e, n, r, s, i) {
1679
1679
  const o = (i == null ? void 0 : i.syncWindowMs) ?? 500, a = W([]), c = W(null), l = W(null), u = W(s);
1680
1680
  u.current = s;
1681
- const y = M(() => {
1681
+ const y = k(() => {
1682
1682
  const d = a.current;
1683
1683
  if (a.current = [], c.current = null, l.current = null, !(d.length === 0 || !r)) {
1684
1684
  t.setQueryData(
1685
1685
  e,
1686
- (p) => Fr(p, d, r)
1686
+ (p) => Ir(p, d, r)
1687
1687
  );
1688
1688
  for (const p of d)
1689
1689
  (p.type === "ADD" || p.type === "UPDATE") && t.setQueryData(
@@ -1691,7 +1691,7 @@ function Ir(t, e, n, r, s, i) {
1691
1691
  { result: p.payload.data }
1692
1692
  );
1693
1693
  }
1694
- }, [t, e, n, r]), f = M(
1694
+ }, [t, e, n, r]), f = k(
1695
1695
  (d) => {
1696
1696
  a.current.push(d), !(c.current !== null || l.current !== null) && (u.current === 1 ? c.current = setTimeout(y, o) : l.current = requestAnimationFrame(y));
1697
1697
  },
@@ -1701,69 +1701,69 @@ function Ir(t, e, n, r, s, i) {
1701
1701
  c.current !== null && (clearTimeout(c.current), c.current = null), l.current !== null && (cancelAnimationFrame(l.current), l.current = null);
1702
1702
  }, []), f;
1703
1703
  }
1704
- const ys = ({
1704
+ const ws = ({
1705
1705
  pluginID: t,
1706
1706
  connectionID: e,
1707
1707
  resourceKey: n,
1708
1708
  idAccessor: r,
1709
1709
  namespaces: s
1710
1710
  }) => {
1711
- const i = P(t), o = j(), { showSnackbar: a } = U(), c = v.useMemo(() => s ?? [], [s]), l = v.useMemo(
1711
+ const i = D(t), o = j(), { showSnackbar: a } = U(), c = b.useMemo(() => s ?? [], [s]), l = b.useMemo(
1712
1712
  () => [i, e, n, c, "list"],
1713
1713
  [i, e, n, c]
1714
- ), u = v.useCallback(
1715
- (C, g) => [i, e, n, g, C],
1714
+ ), u = b.useCallback(
1715
+ (C, h) => [i, e, n, h, C],
1716
1716
  [i, e, n]
1717
- ), { mutateAsync: y } = D({
1718
- mutationFn: async (C) => xe(i, e, n, Le.createFrom({
1717
+ ), { mutateAsync: y } = P({
1718
+ mutationFn: async (C) => xe(i, e, n, Me.createFrom({
1719
1719
  input: C.input,
1720
1720
  namespace: C.namespace ?? (c.length === 1 ? c[0] : "")
1721
1721
  })),
1722
1722
  onSuccess: async (C) => {
1723
- var b;
1724
- const g = C == null ? void 0 : C.result;
1723
+ var v;
1724
+ const h = C == null ? void 0 : C.result;
1725
1725
  let m = "";
1726
- (b = g == null ? void 0 : g.metadata) != null && b.name ? m = g.metadata.name : g != null && g.id ? m = g.id : g != null && g.name ? m = g.name : g != null && g.ID ? m = g.ID : g != null && g.Name && (m = g.Name);
1727
- const h = m ? `Resource ${m} created` : "Resource created";
1728
- a(h, "success"), await o.invalidateQueries({ queryKey: l });
1726
+ (v = h == null ? void 0 : h.metadata) != null && v.name ? m = h.metadata.name : h != null && h.id ? m = h.id : h != null && h.name ? m = h.name : h != null && h.ID ? m = h.ID : h != null && h.Name && (m = h.Name);
1727
+ const g = m ? `Resource ${m} created` : "Resource created";
1728
+ a(g, "success"), await o.invalidateQueries({ queryKey: l });
1729
1729
  },
1730
- onError: k(a, "Failed to create resource")
1730
+ onError: L(a, "Failed to create resource")
1731
1731
  }), f = O({
1732
1732
  queryKey: l,
1733
- queryFn: async () => Ae(i, e, n, Me.createFrom({
1733
+ queryFn: async () => Ae(i, e, n, ke.createFrom({
1734
1734
  order: [{ field: "name", descending: !1 }],
1735
1735
  pagination: { page: 1, pageSize: 200 },
1736
1736
  namespaces: c
1737
1737
  })),
1738
- placeholderData: (C, g) => C,
1738
+ placeholderData: (C, h) => C,
1739
1739
  retry: !1
1740
- }), [d, p] = v.useState(
1741
- I.WatchStateIdle
1740
+ }), [d, p] = b.useState(
1741
+ F.WatchStateIdle
1742
1742
  );
1743
- v.useEffect(() => x(
1743
+ b.useEffect(() => x(
1744
1744
  `${i}/${e}/watch/STATE`,
1745
- (g) => {
1746
- const m = g.data;
1745
+ (h) => {
1746
+ const m = h.data;
1747
1747
  m.resourceKey === n && p(m.state);
1748
1748
  }
1749
1749
  ), [i, e, n]);
1750
- const _ = Ir(o, l, u, r, d);
1751
- return v.useEffect(() => {
1750
+ const _ = Dr(o, l, u, r, d);
1751
+ return b.useEffect(() => {
1752
1752
  if (!r)
1753
1753
  return;
1754
1754
  Kt(i, e, n);
1755
1755
  const C = x(
1756
1756
  `${i}/${e}/${n}/ADD`,
1757
- (h) => _({ type: "ADD", payload: h.data })
1758
- ), g = x(
1757
+ (g) => _({ type: "ADD", payload: g.data })
1758
+ ), h = x(
1759
1759
  `${i}/${e}/${n}/UPDATE`,
1760
- (h) => _({ type: "UPDATE", payload: h.data })
1760
+ (g) => _({ type: "UPDATE", payload: g.data })
1761
1761
  ), m = x(
1762
1762
  `${i}/${e}/${n}/DELETE`,
1763
- (h) => _({ type: "DELETE", payload: h.data })
1763
+ (g) => _({ type: "DELETE", payload: g.data })
1764
1764
  );
1765
1765
  return () => {
1766
- C(), g(), m(), Bt(i, e, n);
1766
+ C(), h(), m(), Bt(i, e, n);
1767
1767
  };
1768
1768
  }, [i, e, n, _]), {
1769
1769
  /**
@@ -1782,19 +1782,19 @@ const ys = ({
1782
1782
  /** Current watch state for this resource type */
1783
1783
  watchState: d,
1784
1784
  /** Whether the watch is currently syncing */
1785
- isSyncing: d === I.WatchStateSyncing,
1785
+ isSyncing: d === F.WatchStateSyncing,
1786
1786
  /** Whether the watch has fully synced */
1787
- isSynced: d === I.WatchStateSynced,
1787
+ isSynced: d === F.WatchStateSynced,
1788
1788
  /** Whether the watch encountered an error */
1789
- watchError: d === I.WatchStateError
1789
+ watchError: d === F.WatchStateError
1790
1790
  };
1791
- }, hs = ({ pluginID: t }) => {
1792
- const e = P(t), { showSnackbar: n } = U(), r = D({
1791
+ }, Es = ({ pluginID: t }) => {
1792
+ const e = D(t), { showSnackbar: n } = U(), r = P({
1793
1793
  mutationFn: async ({ opts: o, input: a }) => xe(
1794
1794
  e,
1795
1795
  o.connectionID,
1796
1796
  o.resourceKey,
1797
- Le.createFrom({
1797
+ Me.createFrom({
1798
1798
  input: a.input,
1799
1799
  namespace: a.namespace ?? o.namespace ?? ""
1800
1800
  })
@@ -1805,7 +1805,7 @@ const ys = ({
1805
1805
  onError(o, { opts: a }) {
1806
1806
  z(n, o, `Failed to create resource ${a.resourceID}`);
1807
1807
  }
1808
- }), s = D({
1808
+ }), s = P({
1809
1809
  mutationFn: async ({ opts: o, input: a }) => Oe(
1810
1810
  e,
1811
1811
  o.connectionID,
@@ -1822,12 +1822,12 @@ const ys = ({
1822
1822
  onError(o, { opts: a }) {
1823
1823
  z(n, o, `Failed to update resource ${a.resourceID}`);
1824
1824
  }
1825
- }), i = D({
1825
+ }), i = P({
1826
1826
  mutationFn: async ({ opts: o, input: a }) => Te(
1827
1827
  e,
1828
1828
  o.connectionID,
1829
1829
  o.resourceKey,
1830
- ke.createFrom({
1830
+ Le.createFrom({
1831
1831
  id: o.resourceID,
1832
1832
  namespace: o.namespace ?? "",
1833
1833
  gracePeriodSeconds: a.gracePeriodSeconds
@@ -1845,13 +1845,13 @@ const ys = ({
1845
1845
  update: s.mutateAsync,
1846
1846
  remove: i.mutateAsync
1847
1847
  };
1848
- }, gs = ({
1848
+ }, Cs = ({
1849
1849
  pluginID: t,
1850
1850
  connectionID: e,
1851
1851
  resourceKey: n,
1852
1852
  enabled: r = !0
1853
1853
  }) => {
1854
- const s = P(t), i = O({
1854
+ const s = D(t), i = O({
1855
1855
  queryKey: ["RESOURCE_ACTIONS", s, e, n],
1856
1856
  queryFn: () => Ht(s, e, n),
1857
1857
  enabled: r && !!s && !!e && !!n,
@@ -1863,12 +1863,12 @@ const ys = ({
1863
1863
  isLoading: i.isLoading,
1864
1864
  error: i.error
1865
1865
  };
1866
- }, ms = ({
1866
+ }, bs = ({
1867
1867
  pluginID: t,
1868
1868
  connectionID: e,
1869
1869
  resourceKey: n
1870
1870
  }) => {
1871
- const r = P(t), s = j(), { showSnackbar: i } = U(), o = D({
1871
+ const r = D(t), s = j(), { showSnackbar: i } = U(), o = P({
1872
1872
  mutationFn: async ({ actionID: a, id: c = "", namespace: l = "", params: u = {} }) => zt(
1873
1873
  r,
1874
1874
  e,
@@ -1890,12 +1890,12 @@ const ys = ({
1890
1890
  isExecuting: o.isPending,
1891
1891
  error: o.error
1892
1892
  };
1893
- }, Ss = ({
1893
+ }, vs = ({
1894
1894
  pluginID: t,
1895
1895
  connectionID: e,
1896
1896
  enabled: n = !0
1897
1897
  }) => {
1898
- const r = P(t), s = O({
1898
+ const r = D(t), s = O({
1899
1899
  queryKey: ["EDITOR_SCHEMAS", r, e],
1900
1900
  queryFn: () => Yt(r, e),
1901
1901
  enabled: n && !!r && !!e,
@@ -1909,19 +1909,19 @@ const ys = ({
1909
1909
  error: s.error,
1910
1910
  refetch: s.refetch
1911
1911
  };
1912
- }, _s = ({
1912
+ }, Rs = ({
1913
1913
  pluginID: t,
1914
1914
  connectionID: e,
1915
1915
  enabled: n = !0
1916
1916
  }) => {
1917
- const r = P(t), s = j(), i = [r, e, "watch-state"], o = W([]), a = W(!1), c = M((f) => {
1917
+ const r = D(t), s = j(), i = [r, e, "watch-state"], o = W([]), a = W(!1), c = k((f) => {
1918
1918
  s.setQueryData(i, (d) => {
1919
1919
  if (!d) return d;
1920
1920
  const p = { ...d.resources, [f.resourceKey]: f.state }, _ = { ...d.resourceCounts, [f.resourceKey]: f.resourceCount };
1921
- let C = 0, g = 0;
1921
+ let C = 0, h = 0;
1922
1922
  for (const m of Object.values(p))
1923
- m === I.WatchStateSynced && C++, (m === I.WatchStateError || m === I.WatchStateFailed) && g++;
1924
- return { ...d, resources: p, resourceCounts: _, totalResources: Object.keys(p).length, syncedCount: C, errorCount: g };
1923
+ m === F.WatchStateSynced && C++, (m === F.WatchStateError || m === F.WatchStateFailed) && h++;
1924
+ return { ...d, resources: p, resourceCounts: _, totalResources: Object.keys(p).length, syncedCount: C, errorCount: h };
1925
1925
  });
1926
1926
  }, [s, r, e]), l = O({
1927
1927
  queryKey: i,
@@ -1930,11 +1930,11 @@ const ys = ({
1930
1930
  if (!f) throw new Error("Failed to get watch state: null response");
1931
1931
  const d = {};
1932
1932
  let p = 0, _ = 0;
1933
- for (const [g, m] of Object.entries(f.resources ?? {}))
1934
- m != null && (d[g] = m, m === I.WatchStateSynced && p++, m === I.WatchStateError && _++);
1933
+ for (const [h, m] of Object.entries(f.resources ?? {}))
1934
+ m != null && (d[h] = m, m === F.WatchStateSynced && p++, m === F.WatchStateError && _++);
1935
1935
  const C = {};
1936
- for (const [g, m] of Object.entries(f.resourceCounts ?? {}))
1937
- m != null && (C[g] = m);
1936
+ for (const [h, m] of Object.entries(f.resourceCounts ?? {}))
1937
+ m != null && (C[h] = m);
1938
1938
  return {
1939
1939
  connection: f.connectionId,
1940
1940
  resources: d,
@@ -1950,7 +1950,7 @@ const ys = ({
1950
1950
  if (!d || d.totalResources === 0) return 3e3;
1951
1951
  let p = 0;
1952
1952
  for (const _ of Object.values(d.resources))
1953
- (_ === I.WatchStateSynced || _ === I.WatchStateError || _ === I.WatchStateStopped || _ === I.WatchStateFailed || _ === I.WatchStateForbidden || _ === I.WatchStateSkipped) && p++;
1953
+ (_ === F.WatchStateSynced || _ === F.WatchStateError || _ === F.WatchStateStopped || _ === F.WatchStateFailed || _ === F.WatchStateForbidden || _ === F.WatchStateSkipped) && p++;
1954
1954
  return p >= d.totalResources ? !1 : 3e3;
1955
1955
  }
1956
1956
  });
@@ -1980,7 +1980,7 @@ const ys = ({
1980
1980
  let y = 0;
1981
1981
  if (u != null && u.resources)
1982
1982
  for (const f of Object.values(u.resources))
1983
- (f === I.WatchStateSynced || f === I.WatchStateError || f === I.WatchStateStopped || f === I.WatchStateFailed || f === I.WatchStateForbidden || f === I.WatchStateSkipped) && y++;
1983
+ (f === F.WatchStateSynced || f === F.WatchStateError || f === F.WatchStateStopped || f === F.WatchStateFailed || f === F.WatchStateForbidden || f === F.WatchStateSkipped) && y++;
1984
1984
  return {
1985
1985
  /** Full summary query result */
1986
1986
  summary: l,
@@ -1993,9 +1993,9 @@ const ys = ({
1993
1993
  /** Number of watches that encountered errors */
1994
1994
  errorCount: (u == null ? void 0 : u.errorCount) ?? 0
1995
1995
  };
1996
- }, ws = () => {
1997
- const [t, e] = q(/* @__PURE__ */ new Map()), n = W(/* @__PURE__ */ new Map()), r = W(/* @__PURE__ */ new Map()), s = M((l) => {
1998
- const u = l.data, y = ge(u), f = Je(n.current, u), d = pe(f);
1996
+ }, Fs = () => {
1997
+ const [t, e] = q(/* @__PURE__ */ new Map()), n = W(/* @__PURE__ */ new Map()), r = W(/* @__PURE__ */ new Map()), s = k((l) => {
1998
+ const u = l.data, y = he(u), f = Je(n.current, u), d = pe(f);
1999
1999
  if (e((p) => {
2000
2000
  const _ = new Map(p);
2001
2001
  return _.set(y, d), _;
@@ -2028,19 +2028,19 @@ const ys = ({
2028
2028
  /** Aggregate progress across all connections (0-1) */
2029
2029
  aggregateProgress: c
2030
2030
  };
2031
- }, Rr = () => {
2032
- const t = v.useContext(Qe);
2031
+ }, Pr = () => {
2032
+ const t = b.useContext(Qe);
2033
2033
  if (!t) throw new Error("useOperations must be used within an OperationsProvider");
2034
2034
  return t;
2035
- }, Es = ({
2035
+ }, Is = ({
2036
2036
  pluginID: t,
2037
2037
  connectionID: e,
2038
2038
  resourceKey: n
2039
2039
  }) => {
2040
- const r = P(t), { showSnackbar: s } = U(), { addOperation: i, updateOperation: o } = Rr(), a = v.useRef([]);
2041
- return v.useEffect(() => () => {
2040
+ const r = D(t), { showSnackbar: s } = U(), { addOperation: i, updateOperation: o } = Pr(), a = b.useRef([]);
2041
+ return b.useEffect(() => () => {
2042
2042
  a.current.forEach((l) => l());
2043
- }, []), { startStreamAction: v.useCallback(
2043
+ }, []), { startStreamAction: b.useCallback(
2044
2044
  async ({ actionID: l, id: u, namespace: y, label: f, params: d = {} }) => {
2045
2045
  try {
2046
2046
  const p = await Zt(
@@ -2060,9 +2060,9 @@ const ys = ({
2060
2060
  status: "running",
2061
2061
  startedAt: Date.now()
2062
2062
  });
2063
- const _ = `action/stream/${p}`, C = x(_, (g) => {
2064
- var h, b, F, w;
2065
- const m = g.data;
2063
+ const _ = `action/stream/${p}`, C = x(_, (h) => {
2064
+ var g, v, R, w;
2065
+ const m = h.data;
2066
2066
  switch (m.type) {
2067
2067
  case "progress": {
2068
2068
  const S = m.data ?? {};
@@ -2075,14 +2075,14 @@ const ys = ({
2075
2075
  case "complete":
2076
2076
  o(p, {
2077
2077
  status: "completed",
2078
- message: ((h = m.data) == null ? void 0 : h.message) ?? "Completed",
2078
+ message: ((g = m.data) == null ? void 0 : g.message) ?? "Completed",
2079
2079
  completedAt: Date.now()
2080
- }), s(((b = m.data) == null ? void 0 : b.message) ?? f + " completed", "success"), ae(_);
2080
+ }), s(((v = m.data) == null ? void 0 : v.message) ?? f + " completed", "success"), ae(_);
2081
2081
  break;
2082
2082
  case "error":
2083
2083
  o(p, {
2084
2084
  status: "error",
2085
- message: ((F = m.data) == null ? void 0 : F.message) ?? "Failed",
2085
+ message: ((R = m.data) == null ? void 0 : R.message) ?? "Failed",
2086
2086
  completedAt: Date.now()
2087
2087
  }), s(((w = m.data) == null ? void 0 : w.message) ?? f + " failed", "error"), ae(_);
2088
2088
  break;
@@ -2097,21 +2097,107 @@ const ys = ({
2097
2097
  },
2098
2098
  [r, e, n, i, o, s]
2099
2099
  ) };
2100
- }, Cs = () => {
2101
- const t = v.useContext(je);
2100
+ }, Or = 1e4, Tr = {
2101
+ owns: { outgoing: "Owns", incoming: "Owned by" },
2102
+ runs_on: { outgoing: "Runs on", incoming: "Running here" },
2103
+ uses: { outgoing: "Uses", incoming: "Used by" },
2104
+ exposes: { outgoing: "Exposes", incoming: "Exposed by" },
2105
+ manages: { outgoing: "Manages", incoming: "Managed by" },
2106
+ member_of: { outgoing: "Member of", incoming: "Members" },
2107
+ selects: { outgoing: "Selects", incoming: "Selected by" }
2108
+ };
2109
+ function Ds(t, e) {
2110
+ const n = Tr[t];
2111
+ if (n)
2112
+ return n[e];
2113
+ const r = t.replace(/_/g, " ");
2114
+ return e === "outgoing" ? r : `${r} (incoming)`;
2115
+ }
2116
+ function Ar(t, e) {
2117
+ return t.pluginId === e.pluginId && t.connectionId === e.connectionId && t.resourceKey === e.resourceKey && t.id === e.id && (t.namespace ?? "") === (e.namespace ?? "");
2118
+ }
2119
+ function xr(t, e) {
2120
+ return e.map((n) => {
2121
+ const r = Ar(n.source, t);
2122
+ return {
2123
+ resource: r ? n.target : n.source,
2124
+ type: n.type,
2125
+ direction: r ? "outgoing" : "incoming",
2126
+ label: n.label
2127
+ };
2128
+ });
2129
+ }
2130
+ const Ps = ({
2131
+ pluginID: t,
2132
+ connectionID: e,
2133
+ resourceKey: n,
2134
+ resourceID: r,
2135
+ namespace: s = "",
2136
+ direction: i = "both",
2137
+ relationshipType: o,
2138
+ enabled: a = !0,
2139
+ refetchInterval: c = Or
2140
+ }) => {
2141
+ const l = D(t), u = O({
2142
+ queryKey: ["RESOURCE_RELATED", l, e, n, s, r, i, o ?? null],
2143
+ queryFn: async () => Xt(l, e, n, s, r, i, o ?? null),
2144
+ enabled: a && !!l && !!e && !!n && !!r,
2145
+ refetchInterval: c
2146
+ }), y = {
2147
+ pluginId: l,
2148
+ connectionId: e,
2149
+ resourceKey: n,
2150
+ id: r,
2151
+ namespace: s
2152
+ }, f = u.data ?? [];
2153
+ return {
2154
+ /** One entry per edge, from the viewed resource's side. */
2155
+ related: xr(y, f),
2156
+ /** The raw graph edges. */
2157
+ edges: f,
2158
+ isLoading: u.isLoading,
2159
+ isFetching: u.isFetching,
2160
+ error: u.error,
2161
+ refetch: u.refetch
2162
+ };
2163
+ }, Os = ({
2164
+ pluginID: t,
2165
+ connectionID: e,
2166
+ resourceKey: n,
2167
+ resourceID: r,
2168
+ namespace: s = "",
2169
+ maxDepth: i = 3,
2170
+ enabled: o = !0,
2171
+ refetchInterval: a = 1e4
2172
+ }) => {
2173
+ const c = D(t), l = O({
2174
+ queryKey: ["RESOURCE_DEPENDENCY_TREE", c, e, n, s, r, i],
2175
+ queryFn: async () => Vt(c, e, n, s, r, i),
2176
+ enabled: o && !!c && !!e && !!n && !!r,
2177
+ refetchInterval: a
2178
+ });
2179
+ return {
2180
+ tree: l.data ?? null,
2181
+ isLoading: l.isLoading,
2182
+ isFetching: l.isFetching,
2183
+ error: l.error,
2184
+ refetch: l.refetch
2185
+ };
2186
+ }, Ts = () => {
2187
+ const t = b.useContext(je);
2102
2188
  if (!t)
2103
2189
  throw new Error("useSettings must be used within a SettingsProvider");
2104
2190
  return t;
2105
- }, vs = ({ to: t, withinContext: e, ...n }) => {
2106
- const { pluginId: r } = he();
2191
+ }, As = ({ to: t, withinContext: e, ...n }) => {
2192
+ const { pluginId: r } = ge();
2107
2193
  r || console.error("Link used outside of a plugin context");
2108
2194
  const s = `/_plugin/${r}${t.startsWith("/") ? "" : "/"}${t}`;
2109
- return v.useMemo(() => /* @__PURE__ */ A(lt, { style: { textDecoration: "none", color: "inherit" }, ...n, to: s }), [n, s]);
2195
+ return b.useMemo(() => /* @__PURE__ */ A(lt, { style: { textDecoration: "none", color: "inherit" }, ...n, to: s }), [n, s]);
2110
2196
  };
2111
- function bs() {
2112
- const t = dt(), e = ft(), { pluginId: n } = he();
2197
+ function xs() {
2198
+ const t = dt(), e = ft(), { pluginId: n } = ge();
2113
2199
  n || console.error("usePluginRouter used outside of a plugin context");
2114
- const r = `/_plugin/${n}`, s = e.pathname.startsWith(r) ? e.pathname.slice(r.length) || "/" : e.pathname, i = M((o, a) => {
2200
+ const r = `/_plugin/${n}`, s = e.pathname.startsWith(r) ? e.pathname.slice(r.length) || "/" : e.pathname, i = k((o, a) => {
2115
2201
  const { ...c } = a ?? {};
2116
2202
  o.startsWith("/") ? t(`${r}${o}`, c) : t(o, c);
2117
2203
  }, [t, r]);
@@ -2121,9 +2207,9 @@ function bs() {
2121
2207
  pluginPath: s
2122
2208
  }), [e, i, s]);
2123
2209
  }
2124
- class Fs {
2210
+ class Ns {
2125
2211
  }
2126
- class Is {
2212
+ class Ls {
2127
2213
  constructor() {
2128
2214
  T(this, "_extensions");
2129
2215
  /**
@@ -2216,84 +2302,88 @@ class Is {
2216
2302
  return this._routes = e, this;
2217
2303
  }
2218
2304
  }
2219
- var Dr = /* @__PURE__ */ ((t) => (t.MISSING_MANIFEST = "MISSING_MANIFEST", t.MISSING_PLUGIN = "MISSING_PLUGIN", t.MISSING_ENTRYPOINT = "MISSING_ENTRYPOINT", t))(Dr || {});
2220
- const Rs = (t) => {
2305
+ var Nr = /* @__PURE__ */ ((t) => (t.MISSING_MANIFEST = "MISSING_MANIFEST", t.MISSING_PLUGIN = "MISSING_PLUGIN", t.MISSING_ENTRYPOINT = "MISSING_ENTRYPOINT", t))(Nr || {});
2306
+ const ks = (t) => {
2221
2307
  const e = t.split("::");
2222
2308
  return e.length === 1 ? { group: "core", version: "", kind: e[0] } : {
2223
2309
  group: e[0] || "core",
2224
2310
  version: e[1] || "",
2225
2311
  kind: e[2] || e[0]
2226
2312
  };
2227
- }, Ds = (t) => !t || t === "core" ? "Core" : t.charAt(0).toUpperCase() + t.slice(1);
2313
+ }, Ms = (t) => !t || t === "core" ? "Core" : t.charAt(0).toUpperCase() + t.slice(1);
2228
2314
  export {
2229
2315
  H as ALL_SESSIONS_KEY,
2230
- pn as BottomDrawerContext,
2231
- hn as ConfirmationModalContext,
2316
+ gn as BottomDrawerContext,
2317
+ mn as ConfirmationModalContext,
2232
2318
  $ as ErrorTypes,
2233
- Br as ExtensionPointRegistry,
2234
- Cn as ExtensionPointStore,
2235
- Kr as ExtensionProvider,
2236
- vs as Link,
2319
+ Xr as ExtensionPointRegistry,
2320
+ vn as ExtensionPointStore,
2321
+ Zr as ExtensionProvider,
2322
+ As as Link,
2237
2323
  Qe as OperationsContext,
2238
- jr as OperationsProvider,
2324
+ Yr as OperationsProvider,
2239
2325
  ye as PluginContext,
2240
- qr as PluginContextProvider,
2241
- Dr as PluginErrorCode,
2242
- Is as PluginWindow,
2243
- Fs as PluginWindowRootProps,
2244
- yn as RightDrawerContext,
2326
+ Br as PluginContextProvider,
2327
+ Nr as PluginErrorCode,
2328
+ Ls as PluginWindow,
2329
+ Ns as PluginWindowRootProps,
2330
+ hn as RightDrawerContext,
2245
2331
  je as SettingsContext,
2246
- Gr as SettingsProvider,
2247
- Hr as SnackbarProvider,
2248
- I as WatchState,
2249
- dn as actionToSnackbar,
2250
- Fr as applyBatch,
2251
- bn as connectionListQueryKey,
2252
- k as createErrorHandler,
2253
- fn as defaultState,
2254
- Ds as formatGroup,
2332
+ zr as SettingsProvider,
2333
+ Vr as SnackbarProvider,
2334
+ F as WatchState,
2335
+ pn as actionToSnackbar,
2336
+ Ir as applyBatch,
2337
+ Fn as connectionListQueryKey,
2338
+ L as createErrorHandler,
2339
+ yn as defaultState,
2340
+ Ms as formatGroup,
2255
2341
  We as isCancelledError,
2256
2342
  Q as parseAppError,
2257
- Rs as parseResourceKey,
2343
+ ks as parseResourceKey,
2344
+ Ds as relationshipLabel,
2258
2345
  z as showAppError,
2259
- ws as useActiveSyncs,
2346
+ xr as toRelatedResources,
2347
+ Fs as useActiveSyncs,
2260
2348
  Ze as useBottomDrawer,
2261
- as as useConfirmationModal,
2262
- zr as useConnection,
2263
- Jr as useConnectionNamespaces,
2264
- Zr as useConnectionStatus,
2265
- Yr as useConnections,
2266
- Ss as useEditorSchemas,
2267
- Ir as useEventBatcher,
2268
- es as useExec,
2269
- ms as useExecuteAction,
2270
- Qr as useExtensionPoint,
2271
- En as useExtensionRegistry,
2272
- ts as useLogs,
2273
- ns as useMetricProviders,
2274
- In as useMetricProvidersForResource,
2275
- ss as useMetricStream,
2276
- Rr as useOperations,
2277
- he as usePluginContext,
2278
- Xr as usePluginData,
2279
- bs as usePluginRouter,
2280
- Wr as usePluginSettings,
2281
- os as usePortForwardSessions,
2282
- P as useResolvedPluginId,
2283
- cs as useResource,
2284
- gs as useResourceActions,
2285
- us as useResourceAreaComponent,
2286
- ls as useResourceGroups,
2287
- rs as useResourceMetrics,
2288
- hs as useResourceMutations,
2289
- is as useResourcePortForwarder,
2290
- ds as useResourceSearch,
2291
- fs as useResourceType,
2292
- ps as useResourceTypes,
2293
- ys as useResources,
2294
- Vr as useRightDrawer,
2295
- Cs as useSettings,
2349
+ ps as useConfirmationModal,
2350
+ es as useConnection,
2351
+ ns as useConnectionNamespaces,
2352
+ rs as useConnectionStatus,
2353
+ ts as useConnections,
2354
+ Os as useDependencyTree,
2355
+ vs as useEditorSchemas,
2356
+ Dr as useEventBatcher,
2357
+ is as useExec,
2358
+ bs as useExecuteAction,
2359
+ Jr as useExtensionPoint,
2360
+ bn as useExtensionRegistry,
2361
+ as as useLogs,
2362
+ cs as useMetricProviders,
2363
+ Dn as useMetricProvidersForResource,
2364
+ ls as useMetricStream,
2365
+ Pr as useOperations,
2366
+ ge as usePluginContext,
2367
+ ss as usePluginData,
2368
+ xs as usePluginRouter,
2369
+ Hr as usePluginSettings,
2370
+ ds as usePortForwardSessions,
2371
+ Ps as useRelatedResources,
2372
+ D as useResolvedPluginId,
2373
+ ys as useResource,
2374
+ Cs as useResourceActions,
2375
+ gs as useResourceAreaComponent,
2376
+ hs as useResourceGroups,
2377
+ us as useResourceMetrics,
2378
+ Es as useResourceMutations,
2379
+ fs as useResourcePortForwarder,
2380
+ ms as useResourceSearch,
2381
+ Ss as useResourceType,
2382
+ _s as useResourceTypes,
2383
+ ws as useResources,
2384
+ os as useRightDrawer,
2385
+ Ts as useSettings,
2296
2386
  U as useSnackbar,
2297
- Es as useStreamAction,
2298
- _s as useWatchState
2387
+ Is as useStreamAction,
2388
+ Rs as useWatchState
2299
2389
  };