react-semaphor 0.1.281 → 0.1.283

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.
Files changed (33) hide show
  1. package/dist/chunks/{dashboard-controls-D3R8Z79V.js → dashboard-controls-DN8jYCON.js} +102 -102
  2. package/dist/chunks/{dashboard-controls-CLd_NTpW.js → dashboard-controls-wfMo3T6T.js} +1 -1
  3. package/dist/chunks/{dashboard-filter-controls-button-DLjcoN1G.js → dashboard-filter-controls-button-DKc_6T_O.js} +2 -2
  4. package/dist/chunks/{dashboard-filter-controls-button-zj4HH2IS.js → dashboard-filter-controls-button-zeiatmo1.js} +125 -113
  5. package/dist/chunks/{dashboard-json-BcdeYcFr.js → dashboard-json-DK_hQ4vs.js} +1 -1
  6. package/dist/chunks/{dashboard-json-CPyonfsi.js → dashboard-json-DyJBSpIU.js} +1 -1
  7. package/dist/chunks/{dashboard-summary-settings-dialog-Cpb9FCXf.js → dashboard-summary-settings-dialog-BPyawgMV.js} +1 -1
  8. package/dist/chunks/{dashboard-summary-settings-dialog-BYQfaQGZ.js → dashboard-summary-settings-dialog-CWtlFDFP.js} +1 -1
  9. package/dist/chunks/{edit-dashboard-visual-NyBBQhsY.js → edit-dashboard-visual-0lBlwTCM.js} +1 -1
  10. package/dist/chunks/{edit-dashboard-visual-CsTmOttj.js → edit-dashboard-visual-4nQV1U_c.js} +319 -319
  11. package/dist/chunks/{index-CsX3UmQg.js → index-B7kUtCgG.js} +26420 -25515
  12. package/dist/chunks/{index-DvAOngur.js → index-BHWWNpG6.js} +223 -223
  13. package/dist/chunks/{resource-management-panel-lglhpWpc.js → resource-management-panel-D8xvqypt.js} +1 -1
  14. package/dist/chunks/{resource-management-panel-BxJ99bHx.js → resource-management-panel-Dpin6Ffw.js} +2 -2
  15. package/dist/chunks/use-create-flow-overlay-state-VwKDgVAy.js +1597 -0
  16. package/dist/chunks/use-create-flow-overlay-state-XkHgf9f3.js +21 -0
  17. package/dist/chunks/{use-visual-utils-C54WwvId.js → use-visual-utils-C8YSTPfX.js} +1 -1
  18. package/dist/chunks/{use-visual-utils-C7wVd3rs.js → use-visual-utils-CBocWNV1.js} +1 -1
  19. package/dist/dashboard/index.cjs +1 -1
  20. package/dist/dashboard/index.js +1 -1
  21. package/dist/index.cjs +1 -1
  22. package/dist/index.js +5 -5
  23. package/dist/style.css +1 -1
  24. package/dist/surfboard/index.cjs +1 -1
  25. package/dist/surfboard/index.js +2 -2
  26. package/dist/types/dashboard.d.ts +9 -1
  27. package/dist/types/main.d.ts +9 -1
  28. package/dist/types/shared.d.ts +9 -1
  29. package/dist/types/surfboard.d.ts +9 -1
  30. package/dist/types/types.d.ts +9 -1
  31. package/package.json +1 -1
  32. package/dist/chunks/use-create-flow-overlay-state-BjV5Q6Lb.js +0 -1443
  33. package/dist/chunks/use-create-flow-overlay-state-BrmQZdh2.js +0 -21
@@ -1,14 +1,14 @@
1
- import { jsxs as o, jsx as e, Fragment as k } from "react/jsx-runtime";
2
- import { bM as de, dn as qs, u as x, cA as ra, cB as na, B as A, cD as oa, cE as Q, dp as ia, N as qa, b as $, e as la, dq as Hs, cr as ca, f as da, g as ua, h as ma, i as Ha, L as Qe, I as ce, v as js, a7 as K, dr as we, cI as We, ds as zs, dt as Pa, du as ja, c as Y, dv as za, dw as Bs, cZ as ha, dx as Ks, dy as Qs, dz as Ws, dA as Js, dB as Xs, dC as Ys, H as Me, W as Ae, x as I, dD as Le, dE as Ba, dF as Ka, d6 as Zs, dG as et, w as Z, cH as J, dH as at, dI as st, dJ as Je, dK as tt, dL as rt, dM as Qa, dN as Wa, dO as Ce, dP as Ee, d2 as Xe, cN as Ye, dQ as Ze, ce as Ja, dR as ea, c9 as Xa, dS as nt, cQ as Ya, cR as Za, cS as es, cT as as, cU as ss, cV as ts, cW as rs, cX as aa, dT as ns, cz as ot, dU as it, ag as lt, U as Ua, af as De, dV as ct, am as dt, ah as je, dW as ut, dX as mt, dY as ht, aB as pt, dZ as ft, d_ as gt, bT as vt, bU as bt, bV as yt, d$ as Nt, bW as St, cF as xt, at as Dt, e0 as wt, e1 as Ct, dm as Et, e2 as Mt, e3 as At, cC as Lt, a9 as It, cK as kt, e4 as Ot, al as Tt, aa as _t, as as Pt, e5 as Ut } from "./index-CsX3UmQg.js";
1
+ import { jsxs as o, jsx as e, Fragment as I } from "react/jsx-runtime";
2
+ import { bM as de, dq as qs, u as x, cC as ra, cD as na, B as A, cF as oa, cG as Q, dr as ia, N as qa, b as $, e as la, ds as Hs, ct as ca, f as da, g as ua, h as ma, i as Ha, L as Qe, I as ce, v as js, a7 as K, dt as we, cK as We, du as Bs, dv as Pa, dw as ja, c as Y, dx as Ba, dy as zs, c$ as ha, dz as Ks, dA as Qs, dB as Ws, dC as Js, dD as Xs, dE as Ys, H as Me, W as Ae, x as k, dF as Le, dG as za, dH as Ka, d8 as Zs, dI as et, w as Z, cJ as J, dJ as at, dK as st, dL as Je, dM as tt, dN as rt, dO as Qa, dP as Wa, dQ as Ce, dR as Ee, d4 as Xe, cP as Ye, dS as Ze, ch as Ja, dT as ea, cc as Xa, dU as nt, cS as Ya, cT as Za, cU as es, cV as as, cW as ss, cX as ts, cY as rs, cZ as aa, dV as ns, cB as ot, dW as it, ag as lt, U as Ua, af as De, dX as ct, am as dt, ah as je, dY as ut, dZ as mt, d_ as ht, aB as pt, d$ as ft, e0 as gt, bT as vt, bU as bt, bV as yt, e1 as Nt, bW as St, cH as xt, at as Dt, e2 as wt, e3 as Ct, dp as Et, e4 as Mt, e5 as At, cE as Lt, a9 as kt, cM as It, e6 as Ot, al as Tt, aa as _t, as as Pt, e7 as Ut } from "./index-B7kUtCgG.js";
3
3
  import * as M from "react";
4
- import os, { useState as N, useMemo as W, useCallback as Ra, useEffect as Rt } from "react";
4
+ import os, { useState as N, useMemo as W, useCallback as Ga, useEffect as Gt } from "react";
5
5
  import "react-dom";
6
- import { b as Gt, u as Ft, d as $t, A as Vt, V as qt, N as Ht, c as jt, D as zt, U as Bt } from "./dashboard-filter-controls-button-zj4HH2IS.js";
6
+ import { b as Rt, u as Ft, d as $t, A as Vt, V as qt, N as Ht, c as jt, D as Bt, U as zt } from "./dashboard-filter-controls-button-zeiatmo1.js";
7
7
  import { l as Kt } from "./date-formatter-vkCj9Ct-.js";
8
- import { C as Qt, D as Wt } from "./dashboard-summary-settings-dialog-BYQfaQGZ.js";
8
+ import { C as Qt, D as Wt } from "./dashboard-summary-settings-dialog-CWtlFDFP.js";
9
9
  import { u as Jt } from "./use-debounced-dirty-check-BwAbnX_5.js";
10
- import { s as ze } from "./normalize-dashboard-for-dirty-check-5KpZN8xr.js";
11
- import { S as Ga } from "./use-create-flow-overlay-state-BjV5Q6Lb.js";
10
+ import { s as Be } from "./normalize-dashboard-for-dirty-check-5KpZN8xr.js";
11
+ import { S as Ra } from "./use-create-flow-overlay-state-VwKDgVAy.js";
12
12
  /**
13
13
  * @license lucide-react v0.453.0 - ISC
14
14
  *
@@ -76,7 +76,7 @@ const ar = de("Sun", [
76
76
  ["path", { d: "m6.34 17.66-1.41 1.41", key: "1m8zz5" }],
77
77
  ["path", { d: "m19.07 4.93-1.41 1.41", key: "1shlcs" }]
78
78
  ]);
79
- var sa = { exports: {} }, Be = {};
79
+ var sa = { exports: {} }, ze = {};
80
80
  /**
81
81
  * @license React
82
82
  * use-sync-external-store-shim.production.js
@@ -88,7 +88,7 @@ var sa = { exports: {} }, Be = {};
88
88
  */
89
89
  var Fa;
90
90
  function sr() {
91
- if (Fa) return Be;
91
+ if (Fa) return ze;
92
92
  Fa = 1;
93
93
  var a = os;
94
94
  function n(r, d) {
@@ -125,7 +125,7 @@ function sr() {
125
125
  return d();
126
126
  }
127
127
  var h = typeof window > "u" || typeof window.document > "u" || typeof window.document.createElement > "u" ? y : u;
128
- return Be.useSyncExternalStore = a.useSyncExternalStore !== void 0 ? a.useSyncExternalStore : h, Be;
128
+ return ze.useSyncExternalStore = a.useSyncExternalStore !== void 0 ? a.useSyncExternalStore : h, ze;
129
129
  }
130
130
  var Ke = {};
131
131
  /**
@@ -378,7 +378,7 @@ function cr() {
378
378
  /* @__PURE__ */ e(we, { className: "px-3", children: "Lenses" }),
379
379
  /* @__PURE__ */ e(We, {}),
380
380
  /* @__PURE__ */ o(
381
- zs,
381
+ Bs,
382
382
  {
383
383
  value: t,
384
384
  onValueChange: p,
@@ -409,7 +409,7 @@ function cr() {
409
409
  }
410
410
  ),
411
411
  /* @__PURE__ */ e(
412
- za,
412
+ Ba,
413
413
  {
414
414
  onClick: (d) => {
415
415
  d.preventDefault(), y(r.id);
@@ -430,7 +430,7 @@ function cr() {
430
430
  ] });
431
431
  }
432
432
  function dr() {
433
- const { displayPreferences: a, shouldShowElement: n } = Bs(), { currentUser: s, userContext: t } = ha(), l = W(
433
+ const { displayPreferences: a, shouldShowElement: n } = zs(), { currentUser: s, userContext: t } = ha(), l = W(
434
434
  () => Ks(s),
435
435
  [s]
436
436
  ), c = W(() => (u) => l && l[u] !== void 0 && l[u] === !1 ? !1 : n(u), [l, n, a]), m = W(
@@ -458,23 +458,23 @@ const ur = async (a, n, s) => {
458
458
  return await Ka(t, n, s);
459
459
  }, mr = async (a, n, s) => {
460
460
  const t = `${a}/management/v1/groups/${s}`;
461
- await Ba(t, n, "DELETE");
461
+ await za(t, n, "DELETE");
462
462
  }, hr = async (a, n, s, t) => {
463
463
  const l = `${a}/management/v1/groups/${s}/members`;
464
464
  return await Ka(l, n, t);
465
465
  }, pr = async (a, n, s, t) => {
466
466
  const l = `${a}/management/v1/groups/${s}/members`;
467
- await Ba(l, n, "DELETE", t);
467
+ await za(l, n, "DELETE", t);
468
468
  };
469
469
  function fr() {
470
470
  const { authToken: a, tokenProps: n } = $(), s = Me();
471
471
  return Ae({
472
472
  mutationFn: (t) => ur(n.apiServiceUrl, (a == null ? void 0 : a.accessToken) || "", t),
473
473
  onSuccess: () => {
474
- s.invalidateQueries({ queryKey: ["groups"] }), I.success("Group created successfully");
474
+ s.invalidateQueries({ queryKey: ["groups"] }), k.success("Group created successfully");
475
475
  },
476
476
  onError: (t) => {
477
- console.error("Failed to create group:", t), I.error("Failed to create group", {
477
+ console.error("Failed to create group:", t), k.error("Failed to create group", {
478
478
  description: Le(t, "Failed to create group")
479
479
  });
480
480
  }
@@ -485,10 +485,10 @@ function gr() {
485
485
  return Ae({
486
486
  mutationFn: (t) => mr(n.apiServiceUrl, (a == null ? void 0 : a.accessToken) || "", t),
487
487
  onSuccess: (t, l) => {
488
- s.invalidateQueries({ queryKey: ["groups"] }), s.removeQueries({ queryKey: ["group", l] }), I.success("Group deleted successfully");
488
+ s.invalidateQueries({ queryKey: ["groups"] }), s.removeQueries({ queryKey: ["group", l] }), k.success("Group deleted successfully");
489
489
  },
490
490
  onError: (t) => {
491
- console.error("Failed to delete group:", t), I.error("Failed to delete group", {
491
+ console.error("Failed to delete group:", t), k.error("Failed to delete group", {
492
492
  description: Le(t, "Failed to delete group")
493
493
  });
494
494
  }
@@ -504,10 +504,10 @@ function vr() {
504
504
  onSuccess: (t, l) => {
505
505
  s.invalidateQueries({ queryKey: ["group", l.groupId] }), s.invalidateQueries({
506
506
  queryKey: ["group-members", l.groupId]
507
- }), s.invalidateQueries({ queryKey: ["groups"] }), I.success("Members added successfully");
507
+ }), s.invalidateQueries({ queryKey: ["groups"] }), k.success("Members added successfully");
508
508
  },
509
509
  onError: (t) => {
510
- console.error("Failed to add group members:", t), I.error("Failed to add members", {
510
+ console.error("Failed to add group members:", t), k.error("Failed to add members", {
511
511
  description: Le(t, "Failed to add members")
512
512
  });
513
513
  }
@@ -523,10 +523,10 @@ function br() {
523
523
  onSuccess: (t, l) => {
524
524
  s.invalidateQueries({ queryKey: ["group", l.groupId] }), s.invalidateQueries({
525
525
  queryKey: ["group-members", l.groupId]
526
- }), s.invalidateQueries({ queryKey: ["groups"] }), I.success("Members removed successfully");
526
+ }), s.invalidateQueries({ queryKey: ["groups"] }), k.success("Members removed successfully");
527
527
  },
528
528
  onError: (t) => {
529
- console.error("Failed to remove group members:", t), I.error("Failed to remove members", {
529
+ console.error("Failed to remove group members:", t), k.error("Failed to remove members", {
530
530
  description: Le(t, "Failed to remove members")
531
531
  });
532
532
  }
@@ -624,10 +624,10 @@ function yr({
624
624
  {
625
625
  type: "submit",
626
626
  disabled: y.isPending || !t.trim(),
627
- children: y.isPending ? /* @__PURE__ */ o(k, { children: [
627
+ children: y.isPending ? /* @__PURE__ */ o(I, { children: [
628
628
  /* @__PURE__ */ e(Z, { className: "mr-2 h-4 w-4 animate-spin" }),
629
629
  "Creating..."
630
- ] }) : /* @__PURE__ */ o(k, { children: [
630
+ ] }) : /* @__PURE__ */ o(I, { children: [
631
631
  /* @__PURE__ */ e(J, { className: "mr-2 h-4 w-4" }),
632
632
  "Create Group"
633
633
  ] })
@@ -842,8 +842,8 @@ function Lr({
842
842
  const g = m.toLowerCase();
843
843
  return _.filter(
844
844
  (E) => {
845
- var O, F, z, ae;
846
- return ((F = (O = E.user) == null ? void 0 : O.name) == null ? void 0 : F.toLowerCase().includes(g)) || ((ae = (z = E.user) == null ? void 0 : z.email) == null ? void 0 : ae.toLowerCase().includes(g));
845
+ var O, F, B, ae;
846
+ return ((F = (O = E.user) == null ? void 0 : O.name) == null ? void 0 : F.toLowerCase().includes(g)) || ((ae = (B = E.user) == null ? void 0 : B.email) == null ? void 0 : ae.toLowerCase().includes(g));
847
847
  }
848
848
  );
849
849
  }, [_, m]), j = async () => {
@@ -875,12 +875,12 @@ function Lr({
875
875
  y(
876
876
  (E) => E.includes(g) ? E.filter((O) => O !== g) : [...E, g]
877
877
  );
878
- }, Ie = (g) => {
878
+ }, ke = (g) => {
879
879
  r(
880
880
  (E) => E.includes(g) ? E.filter((O) => O !== g) : [...E, g]
881
881
  );
882
882
  };
883
- return /* @__PURE__ */ e(k, { children: /* @__PURE__ */ e(la, { open: a, onOpenChange: n, children: /* @__PURE__ */ o(da, { className: "max-w-3xl max-h-[80vh]", "aria-describedby": "group-members-description", children: [
883
+ return /* @__PURE__ */ e(I, { children: /* @__PURE__ */ e(la, { open: a, onOpenChange: n, children: /* @__PURE__ */ o(da, { className: "max-w-3xl max-h-[80vh]", "aria-describedby": "group-members-description", children: [
884
884
  /* @__PURE__ */ o(ua, { children: [
885
885
  /* @__PURE__ */ e(ma, { children: s.name }),
886
886
  /* @__PURE__ */ e("div", { className: "flex items-center gap-2 mt-1", children: /* @__PURE__ */ o("p", { className: "text-sm text-muted-foreground", children: [
@@ -919,11 +919,11 @@ function Lr({
919
919
  /* @__PURE__ */ e("p", { className: "text-sm font-medium", children: m ? "No members found" : "No members yet" }),
920
920
  /* @__PURE__ */ e("p", { className: "text-xs mt-1", children: m ? "Try a different search" : 'Switch to the "Add Members" tab to add people to this group' })
921
921
  ] }) : /* @__PURE__ */ e("div", { className: "space-y-2", children: D.map((g) => /* @__PURE__ */ e(
922
- Ir,
922
+ kr,
923
923
  {
924
924
  member: g,
925
925
  selected: h.includes(g.userId),
926
- onToggle: () => Ie(g.userId)
926
+ onToggle: () => ke(g.userId)
927
927
  },
928
928
  g.id
929
929
  )) }) }),
@@ -941,10 +941,10 @@ function Lr({
941
941
  size: "sm",
942
942
  onClick: ue,
943
943
  disabled: U.isPending,
944
- children: U.isPending ? /* @__PURE__ */ o(k, { children: [
944
+ children: U.isPending ? /* @__PURE__ */ o(I, { children: [
945
945
  /* @__PURE__ */ e(Z, { className: "mr-2 h-4 w-4 animate-spin" }),
946
946
  "Removing..."
947
- ] }) : /* @__PURE__ */ o(k, { children: [
947
+ ] }) : /* @__PURE__ */ o(I, { children: [
948
948
  /* @__PURE__ */ e(Ja, { className: "mr-2 h-4 w-4" }),
949
949
  "Remove Selected"
950
950
  ] })
@@ -970,7 +970,7 @@ function Lr({
970
970
  /* @__PURE__ */ e("p", { className: "text-sm font-medium", children: "No available users" }),
971
971
  /* @__PURE__ */ e("p", { className: "text-xs mt-1", children: m ? "Try a different search" : "All eligible users are already members" })
972
972
  ] }) : /* @__PURE__ */ e("div", { className: "space-y-2", children: H.map((g) => /* @__PURE__ */ e(
973
- kr,
973
+ Ir,
974
974
  {
975
975
  user: g,
976
976
  selected: p.includes(g.id),
@@ -990,10 +990,10 @@ function Lr({
990
990
  {
991
991
  onClick: j,
992
992
  disabled: P.isPending,
993
- children: P.isPending ? /* @__PURE__ */ o(k, { children: [
993
+ children: P.isPending ? /* @__PURE__ */ o(I, { children: [
994
994
  /* @__PURE__ */ e(Z, { className: "mr-2 h-4 w-4 animate-spin" }),
995
995
  "Adding..."
996
- ] }) : /* @__PURE__ */ o(k, { children: [
996
+ ] }) : /* @__PURE__ */ o(I, { children: [
997
997
  /* @__PURE__ */ e(ea, { className: "mr-2 h-4 w-4" }),
998
998
  "Add Members"
999
999
  ] })
@@ -1004,7 +1004,7 @@ function Lr({
1004
1004
  ] })
1005
1005
  ] }) }) });
1006
1006
  }
1007
- function Ir({
1007
+ function kr({
1008
1008
  member: a,
1009
1009
  selected: n,
1010
1010
  onToggle: s
@@ -1027,7 +1027,7 @@ function Ir({
1027
1027
  }
1028
1028
  );
1029
1029
  }
1030
- function kr({
1030
+ function Ir({
1031
1031
  user: a,
1032
1032
  selected: n,
1033
1033
  onToggle: s
@@ -1075,7 +1075,7 @@ function Or({
1075
1075
  }, H = () => {
1076
1076
  t("groups"), U();
1077
1077
  };
1078
- return /* @__PURE__ */ o(k, { children: [
1078
+ return /* @__PURE__ */ o(I, { children: [
1079
1079
  /* @__PURE__ */ e(la, { open: a, onOpenChange: n, children: /* @__PURE__ */ o(da, { className: "max-w-4xl max-h-[80vh]", children: [
1080
1080
  /* @__PURE__ */ o(ua, { children: [
1081
1081
  /* @__PURE__ */ o(ma, { className: "flex items-center gap-2", children: [
@@ -1164,7 +1164,7 @@ function Or({
1164
1164
  onClick: V,
1165
1165
  disabled: v.isPending,
1166
1166
  className: "bg-destructive text-destructive-foreground hover:bg-destructive/90",
1167
- children: v.isPending ? /* @__PURE__ */ o(k, { children: [
1167
+ children: v.isPending ? /* @__PURE__ */ o(I, { children: [
1168
1168
  /* @__PURE__ */ e(Z, { className: "mr-2 h-4 w-4 animate-spin" }),
1169
1169
  "Deleting..."
1170
1170
  ] }) : "Delete Group"
@@ -1328,9 +1328,9 @@ function _r(a) {
1328
1328
  }
1329
1329
  return Array.from(t.values());
1330
1330
  }
1331
- function zr() {
1332
- var Ia, ka, Oa, Ta;
1333
- Gt(), Ft();
1331
+ function Br() {
1332
+ var ka, Ia, Oa, Ta;
1333
+ Rt(), Ft();
1334
1334
  const {
1335
1335
  authToken: a,
1336
1336
  tokenProps: n,
@@ -1343,7 +1343,7 @@ function zr() {
1343
1343
  x((i) => i.selectedSheetId);
1344
1344
  const d = x(
1345
1345
  (i) => i.isDashboardEditing
1346
- ), { setDashboardTitle: f } = x((i) => i.actions), [v, b] = N(!1), [S, C] = N(!1), [P, U] = N(!1), [_, V] = N(!1), [q, H] = N(!1), [D, j] = N(!1), [ue, ee] = N(null), [Ie, g] = N(!1), [E, O] = N(null), [F, z] = N([]), [ae, me] = N(!1), gs = x((i) => i.isDashboardPanelOpen), vs = x(
1346
+ ), { setDashboardTitle: f } = x((i) => i.actions), [v, b] = N(!1), [S, C] = N(!1), [P, U] = N(!1), [_, V] = N(!1), [q, H] = N(!1), [D, j] = N(!1), [ue, ee] = N(null), [ke, g] = N(!1), [E, O] = N(null), [F, B] = N([]), [ae, me] = N(!1), gs = x((i) => i.isDashboardPanelOpen), vs = x(
1347
1347
  (i) => i.actions.setIsDashboardPanelOpen
1348
1348
  ), bs = x((i) => i.filterValues), w = x((i) => i.isVisualEditing);
1349
1349
  Ua((i) => i.card);
@@ -1353,9 +1353,9 @@ function zr() {
1353
1353
  (i) => i.initialDashboard
1354
1354
  );
1355
1355
  De((i) => i.selectedVisual), x((i) => i.selectedFrameId), Ua((i) => i.frame);
1356
- const pe = se ? (ka = se == null ? void 0 : se.permissions) == null ? void 0 : ka.canEdit : (Ia = he == null ? void 0 : he.permissions) == null ? void 0 : Ia.canEdit, fe = x((i) => i.showFilters), ba = ct((i) => i.setPanelOpen), ys = x(
1356
+ const pe = se ? (Ia = se == null ? void 0 : se.permissions) == null ? void 0 : Ia.canEdit : (ka = he == null ? void 0 : he.permissions) == null ? void 0 : ka.canEdit, fe = x((i) => i.showFilters), ba = ct((i) => i.setPanelOpen), ys = x(
1357
1357
  (i) => i.showDashboardJSON
1358
- ), ke = x((i) => i.onSaveFunction), ya = x(
1358
+ ), Ie = x((i) => i.onSaveFunction), ya = x(
1359
1359
  (i) => i.actions.setShowFilters
1360
1360
  ), { setIsDashboardEditing: Na, setShowDashboardJSON: Sa } = x(
1361
1361
  (i) => i.actions
@@ -1364,9 +1364,9 @@ function zr() {
1364
1364
  ), { resources: ge } = dt(je.DASHBOARD), { data: Te } = ut(), Ns = ((Oa = Te == null ? void 0 : Te.preference) == null ? void 0 : Oa.defaultDashboardId) || null, { mutate: Ss, isPending: xs } = mt(), { currentUser: Ds } = ha(), ws = ht(Ds), X = se || he, Da = X ? {
1365
1365
  id: X.id,
1366
1366
  title: (r == null ? void 0 : r.title) || X.title || "Dashboard"
1367
- } : null, { handleAddNewFrame: Cs } = pt(), [_e, Pe] = N(!1), [Es, te] = N(!1), [Ue, ve] = N("close"), re = ft(je.DASHBOARD), [R, Re] = N(
1367
+ } : null, { handleAddNewFrame: Cs } = pt(), [_e, Pe] = N(!1), [Es, te] = N(!1), [Ue, ve] = N("close"), re = ft(je.DASHBOARD), [G, Ge] = N(
1368
1368
  null
1369
- ), wa = Ra(
1369
+ ), wa = Ga(
1370
1370
  (i) => {
1371
1371
  window.setTimeout(() => {
1372
1372
  ee(i);
@@ -1389,53 +1389,53 @@ function zr() {
1389
1389
  },
1390
1390
  {
1391
1391
  onSuccess: () => {
1392
- console.log("Dashboard title updated successfully"), I.success("Dashboard title updated");
1392
+ console.log("Dashboard title updated successfully"), k.success("Dashboard title updated");
1393
1393
  },
1394
- onError: (G) => {
1395
- console.error("Failed to update dashboard title:", G), I.error("Failed to update dashboard title"), f(L);
1394
+ onError: (R) => {
1395
+ console.error("Failed to update dashboard title:", R), k.error("Failed to update dashboard title"), f(L);
1396
1396
  }
1397
1397
  }
1398
1398
  );
1399
1399
  };
1400
- Rt(() => {
1400
+ Gt(() => {
1401
1401
  if (ge && ge.length > 0) {
1402
1402
  const i = r == null ? void 0 : r.id;
1403
1403
  if (i) {
1404
1404
  const L = ge.find(
1405
- (G) => G.id === i
1405
+ (R) => R.id === i
1406
1406
  );
1407
1407
  L && xa(L);
1408
1408
  }
1409
1409
  }
1410
1410
  }, [ge, r == null ? void 0 : r.id, xa]);
1411
- const be = n.orgUserId || n.tenantId, Ca = d && !w && be && pe, { setDashboard: Ge } = x((i) => i.actions), As = () => {
1411
+ const be = n.orgUserId || n.tenantId, Ca = d && !w && be && pe, { setDashboard: Re } = x((i) => i.actions), As = () => {
1412
1412
  Na(!0);
1413
1413
  }, Fe = () => {
1414
- Na(!1), Sa(!1), Re(null), ee(null);
1414
+ Na(!1), Sa(!1), Ge(null), ee(null);
1415
1415
  };
1416
1416
  $t(
1417
1417
  d,
1418
1418
  r,
1419
- R,
1420
- (i) => Re(i)
1419
+ G,
1420
+ (i) => Ge(i)
1421
1421
  );
1422
1422
  const { isDirty: Ea, isDirtyPending: Ls, resetDirty: ye } = Jt(
1423
1423
  r,
1424
- R,
1424
+ G,
1425
1425
  300,
1426
1426
  1e3,
1427
- ze
1428
- ), Ma = Ra(() => R ? ze(r) !== ze(R) : !1, [r, R]), $e = Ea || Ls, ne = _e || re.isPending, Is = () => {
1427
+ Be
1428
+ ), Ma = Ga(() => G ? Be(r) !== Be(G) : !1, [r, G]), $e = Ea || Ls, ne = _e || re.isPending, ks = () => {
1429
1429
  Ma() ? (ve("close"), te(!0)) : (Fe(), ye());
1430
- }, ks = async () => {
1430
+ }, Is = async () => {
1431
1431
  await Ve({
1432
1432
  closeAfterSave: !0,
1433
1433
  navigateHomeAfterSave: Ue === "home"
1434
1434
  });
1435
1435
  }, Os = () => {
1436
- R && Ge(R), Fe(), Ue === "home" && Oe(), ve("close"), te(!1), ye();
1436
+ G && Re(G), Fe(), Ue === "home" && Oe(), ve("close"), te(!1), ye();
1437
1437
  }, Ts = () => {
1438
- R && (Ge(R), ye());
1438
+ G && (Re(G), ye());
1439
1439
  }, _s = () => {
1440
1440
  if (d && Ma()) {
1441
1441
  ve("home"), te(!0);
@@ -1447,10 +1447,10 @@ function zr() {
1447
1447
  const L = x.getState().dashboard;
1448
1448
  if (!L)
1449
1449
  return;
1450
- const G = (i == null ? void 0 : i.closeAfterSave) ?? ae, Fs = (i == null ? void 0 : i.navigateHomeAfterSave) ?? !1;
1451
- me(G), G && te(!1);
1450
+ const R = (i == null ? void 0 : i.closeAfterSave) ?? ae, Fs = (i == null ? void 0 : i.navigateHomeAfterSave) ?? !1;
1451
+ me(R), R && te(!1);
1452
1452
  const $s = Pt(L);
1453
- g(!0), O(null), z([]), Pe(!0);
1453
+ g(!0), O(null), B([]), Pe(!0);
1454
1454
  const Vs = {
1455
1455
  template: L
1456
1456
  };
@@ -1462,28 +1462,28 @@ function zr() {
1462
1462
  {
1463
1463
  onSuccess: (T) => {
1464
1464
  var Ne, Se, _a;
1465
- const B = (T == null ? void 0 : T.id) || ((Ne = T == null ? void 0 : T.dashboard) == null ? void 0 : Ne.id) || ((Se = T == null ? void 0 : T.resource) == null ? void 0 : Se.id) || ((_a = T == null ? void 0 : T.template) == null ? void 0 : _a.id) || null;
1466
- if (!L.id && B) {
1465
+ const z = (T == null ? void 0 : T.id) || ((Ne = T == null ? void 0 : T.dashboard) == null ? void 0 : Ne.id) || ((Se = T == null ? void 0 : T.resource) == null ? void 0 : Se.id) || ((_a = T == null ? void 0 : T.template) == null ? void 0 : _a.id) || null;
1466
+ if (!L.id && z) {
1467
1467
  const He = Ut.getState(), xe = He.pendingDashboardDraftMigration;
1468
1468
  (xe == null ? void 0 : xe.scopeKey) === u ? He.actions.setPendingDashboardDraftMigrationExpectedDashboardId(
1469
- B
1469
+ z
1470
1470
  ) : xe && He.actions.clearPendingDashboardDraftMigration();
1471
1471
  }
1472
- Pe(!1), I.success("Dashboard saved!"), Re($s), g(!1), me(!1), G && (Fe(), ye(), Fs && Oe()), ve("close");
1472
+ Pe(!1), k.success("Dashboard saved!"), Ge($s), g(!1), me(!1), R && (Fe(), ye(), Fs && Oe()), ve("close");
1473
1473
  },
1474
1474
  onError: (T) => {
1475
1475
  Pe(!1), O("Failed to save dashboard. Please try again.");
1476
- const B = T.details, Ne = Array.isArray(
1477
- B == null ? void 0 : B.errors
1478
- ) ? (B.errors || []).filter(
1476
+ const z = T.details, Ne = Array.isArray(
1477
+ z == null ? void 0 : z.errors
1478
+ ) ? (z.errors || []).filter(
1479
1479
  (Se) => typeof Se == "string"
1480
1480
  ) : [];
1481
- z(
1481
+ B(
1482
1482
  _r({
1483
1483
  errors: Ne,
1484
1484
  dashboard: L || void 0
1485
1485
  })
1486
- ), I.error("Failed to save dashboard");
1486
+ ), k.error("Failed to save dashboard");
1487
1487
  }
1488
1488
  }
1489
1489
  );
@@ -1495,16 +1495,16 @@ function zr() {
1495
1495
  b(!1);
1496
1496
  return;
1497
1497
  }
1498
- const L = JSON.stringify(i), G = {
1498
+ const L = JSON.stringify(i), R = {
1499
1499
  ...h,
1500
1500
  template: L,
1501
1501
  filterValues: bs
1502
1502
  };
1503
1503
  await ta(
1504
1504
  n.apiServiceUrl,
1505
- G,
1505
+ R,
1506
1506
  a == null ? void 0 : a.accessToken
1507
- ), I.success("Lens saved"), ke == null || ke(i), b(!1);
1507
+ ), k.success("Lens saved"), Ie == null || Ie(i), b(!1);
1508
1508
  }
1509
1509
  const Aa = (h == null ? void 0 : h.name) || r.title;
1510
1510
  re.isPending && console.log("Title during update:", {
@@ -1513,7 +1513,7 @@ function zr() {
1513
1513
  dashboardId: r == null ? void 0 : r.id,
1514
1514
  currentLensName: h == null ? void 0 : h.name
1515
1515
  });
1516
- const La = n.orgUserId || n.tenantId && n.endUserId && n.endUserEmail, Us = !!La && !!(a != null && a.accessToken) && !!(n != null && n.apiServiceUrl), Rs = c, oe = (r == null ? void 0 : r.id) || null, qe = !!oe && Ns === oe, Gs = () => {
1516
+ const La = n.orgUserId || n.tenantId && n.endUserId && n.endUserEmail, Us = !!La && !!(a != null && a.accessToken) && !!(n != null && n.apiServiceUrl), Gs = c, oe = (r == null ? void 0 : r.id) || null, qe = !!oe && Ns === oe, Rs = () => {
1517
1517
  oe && Ss({
1518
1518
  dashboardId: qe ? null : oe
1519
1519
  });
@@ -1525,7 +1525,7 @@ function zr() {
1525
1525
  role: "dashboard-controls",
1526
1526
  children: [
1527
1527
  /* @__PURE__ */ o("div", { className: "flex items-center gap-2", children: [
1528
- La && /* @__PURE__ */ o(k, { children: [
1528
+ La && /* @__PURE__ */ o(I, { children: [
1529
1529
  /* @__PURE__ */ e(
1530
1530
  K,
1531
1531
  {
@@ -1538,7 +1538,7 @@ function zr() {
1538
1538
  children: /* @__PURE__ */ e(Yt, { className: "h-4 w-4" })
1539
1539
  }
1540
1540
  ),
1541
- Rs && !w && /* @__PURE__ */ e(
1541
+ Gs && !w && /* @__PURE__ */ e(
1542
1542
  K,
1543
1543
  {
1544
1544
  "aria-label": "Dashboard Hub",
@@ -1557,7 +1557,7 @@ function zr() {
1557
1557
  role: "status",
1558
1558
  children: /* @__PURE__ */ e("span", { className: "sr-only", children: "Loading dashboard title" })
1559
1559
  }
1560
- ) : /* @__PURE__ */ o(k, { children: [
1560
+ ) : /* @__PURE__ */ o(I, { children: [
1561
1561
  /* @__PURE__ */ e(
1562
1562
  gt,
1563
1563
  {
@@ -1584,7 +1584,7 @@ function zr() {
1584
1584
  {
1585
1585
  variant: "ghost",
1586
1586
  size: "icon",
1587
- onClick: Gs,
1587
+ onClick: Rs,
1588
1588
  disabled: xs || !(a != null && a.accessToken) || !(n != null && n.apiServiceUrl),
1589
1589
  className: "h-7 w-7",
1590
1590
  children: /* @__PURE__ */ e(
@@ -1603,18 +1603,18 @@ function zr() {
1603
1603
  ] }))
1604
1604
  ] }),
1605
1605
  /* @__PURE__ */ o("div", { className: "flex items-center gap-2", children: [
1606
- w && /* @__PURE__ */ o(k, { children: [
1606
+ w && /* @__PURE__ */ o(I, { children: [
1607
1607
  /* @__PURE__ */ e(Vt, { className: "mr-2" }),
1608
1608
  /* @__PURE__ */ e(qt, { className: "h-7" })
1609
1609
  ] }),
1610
- t && !w && /* @__PURE__ */ o(k, { children: [
1610
+ t && !w && /* @__PURE__ */ o(I, { children: [
1611
1611
  /* @__PURE__ */ e(
1612
1612
  K,
1613
1613
  {
1614
1614
  tooltip: "Copy Token",
1615
1615
  onClick: () => {
1616
1616
  var i;
1617
- a != null && a.accessToken && ((i = navigator == null ? void 0 : navigator.clipboard) != null && i.writeText ? navigator.clipboard.writeText(a.accessToken).then(() => I.success("Token copied to clipboard")).catch(() => I.error("Unable to copy token")) : I.error("Clipboard not available"));
1617
+ a != null && a.accessToken && ((i = navigator == null ? void 0 : navigator.clipboard) != null && i.writeText ? navigator.clipboard.writeText(a.accessToken).then(() => k.success("Token copied to clipboard")).catch(() => k.error("Unable to copy token")) : k.error("Clipboard not available"));
1618
1618
  },
1619
1619
  className: "h-7 p-2",
1620
1620
  children: /* @__PURE__ */ e(xt, { className: "h-4 w-4" })
@@ -1658,7 +1658,7 @@ function zr() {
1658
1658
  }
1659
1659
  ),
1660
1660
  d && !w && c && ue ? /* @__PURE__ */ e(
1661
- zt,
1661
+ Bt,
1662
1662
  {
1663
1663
  open: !0,
1664
1664
  onOpenChange: (i) => {
@@ -1679,7 +1679,7 @@ function zr() {
1679
1679
  onClick: Ps,
1680
1680
  size: "sm",
1681
1681
  children: [
1682
- /* @__PURE__ */ e(Ga, { className: "mr-2 h-4 w-4" }),
1682
+ /* @__PURE__ */ e(Ra, { className: "mr-2 h-4 w-4" }),
1683
1683
  "Save Lens"
1684
1684
  ]
1685
1685
  }
@@ -1734,7 +1734,7 @@ function zr() {
1734
1734
  onClick: () => Ve(),
1735
1735
  size: "sm",
1736
1736
  children: [
1737
- ne ? /* @__PURE__ */ e(Z, { className: "mr-2 h-4 w-4 animate-spin" }) : /* @__PURE__ */ e(Ga, { className: "mr-2 h-4 w-4" }),
1737
+ ne ? /* @__PURE__ */ e(Z, { className: "mr-2 h-4 w-4 animate-spin" }) : /* @__PURE__ */ e(Ra, { className: "mr-2 h-4 w-4" }),
1738
1738
  ne ? "Saving..." : "Save"
1739
1739
  ]
1740
1740
  }
@@ -1763,9 +1763,9 @@ function zr() {
1763
1763
  {
1764
1764
  variant: "outline",
1765
1765
  className: "h-7 p-2",
1766
- onClick: Is,
1766
+ onClick: ks,
1767
1767
  children: [
1768
- /* @__PURE__ */ e(za, { className: "mr-2 h-4 w-4" }),
1768
+ /* @__PURE__ */ e(Ba, { className: "mr-2 h-4 w-4" }),
1769
1769
  "Close"
1770
1770
  ]
1771
1771
  }
@@ -1793,13 +1793,13 @@ function zr() {
1793
1793
  onClick: () => V(!0),
1794
1794
  className: "flex items-center gap-2",
1795
1795
  children: [
1796
- /* @__PURE__ */ e(It, { className: "mr-2 h-4 w-4" }),
1796
+ /* @__PURE__ */ e(kt, { className: "mr-2 h-4 w-4" }),
1797
1797
  "Schedule Dashboard"
1798
1798
  ]
1799
1799
  }
1800
1800
  ),
1801
1801
  /* @__PURE__ */ e(We, {}),
1802
- ws && /* @__PURE__ */ o(k, { children: [
1802
+ ws && /* @__PURE__ */ o(I, { children: [
1803
1803
  /* @__PURE__ */ e(we, { className: "px-2.5 text-xs font-medium text-muted-foreground", children: "Access" }),
1804
1804
  /* @__PURE__ */ o(
1805
1805
  Q,
@@ -1821,7 +1821,7 @@ function zr() {
1821
1821
  onClick: () => H(!0),
1822
1822
  className: "flex items-center gap-2",
1823
1823
  children: [
1824
- /* @__PURE__ */ e(kt, { className: "mr-2 h-4 w-4" }),
1824
+ /* @__PURE__ */ e(It, { className: "mr-2 h-4 w-4" }),
1825
1825
  "Calendar Preferences"
1826
1826
  ]
1827
1827
  }
@@ -1879,7 +1879,7 @@ function zr() {
1879
1879
  onOpenChange: j,
1880
1880
  dashboard: r,
1881
1881
  disabled: !d,
1882
- onApply: (i) => Ge({
1882
+ onApply: (i) => Re({
1883
1883
  ...r,
1884
1884
  summary: i
1885
1885
  })
@@ -1888,9 +1888,9 @@ function zr() {
1888
1888
  /* @__PURE__ */ e(
1889
1889
  Ya,
1890
1890
  {
1891
- open: Ie,
1891
+ open: ke,
1892
1892
  onOpenChange: (i) => {
1893
- !i && _e && !E || (g(i), i || (O(null), z([]), me(!1)));
1893
+ !i && _e && !E || (g(i), i || (O(null), B([]), me(!1)));
1894
1894
  },
1895
1895
  children: /* @__PURE__ */ o(Za, { className: "max-w-sm", children: [
1896
1896
  /* @__PURE__ */ o(es, { children: [
@@ -1901,12 +1901,12 @@ function zr() {
1901
1901
  /* @__PURE__ */ e("ul", { className: "list-disc space-y-1 pl-4 text-xs text-muted-foreground", children: F.slice(0, 5).map((i) => /* @__PURE__ */ e("li", { children: i }, i)) })
1902
1902
  ] })
1903
1903
  ] }),
1904
- /* @__PURE__ */ e(ts, { className: "flex-col gap-2 sm:flex-row sm:justify-end", children: E ? /* @__PURE__ */ o(k, { children: [
1904
+ /* @__PURE__ */ e(ts, { className: "flex-col gap-2 sm:flex-row sm:justify-end", children: E ? /* @__PURE__ */ o(I, { children: [
1905
1905
  /* @__PURE__ */ e(
1906
1906
  rs,
1907
1907
  {
1908
1908
  onClick: () => {
1909
- g(!1), O(null), z([]), me(!1);
1909
+ g(!1), O(null), B([]), me(!1);
1910
1910
  },
1911
1911
  className: "m-0",
1912
1912
  children: "Close"
@@ -1938,13 +1938,13 @@ function zr() {
1938
1938
  }
1939
1939
  ),
1940
1940
  /* @__PURE__ */ e(
1941
- Bt,
1941
+ zt,
1942
1942
  {
1943
1943
  open: Es,
1944
1944
  onOpenChange: (i) => {
1945
1945
  te(i);
1946
1946
  },
1947
- onSave: ks,
1947
+ onSave: Is,
1948
1948
  onDiscard: Os,
1949
1949
  isSaving: _e,
1950
1950
  saveLabel: "Save",
@@ -1957,5 +1957,5 @@ function zr() {
1957
1957
  );
1958
1958
  }
1959
1959
  export {
1960
- zr as default
1960
+ Br as default
1961
1961
  };
@@ -1,4 +1,4 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),s=require("./index-DvAOngur.js"),x=require("react");require("react-dom");const P=require("./dashboard-filter-controls-button-DLjcoN1G.js"),_s=require("./date-formatter-CqXdM6JO.js"),Xe=require("./dashboard-summary-settings-dialog-Cpb9FCXf.js"),Us=require("./use-debounced-dirty-check-XHSwAefL.js"),we=require("./normalize-dashboard-for-dirty-check-BXRUMVb2.js"),Ye=require("./use-create-flow-overlay-state-BrmQZdh2.js");function Rs(t){const o=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const a in t)if(a!=="default"){const r=Object.getOwnPropertyDescriptor(t,a);Object.defineProperty(o,a,r.get?r:{enumerable:!0,get:()=>t[a]})}}return o.default=t,Object.freeze(o)}const C=Rs(x);/**
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),s=require("./index-BHWWNpG6.js"),x=require("react");require("react-dom");const P=require("./dashboard-filter-controls-button-DKc_6T_O.js"),_s=require("./date-formatter-CqXdM6JO.js"),Xe=require("./dashboard-summary-settings-dialog-BPyawgMV.js"),Us=require("./use-debounced-dirty-check-XHSwAefL.js"),we=require("./normalize-dashboard-for-dirty-check-BXRUMVb2.js"),Ye=require("./use-create-flow-overlay-state-XkHgf9f3.js");function Rs(t){const o=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const a in t)if(a!=="default"){const r=Object.getOwnPropertyDescriptor(t,a);Object.defineProperty(o,a,r.get?r:{enumerable:!0,get:()=>t[a]})}}return o.default=t,Object.freeze(o)}const C=Rs(x);/**
2
2
  * @license lucide-react v0.453.0 - ISC
3
3
  *
4
4
  * This source code is licensed under the ISC license.