impact-nova 3.0.0-alpha.5 → 3.0.0-alpha.6

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 (27) hide show
  1. package/dist/components/data/ag-grid-react/cell-renderers/editors/list-select-cell-editor.js +56 -42
  2. package/dist/components/data/ag-grid-react/cell-renderers/editors/select-cell-editor.js +48 -45
  3. package/dist/components/data/ag-grid-react/cell-renderers/list-select-display-renderer.js +31 -33
  4. package/dist/components/data/ag-grid-react/cell-renderers/select-display-renderer.js +18 -17
  5. package/dist/components/data/ag-grid-react/editable-utils.d.ts +9 -1
  6. package/dist/components/data/ag-grid-react/editable-utils.js +46 -41
  7. package/dist/components/data/expandable-list-item/expandable-list-item-attributes.js +3 -2
  8. package/dist/components/data/expandable-list-item/expandable-list-item-metrics.js +3 -2
  9. package/dist/components/data/expandable-list-item/sku-picker-chrome.js +35 -30
  10. package/dist/components/data/expandable-list-item/virtualized-responsive-grid.catalog.d.ts +1 -1
  11. package/dist/components/data-display/chart/chart-scatter3d.d.ts +39 -0
  12. package/dist/components/data-display/chart/chart-scatter3d.js +180 -0
  13. package/dist/components/data-display/chart/chart.js +125 -112
  14. package/dist/components/data-display/chart/chart.utils.js +122 -92
  15. package/dist/components/feedback/tooltip/tab-tooltip-render.js +3 -2
  16. package/dist/components/flows/command-palette/shortcut-settings.js +10 -10
  17. package/dist/components/flows/filter-panel/filter-panel.js +4 -4
  18. package/dist/components/forms/choice-card/choice-card-percent.js +68 -50
  19. package/dist/components/forms/choice-card/choice-card.js +23 -23
  20. package/dist/components/forms/select/components/SelectTriggerValue.js +3 -2
  21. package/dist/components/forms/select/components/Submenu.js +3 -2
  22. package/dist/components/primitives/stepper/internals/stepper-summary.js +5 -5
  23. package/dist/impact-nova-components.css +32 -4
  24. package/dist/impact-nova.css +1 -1
  25. package/dist/llms/rules/installation.js +1 -1
  26. package/dist/llms/rules/requirements.js +1 -1
  27. package/package.json +1 -1
@@ -1,30 +1,42 @@
1
- import { jsx as n } from "react/jsx-runtime";
2
- import { forwardRef as E, useState as D, useRef as O, useImperativeHandle as R, useCallback as r } from "react";
1
+ import { jsx as c } from "react/jsx-runtime";
2
+ import { forwardRef as D, useState as O, useRef as h, useImperativeHandle as R, useCallback as i } from "react";
3
3
  import { Select as j } from "../../../../forms/select/select.js";
4
- import { cn as y } from "../../../../../lib/utils.js";
5
- const I = E((g, C) => {
4
+ import { cn as P } from "../../../../../lib/utils.js";
5
+ function k(t) {
6
+ if (typeof t.onValueChange == "function")
7
+ return t.onValueChange;
8
+ const a = t.colDef?.cellEditorParams, e = typeof a == "function" ? a(t) : a;
9
+ if (!e || typeof e != "object" || !("onValueChange" in e))
10
+ return;
11
+ const n = e.onValueChange;
12
+ if (typeof n == "function")
13
+ return n;
14
+ }
15
+ const L = D((t, a) => {
6
16
  const {
7
- value: l,
8
- options: v = [],
9
- placeholder: h = "Select...",
10
- isSearchable: S = !0,
17
+ value: e,
18
+ options: n = [],
19
+ placeholder: S = "Select...",
20
+ isSearchable: V = !0,
11
21
  isClearable: b = !0,
12
- stopEditing: i,
13
- onValueChange: u,
22
+ stopEditing: f,
14
23
  colDef: w
15
- } = g, M = w?.cellRendererParams?.triggerClassName, t = l && typeof l == "object" && "value" in l, o = t ? l.cellMetadata : void 0, c = t ? l.value : l, d = v.map((e) => ({
16
- value: e.value,
17
- label: e.label,
18
- isDisabled: e.isDisabled
19
- })), [s, f] = D(
20
- c != null ? String(c) : null
21
- ), m = O(!1);
22
- R(C, () => ({
24
+ } = t, d = k(t), M = w?.cellRendererParams?.triggerClassName, o = e && typeof e == "object" && "value" in e, m = o ? e.cellMetadata : void 0, s = o ? e.value : e, g = n.map((l) => ({
25
+ value: l.value,
26
+ label: l.label,
27
+ isDisabled: l.isDisabled
28
+ })), [N, C] = O(
29
+ s != null ? String(s) : null
30
+ ), p = h(
31
+ s != null ? String(s) : null
32
+ ), v = h(!1);
33
+ R(a, () => ({
23
34
  getValue() {
24
- return t ? {
25
- value: s,
26
- ...o !== void 0 && { cellMetadata: o }
27
- } : s;
35
+ const l = p.current;
36
+ return o ? {
37
+ value: l,
38
+ ...m !== void 0 && { cellMetadata: m }
39
+ } : l;
28
40
  },
29
41
  isCancelBeforeStart() {
30
42
  return !1;
@@ -33,29 +45,31 @@ const I = E((g, C) => {
33
45
  return !1;
34
46
  },
35
47
  isPopup() {
36
- return !1;
48
+ return !0;
37
49
  }
38
50
  }));
39
- const N = d.find((e) => e.value === s) ?? null, a = r(() => {
40
- m.current || (m.current = !0, i());
41
- }, [i]), x = r(
42
- (e) => {
43
- const p = e ? e.value : null;
44
- f(p), u?.(p), a();
51
+ const x = g.find((l) => l.value === N) ?? null, r = i(() => {
52
+ v.current || (v.current = !0, f());
53
+ }, [f]), y = i(
54
+ (l) => {
55
+ const u = l ? l.value : null;
56
+ p.current = u, C(u), d?.(u), r();
45
57
  },
46
- [a, f, u]
47
- ), V = r(() => {
48
- a();
49
- }, [a]);
50
- return /* @__PURE__ */ n("div", { className: "flex h-full w-full min-w-0 items-center ag-cell-inner-padding", children: /* @__PURE__ */ n("div", { className: y("min-w-0 flex-1", M), children: /* @__PURE__ */ n(
58
+ [r, C, d]
59
+ ), E = i(() => {
60
+ queueMicrotask(() => {
61
+ r();
62
+ });
63
+ }, [r]);
64
+ return /* @__PURE__ */ c("div", { className: "flex h-full w-full min-w-0 items-center ag-cell-inner-padding", children: /* @__PURE__ */ c("div", { className: P("min-w-0 flex-1", M), children: /* @__PURE__ */ c(
51
65
  j,
52
66
  {
53
- options: d,
54
- value: N,
55
- onChange: x,
56
- onMenuClose: V,
57
- placeholder: h,
58
- isSearchable: S,
67
+ options: g,
68
+ value: x,
69
+ onChange: y,
70
+ onMenuClose: E,
71
+ placeholder: S,
72
+ isSearchable: V,
59
73
  isClearable: b,
60
74
  isMulti: !1,
61
75
  defaultMenuIsOpen: !0,
@@ -64,7 +78,7 @@ const I = E((g, C) => {
64
78
  }
65
79
  ) }) });
66
80
  });
67
- I.displayName = "ListSelectCellEditor";
81
+ L.displayName = "ListSelectCellEditor";
68
82
  export {
69
- I as ListSelectCellEditor
83
+ L as ListSelectCellEditor
70
84
  };
@@ -1,37 +1,40 @@
1
- import { jsxs as O, jsx as i } from "react/jsx-runtime";
2
- import { forwardRef as y, useState as F, useRef as k, useImperativeHandle as B, useCallback as c } from "react";
3
- import { Select as H } from "../../../../forms/select/select.js";
4
- import { SelectAiInsightAffordance as L } from "../select-ai-insight-affordance.js";
5
- const P = y((g, b) => {
1
+ import { jsxs as F, jsx as i } from "react/jsx-runtime";
2
+ import { forwardRef as k, useState as B, useRef as g, useImperativeHandle as H, useCallback as r } from "react";
3
+ import { Select as L } from "../../../../forms/select/select.js";
4
+ import { SelectAiInsightAffordance as P } from "../select-ai-insight-affordance.js";
5
+ const q = k((b, v) => {
6
6
  const {
7
7
  value: l,
8
- options: v = [],
8
+ options: S = [],
9
9
  placeholder: C = "Select...",
10
- isSearchable: S = !0,
11
- isClearable: w = !0,
12
- stopEditing: r,
13
- onValueChange: u,
14
- data: t,
15
- showAiInsight: x,
16
- aiInsightField: M,
17
- confidenceScore: V,
10
+ isSearchable: w = !0,
11
+ isClearable: x = !0,
12
+ stopEditing: u,
13
+ onValueChange: d,
14
+ data: n,
15
+ showAiInsight: M,
16
+ aiInsightField: V,
17
+ confidenceScore: R,
18
18
  confidenceScoreField: j,
19
19
  confidenceReason: D,
20
20
  confidenceReasonField: E,
21
21
  confidenceLabel: I
22
- } = g, n = l && typeof l == "object" && "value" in l, o = n ? l.cellMetadata : void 0, d = n ? l.value : l, f = v.map((e) => ({
22
+ } = b, o = l && typeof l == "object" && "value" in l, s = o ? l.cellMetadata : void 0, t = o ? l.value : l, f = S.map((e) => ({
23
23
  value: e.value,
24
24
  label: e.label,
25
25
  isDisabled: e.isDisabled
26
- })), [s, p] = F(
27
- d != null ? String(d) : null
28
- ), h = k(!1);
29
- B(b, () => ({
26
+ })), [N, p] = B(
27
+ t != null ? String(t) : null
28
+ ), m = g(
29
+ t != null ? String(t) : null
30
+ ), h = g(!1);
31
+ H(v, () => ({
30
32
  getValue() {
31
- return n ? {
32
- value: s,
33
- ...o !== void 0 && { cellMetadata: o }
34
- } : s;
33
+ const e = m.current;
34
+ return o ? {
35
+ value: e,
36
+ ...s !== void 0 && { cellMetadata: s }
37
+ } : e;
35
38
  },
36
39
  isCancelBeforeStart() {
37
40
  return !1;
@@ -43,33 +46,33 @@ const P = y((g, b) => {
43
46
  return !0;
44
47
  }
45
48
  }));
46
- const N = f.find((e) => e.value === s) ?? null, a = c(() => {
47
- h.current || (h.current = !0, r());
48
- }, [r]), R = c(
49
+ const A = f.find((e) => e.value === N) ?? null, a = r(() => {
50
+ h.current || (h.current = !0, u());
51
+ }, [u]), O = r(
49
52
  (e) => {
50
- const m = e ? e.value : null;
51
- p(m), u?.(m), a();
53
+ const c = e ? e.value : null;
54
+ m.current = c, p(c), d?.(c), a();
52
55
  },
53
- [a, u, p]
54
- ), A = c(() => {
56
+ [a, d, p]
57
+ ), y = r(() => {
55
58
  a();
56
59
  }, [a]);
57
- return /* @__PURE__ */ O(
60
+ return /* @__PURE__ */ F(
58
61
  "div",
59
62
  {
60
63
  className: "box-border flex h-full w-full min-w-0 items-center gap-2 ps-2 pe-2.5 ag-editable-cell-highlight",
61
64
  "data-component": "select-cell-editor",
62
65
  children: [
63
66
  /* @__PURE__ */ i("div", { className: "min-w-0 flex-1", children: /* @__PURE__ */ i(
64
- H,
67
+ L,
65
68
  {
66
69
  options: f,
67
- value: N,
68
- onChange: R,
69
- onMenuClose: A,
70
+ value: A,
71
+ onChange: O,
72
+ onMenuClose: y,
70
73
  placeholder: C,
71
- isSearchable: S,
72
- isClearable: w,
74
+ isSearchable: w,
75
+ isClearable: x,
73
76
  isMulti: !1,
74
77
  defaultMenuIsOpen: !0,
75
78
  className: "!border-none !shadow-none !ring-0 !h-7 !rounded-[8px] !px-1.5",
@@ -77,24 +80,24 @@ const P = y((g, b) => {
77
80
  }
78
81
  ) }),
79
82
  /* @__PURE__ */ i(
80
- L,
83
+ P,
81
84
  {
82
- showAiInsight: x,
83
- aiInsightField: M,
84
- confidenceScore: V,
85
+ showAiInsight: M,
86
+ aiInsightField: V,
87
+ confidenceScore: R,
85
88
  confidenceScoreField: j,
86
89
  confidenceReason: D,
87
90
  confidenceReasonField: E,
88
91
  confidenceLabel: I,
89
- data: t && typeof t == "object" ? t : null,
90
- cellMetadata: o
92
+ data: n && typeof n == "object" ? n : null,
93
+ cellMetadata: s
91
94
  }
92
95
  )
93
96
  ]
94
97
  }
95
98
  );
96
99
  });
97
- P.displayName = "SelectCellEditor";
100
+ q.displayName = "SelectCellEditor";
98
101
  export {
99
- P as SelectCellEditor
102
+ q as SelectCellEditor
100
103
  };
@@ -1,61 +1,59 @@
1
- import { jsx as t, jsxs as m } from "react/jsx-runtime";
1
+ import { jsx as t, jsxs as b } from "react/jsx-runtime";
2
2
  import { Cross as N, ChevronRight as D } from "impact-nova-icons";
3
- import { cn as r } from "../../../../lib/utils.js";
3
+ import { cn as o } from "../../../../lib/utils.js";
4
4
  import { selectTriggerVariants as j } from "../../../forms/select/select.variants.js";
5
- const C = (b) => {
5
+ import { readColDefEditable as C } from "../editable-utils.js";
6
+ const V = (c) => {
6
7
  const {
7
- value: l,
8
- options: g = [],
9
- placeholder: h = "Select...",
10
- disabled: i,
11
- isClearable: x = !0,
8
+ value: e,
9
+ options: h = [],
10
+ placeholder: x = "Select...",
11
+ disabled: a,
12
+ isClearable: g = !0,
12
13
  triggerClassName: w,
13
- colDef: o,
14
- data: s,
14
+ colDef: d,
15
+ data: i,
15
16
  setValue: v
16
- } = b, d = l && typeof l == "object" && "cellMetadata" in l ? l.cellMetadata?._isDisabled : void 0, f = s && typeof s == "object" && "rowMetadata" in s ? s.rowMetadata?._isDisabled : void 0;
17
- let e = !1;
18
- if (!i) {
19
- const a = o?._originalEditable;
20
- o?.editable === !1 ? e = !1 : d === !1 ? e = !0 : d === !0 ? e = !1 : f === !1 ? e = !0 : f === !0 ? e = !1 : e = a === !0 || o?.editable === !0;
21
- }
22
- const n = l && typeof l == "object" && "value" in l ? l.value : l, u = g.find((a) => a.value === String(n ?? ""))?.label ?? (n != null && n !== "" ? String(n) : ""), c = !u, y = x && e && !c && !i, p = (a) => {
23
- a.preventDefault(), a.stopPropagation(), v?.(null);
17
+ } = c, f = e && typeof e == "object" && "cellMetadata" in e ? e.cellMetadata?._isDisabled : void 0, m = i && typeof i == "object" && "rowMetadata" in i ? i.rowMetadata?._isDisabled : void 0;
18
+ let l = !1;
19
+ a || (d?.editable === !1 ? l = !1 : f === !1 ? l = !0 : f === !0 ? l = !1 : m === !1 ? l = !0 : m === !0 ? l = !1 : l = C(d, c));
20
+ const s = e && typeof e == "object" && "value" in e ? e.value : e, u = h.find((n) => n.value === String(s ?? ""))?.label ?? (s != null && s !== "" ? String(s) : ""), r = !u, y = g && l && !r && !a, p = (n) => {
21
+ n.preventDefault(), n.stopPropagation(), v?.(null);
24
22
  };
25
23
  return /* @__PURE__ */ t(
26
24
  "div",
27
25
  {
28
- className: r(
26
+ className: o(
29
27
  "flex h-full w-full min-w-0 items-center ag-cell-inner-padding",
30
- i && "cursor-not-allowed opacity-60",
31
- !i && e && "in-ag-editable-cell-highlight"
28
+ a && "cursor-not-allowed opacity-60",
29
+ !a && l && "in-ag-editable-cell-highlight"
32
30
  ),
33
- children: /* @__PURE__ */ t("div", { className: r("min-w-0 flex-1", w), children: /* @__PURE__ */ t(
31
+ children: /* @__PURE__ */ t("div", { className: o("min-w-0 flex-1", w), children: /* @__PURE__ */ t(
34
32
  "div",
35
33
  {
36
- className: r(
34
+ className: o(
37
35
  j({
38
36
  size: "default",
39
37
  error: !1,
40
- disabled: !!i,
41
- readOnly: !e,
38
+ disabled: !!a,
39
+ readOnly: !l,
42
40
  open: !1
43
41
  }),
44
42
  "w-full max-w-full"
45
43
  ),
46
44
  "data-component": "select-trigger",
47
- children: /* @__PURE__ */ m("div", { className: "flex w-full min-w-0 max-w-full items-center justify-between", children: [
45
+ children: /* @__PURE__ */ b("div", { className: "flex w-full min-w-0 max-w-full items-center justify-between", children: [
48
46
  /* @__PURE__ */ t(
49
47
  "span",
50
48
  {
51
- className: r(
49
+ className: o(
52
50
  "block min-w-0 truncate text-[14px] text-content",
53
- c ? "font-normal text-content-placeholder" : "font-normal"
51
+ r ? "font-normal text-content-placeholder" : "font-normal"
54
52
  ),
55
- children: c ? h : u
53
+ children: r ? x : u
56
54
  }
57
55
  ),
58
- e ? /* @__PURE__ */ m("div", { className: "flex shrink-0 items-center gap-1 text-content-icon", children: [
56
+ /* @__PURE__ */ b("div", { className: "flex shrink-0 items-center gap-1 text-content-icon", children: [
59
57
  y ? /* @__PURE__ */ t(
60
58
  "span",
61
59
  {
@@ -76,14 +74,14 @@ const C = (b) => {
76
74
  className: "rotate-90 shrink-0"
77
75
  }
78
76
  )
79
- ] }) : null
77
+ ] })
80
78
  ] })
81
79
  }
82
80
  ) })
83
81
  }
84
82
  );
85
83
  };
86
- C.displayName = "ListSelectDisplayRenderer";
84
+ V.displayName = "ListSelectDisplayRenderer";
87
85
  export {
88
- C as ListSelectDisplayRenderer
86
+ V as ListSelectDisplayRenderer
89
87
  };
@@ -1,8 +1,9 @@
1
1
  import { jsxs as p, jsx as s } from "react/jsx-runtime";
2
2
  import { LoadingSpinner as N, ChevronRight as R } from "impact-nova-icons";
3
3
  import { cn as f } from "../../../../lib/utils.js";
4
- import { SelectAiInsightAffordance as E } from "./select-ai-insight-affordance.js";
5
- function F(e) {
4
+ import { readColDefEditable as F } from "../editable-utils.js";
5
+ import { SelectAiInsightAffordance as C } from "./select-ai-insight-affordance.js";
6
+ function E(e) {
6
7
  if (e && typeof e == "object" && "cellMetadata" in e)
7
8
  return e.cellMetadata;
8
9
  }
@@ -10,16 +11,16 @@ function A(e) {
10
11
  if (e && typeof e == "object" && "rowMetadata" in e)
11
12
  return e.rowMetadata;
12
13
  }
13
- function h(e) {
14
- return e.isLoading === !0 || F(e.value)?.isLoading === !0 ? !0 : A(e.data)?.isLoading === !0;
14
+ function g(e) {
15
+ return e.isLoading === !0 || E(e.value)?.isLoading === !0 ? !0 : A(e.data)?.isLoading === !0;
15
16
  }
16
- function C(e) {
17
+ function I(e) {
17
18
  const { value: t, data: a, disabled: d, colDef: i } = e;
18
- if (d || h(e)) return !1;
19
- const n = t && typeof t == "object" && "cellMetadata" in t ? t.cellMetadata?._isDisabled : void 0, l = a && typeof a == "object" && "rowMetadata" in a ? a.rowMetadata?._isDisabled : void 0, u = i?._originalEditable;
20
- return i?.editable === !1 ? !1 : n === !1 ? !0 : n === !0 ? !1 : l === !1 ? !0 : l === !0 ? !1 : u === !0 || i?.editable === !0;
19
+ if (d || g(e)) return !1;
20
+ const n = t && typeof t == "object" && "cellMetadata" in t ? t.cellMetadata?._isDisabled : void 0, l = a && typeof a == "object" && "rowMetadata" in a ? a.rowMetadata?._isDisabled : void 0;
21
+ return i?.editable === !1 ? !1 : n === !1 ? !0 : n === !0 ? !1 : l === !1 ? !0 : l === !0 ? !1 : F(i, e);
21
22
  }
22
- const I = (e) => {
23
+ const O = (e) => {
23
24
  const {
24
25
  value: t,
25
26
  options: a = [],
@@ -27,13 +28,13 @@ const I = (e) => {
27
28
  disabled: i,
28
29
  data: n,
29
30
  showAiInsight: l,
30
- aiInsightField: u,
31
+ aiInsightField: h,
31
32
  confidenceScore: v,
32
33
  confidenceScoreField: y,
33
34
  confidenceReason: w,
34
35
  confidenceReasonField: x,
35
36
  confidenceLabel: S
36
- } = e, o = h(e), r = C(e), M = r || o, b = t && typeof t == "object" && "value" in t, j = b ? t.cellMetadata : void 0, c = b ? t.value : t, m = a.find((L) => L.value === String(c ?? ""))?.label ?? (c != null && c !== "" ? String(c) : ""), g = !m, D = n && typeof n == "object" ? n : null;
37
+ } = e, o = g(e), r = I(e), M = r || o, u = t && typeof t == "object" && "value" in t, j = u ? t.cellMetadata : void 0, c = u ? t.value : t, b = a.find((L) => L.value === String(c ?? ""))?.label ?? (c != null && c !== "" ? String(c) : ""), m = !b, D = n && typeof n == "object" ? n : null;
37
38
  return /* @__PURE__ */ p(
38
39
  "div",
39
40
  {
@@ -60,9 +61,9 @@ const I = (e) => {
60
61
  {
61
62
  className: f(
62
63
  "truncate text-sm font-medium text-content",
63
- g && "text-content-empty"
64
+ m && "text-content-empty"
64
65
  ),
65
- children: g ? d : m
66
+ children: m ? d : b
66
67
  }
67
68
  ),
68
69
  o ? /* @__PURE__ */ s(N, { size: "14px", className: "shrink-0 text-content-icon" }) : r ? /* @__PURE__ */ s(R, { className: "h-3.5 w-3.5 shrink-0 rotate-90 text-content-icon" }) : null
@@ -70,10 +71,10 @@ const I = (e) => {
70
71
  }
71
72
  ),
72
73
  /* @__PURE__ */ s(
73
- E,
74
+ C,
74
75
  {
75
76
  showAiInsight: l,
76
- aiInsightField: u,
77
+ aiInsightField: h,
77
78
  confidenceScore: v,
78
79
  confidenceScoreField: y,
79
80
  confidenceReason: w,
@@ -87,7 +88,7 @@ const I = (e) => {
87
88
  }
88
89
  );
89
90
  };
90
- I.displayName = "SelectDisplayRenderer";
91
+ O.displayName = "SelectDisplayRenderer";
91
92
  export {
92
- I as SelectDisplayRenderer
93
+ O as SelectDisplayRenderer
93
94
  };
@@ -1,4 +1,12 @@
1
- import { ColDef, ColGroupDef } from 'ag-grid-community';
1
+ import { ColDef, ColGroupDef, ICellRendererParams } from 'ag-grid-community';
2
+ /**
3
+ * Resolve column-level editability for display renderers.
4
+ *
5
+ * AG Grid accepts `editable` as a boolean *or* a callback. Display chrome
6
+ * (Select trigger, chevron) must invoke the callback — `=== true` misses every
7
+ * function and paints the cell as a disabled input.
8
+ */
9
+ export declare function readColDefEditable(colDef: ColDef | null | undefined, rendererParams: ICellRendererParams): boolean;
2
10
  /**
3
11
  * Recursively overrides `editable` on leaf columns to be a function
4
12
  * that enforces the **4-level editable priority**: column < split < row < cell.
@@ -1,62 +1,67 @@
1
1
  import { resolveCellEditable as d } from "./cell-renderers/cell-renderer-utils.js";
2
- const y = (o, l) => {
3
- if (l in o) return o[l];
4
- if (l.includes(".")) {
5
- const e = l.split(".");
6
- let t = o;
7
- for (const n of e)
8
- if (t != null && typeof t == "object")
9
- t = t[n];
2
+ function j(n, t) {
3
+ const e = n?.editable;
4
+ return typeof e == "function" ? e(t) : e === !0 ? !0 : e === !1 ? !1 : n?._originalEditable === !0;
5
+ }
6
+ const y = (n, t) => {
7
+ if (t in n) return n[t];
8
+ if (t.includes(".")) {
9
+ const e = t.split(".");
10
+ let l = n;
11
+ for (const r of e)
12
+ if (l != null && typeof l == "object")
13
+ l = l[r];
10
14
  else
11
15
  return;
12
- return t;
16
+ return l;
13
17
  }
14
- }, h = (o) => {
15
- const l = o.colDef.field;
16
- if (!l) return !1;
17
- let e = o.data, t = l;
18
- if (!(l in e) && l.includes(".")) {
19
- const r = l.split(".");
20
- t = r[r.length - 1];
21
- for (let i = 0; i < r.length - 1; i++) {
22
- const s = e[r[i]];
23
- if (s != null && typeof s == "object")
24
- e = s;
18
+ }, E = (n) => {
19
+ const t = n.colDef.field;
20
+ if (!t) return !1;
21
+ let e = n.data, l = t;
22
+ if (!(t in e) && t.includes(".")) {
23
+ const o = t.split(".");
24
+ l = o[o.length - 1];
25
+ for (let i = 0; i < o.length - 1; i++) {
26
+ const a = e[o[i]];
27
+ if (a != null && typeof a == "object")
28
+ e = a;
25
29
  else
26
30
  return !1;
27
31
  }
28
32
  }
29
- const n = e[t], u = o.newValue;
30
- return n && typeof n == "object" && "cellMetadata" in n ? e[t] = u && typeof u == "object" && "value" in u ? u : { ...n, value: u } : e[t] = u, !0;
33
+ const r = e[l], u = n.newValue;
34
+ return r && typeof r == "object" && "cellMetadata" in r ? e[l] = u && typeof u == "object" && "value" in u ? u : { ...r, value: u } : e[l] = u, !0;
31
35
  };
32
- function j(o) {
33
- return o.map((l) => {
34
- const e = { ...l };
36
+ function g(n) {
37
+ return n.map((t) => {
38
+ const e = { ...t };
35
39
  if (e.children?.length)
36
- return e.children = j(e.children), e;
37
- const t = e.field;
38
- if (!t) return e;
39
- const n = e.cellEditorParams?.splits, u = n?.some((i) => i.editable === !0) ?? !1, r = typeof e.editable == "boolean" ? e.editable : void 0;
40
- return e._originalEditable = r, n || (e.valueSetter = h), e.editable = (i) => {
40
+ return e.children = g(e.children), e;
41
+ const l = e.field;
42
+ if (!l) return e;
43
+ const r = e.cellEditorParams?.splits, u = r?.some((i) => i.editable === !0) ?? !1, o = typeof e.editable == "boolean" ? e.editable : void 0;
44
+ return e._originalEditable = o, r || (e.valueSetter = E), e.editable = (i) => {
41
45
  if (i.node?.group === !0 || i.data?.group === !0)
42
46
  return !1;
43
- const s = i.data;
44
- if (!s) return u || !!r;
45
- const c = y(s, t);
46
- if (n) {
47
- const p = c != null && typeof c == "object" ? c : null;
48
- return n.some((a) => {
49
- const f = a.field?.split(".")?.pop();
47
+ const a = i.data;
48
+ if (!a) return u || !!o;
49
+ const s = y(a, l);
50
+ if (r) {
51
+ const p = s != null && typeof s == "object" ? s : null;
52
+ return r.some((c) => {
53
+ const f = c.field?.split(".")?.pop();
50
54
  if (!f) return !1;
51
55
  const v = p?.[f];
52
- return d(r, a.editable, s, v);
56
+ return d(o, c.editable, a, v);
53
57
  });
54
58
  }
55
- const b = c != null && typeof c == "object" && "value" in c ? c : void 0;
56
- return d(r, void 0, s, b);
59
+ const b = s != null && typeof s == "object" && "value" in s ? s : void 0;
60
+ return d(o, void 0, a, b);
57
61
  }, e;
58
62
  });
59
63
  }
60
64
  export {
61
- j as addRowDataEditableCheck
65
+ g as addRowDataEditableCheck,
66
+ j as readColDefEditable
62
67
  };
@@ -3,7 +3,8 @@ import { Badge as s } from "../../data-display/badge/badge.js";
3
3
  import { FilterPopoverContent as u } from "../../flows/filter-strip/filter-tag-list.js";
4
4
  import { Popover as b, PopoverTrigger as f } from "../../feedback/popover/popover.js";
5
5
  import { Tooltip as g, TooltipTrigger as v, TooltipContent as x } from "../../feedback/tooltip/tooltip.js";
6
- function w({
6
+ import "react";
7
+ function I({
7
8
  tags: o,
8
9
  title: l = "Attributes",
9
10
  maxVisibleTags: n = 4,
@@ -70,5 +71,5 @@ function w({
70
71
  );
71
72
  }
72
73
  export {
73
- w as ExpandableListItemAttributes
74
+ I as ExpandableListItemAttributes
74
75
  };
@@ -1,8 +1,9 @@
1
1
  import { jsx as e, jsxs as s } from "react/jsx-runtime";
2
2
  import { ScrollOverflowAffordance as o } from "../../layout/horizontal-scroller/scroll-overflow-affordance.js";
3
+ import "react";
3
4
  import { OverflowTooltip as r } from "../../feedback/tooltip/overflow-tooltip.js";
4
5
  const m = 128;
5
- function x({
6
+ function f({
6
7
  columns: i,
7
8
  sectionId: l = "metrics"
8
9
  }) {
@@ -50,5 +51,5 @@ function x({
50
51
  );
51
52
  }
52
53
  export {
53
- x as ExpandableListItemMetrics
54
+ f as ExpandableListItemMetrics
54
55
  };