@owp/core 2.5.40 → 2.5.41

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 (30) hide show
  1. package/dist/_virtual/index10.js +2 -2
  2. package/dist/_virtual/index12.js +2 -2
  3. package/dist/_virtual/index13.js +2 -2
  4. package/dist/_virtual/index14.js +2 -2
  5. package/dist/_virtual/index15.js +2 -2
  6. package/dist/_virtual/index16.js +4 -4
  7. package/dist/_virtual/index17.js +4 -4
  8. package/dist/_virtual/index18.js +4 -4
  9. package/dist/_virtual/index19.js +4 -4
  10. package/dist/_virtual/index5.js +2 -2
  11. package/dist/components/OwpTreeGrid/internal/treeGridRuntime.js +455 -444
  12. package/dist/components/OwpTreeGrid/internal/treeGridRuntime.js.map +1 -1
  13. package/dist/layout/components/toggles/NavigationSearchToggle.js +3 -3
  14. package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/CODE128/index.js +1 -1
  15. package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/CODE39/index.js +1 -1
  16. package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/CODE93/index.js +1 -1
  17. package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/EAN_UPC/index.js +1 -1
  18. package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/GenericBarcode/index.js +1 -1
  19. package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/ITF/index.js +1 -1
  20. package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/MSI/index.js +1 -1
  21. package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/codabar/index.js +1 -1
  22. package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/pharmacode/index.js +1 -1
  23. package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/renderers/index.js +1 -1
  24. package/dist/node_modules/.pnpm/react-is@16.13.1/node_modules/react-is/index.js +1 -1
  25. package/dist/node_modules/.pnpm/react-overlays@5.2.1_react-dom@19.2.4_react@19.2.4__react@19.2.4/node_modules/react-overlays/esm/Portal.js +1 -1
  26. package/dist/types/utils/treeGridUtil.d.ts +5 -0
  27. package/dist/utils/treeGridUtil.js +153 -150
  28. package/dist/utils/treeGridUtil.js.map +1 -1
  29. package/dist/utils.js +41 -40
  30. package/package.json +1 -1
@@ -1,79 +1,81 @@
1
1
  var M = Object.defineProperty;
2
2
  var l = (e, t) => M(e, "name", { value: t, configurable: !0 });
3
- import { TREEGRID_CELL_CHANGED_CLASS as X, TREEGRID_CELL_HIGHLIGHT_COLOR as p } from "../constants/treeGrid.js";
4
- import { TREEGRID_INPUT_CELL_COLOR as _t, TREEGRID_WARNING_CELL_COLOR as Dt } from "../constants/treeGrid.js";
3
+ import { TREEGRID_CELL_CHANGED_CLASS as X, TREEGRID_CELL_HIGHLIGHT_COLOR as g } from "../constants/treeGrid.js";
4
+ import { TREEGRID_INPUT_CELL_COLOR as It, TREEGRID_WARNING_CELL_COLOR as St } from "../constants/treeGrid.js";
5
5
  import { parseTreeGridXmlToJson as Q } from "../components/OwpTreeGrid/internal/treeGridLayout.js";
6
- import { resolveTreeGridSelectedRows as g } from "../components/OwpTreeGrid/internal/treeGridSelection.js";
7
- import { emitTreeGridBodyRowsChanged as _ } from "./internal/treeGridBodyRowsEvent.js";
8
- import { isArray as D } from "../node_modules/.pnpm/es-toolkit@1.39.10/node_modules/es-toolkit/dist/compat/predicate/isArray.js";
9
- import { lowerCase as J } from "../node_modules/.pnpm/es-toolkit@1.39.10/node_modules/es-toolkit/dist/compat/string/lowerCase.js";
6
+ import { resolveTreeGridSelectedRows as J } from "../components/OwpTreeGrid/internal/treeGridSelection.js";
7
+ import { emitTreeGridBodyRowsChanged as D } from "./internal/treeGridBodyRowsEvent.js";
8
+ import { isArray as A } from "../node_modules/.pnpm/es-toolkit@1.39.10/node_modules/es-toolkit/dist/compat/predicate/isArray.js";
9
+ import { lowerCase as Z } from "../node_modules/.pnpm/es-toolkit@1.39.10/node_modules/es-toolkit/dist/compat/string/lowerCase.js";
10
10
  import { isPlainObject as h } from "../node_modules/.pnpm/es-toolkit@1.39.10/node_modules/es-toolkit/dist/predicate/isPlainObject.js";
11
- import { get as Z } from "../node_modules/.pnpm/es-toolkit@1.39.10/node_modules/es-toolkit/dist/compat/object/get.js";
12
- import { isEmpty as ee } from "../node_modules/.pnpm/es-toolkit@1.39.10/node_modules/es-toolkit/dist/compat/predicate/isEmpty.js";
11
+ import { get as ee } from "../node_modules/.pnpm/es-toolkit@1.39.10/node_modules/es-toolkit/dist/compat/object/get.js";
12
+ import { isEmpty as te } from "../node_modules/.pnpm/es-toolkit@1.39.10/node_modules/es-toolkit/dist/compat/predicate/isEmpty.js";
13
13
  import { without as L } from "../node_modules/.pnpm/es-toolkit@1.39.10/node_modules/es-toolkit/dist/compat/array/without.js";
14
- const te = ["Added", "Changed"], re = ["OWP", "IPX"], ne = /^H{1,2}(?::m{1,2})?(?::s{1,2})?$/, F = "__owpAddedByAddTreeGridRowById", E = "__owpAddedRowHighlightColumns", $ = "__owpAddedRowInitialValueKeys", A = "__owpAddedRowInitialValues", K = "__owpAddedRowBaselineValues", G = "__owpCellStyleBaselineValues", y = "Selected", se = /* @__PURE__ */ l(({
14
+ const re = ["Added", "Changed"], ne = ["OWP", "IPX"], se = /^H{1,2}(?::m{1,2})?(?::s{1,2})?$/, F = "__owpAddedByAddTreeGridRowById", K = "__owpAddedRowEditableColumns", G = "__owpAddedRowHighlightColumns", $ = "__owpAddedRowInitialValueKeys", I = "__owpAddedRowInitialValues", j = "__owpAddedRowBaselineValues", E = "__owpCellStyleBaselineValues", y = "Selected", le = /* @__PURE__ */ l(({
15
15
  label: e
16
- }) => `${e} 필수 입력`, "DEFAULT_TREE_GRID_REQUIRED_CELL_MESSAGE_FACTORY"), le = [
16
+ }) => `${e} 필수 입력`, "DEFAULT_TREE_GRID_REQUIRED_CELL_MESSAGE_FACTORY"), ae = [
17
17
  "added"
18
- ], I = /* @__PURE__ */ l((e) => D(e) ? e.filter((t) => typeof t == "string" && t !== "") : [], "normalizeTreeGridStringValues"), S = I, ae = /* @__PURE__ */ l((e) => {
18
+ ], _ = /* @__PURE__ */ l((e) => A(e) ? e.filter((t) => typeof t == "string" && t !== "") : [], "normalizeTreeGridStringValues"), S = _, ie = _, ce = /* @__PURE__ */ l((e) => {
19
19
  e && (e[F] = 1);
20
- }, "markTreeGridRowAddedById"), ie = /* @__PURE__ */ l((e) => {
20
+ }, "markTreeGridRowAddedById"), de = /* @__PURE__ */ l((e) => {
21
21
  const t = e == null ? void 0 : e[F];
22
22
  return !!e && t !== 0 && t !== !1 && t !== void 0;
23
23
  }, "isTreeGridRowAddedById"), m = /* @__PURE__ */ l((e) => {
24
24
  const t = e == null ? void 0 : e.Added;
25
- return t === 1 || t === "1" || t === !0 || ie(e);
26
- }, "isTreeGridAddedRow"), ce = /* @__PURE__ */ l((e) => {
25
+ return t === 1 || t === "1" || t === !0 || de(e);
26
+ }, "isTreeGridAddedRow"), oe = /* @__PURE__ */ l((e) => {
27
27
  const t = e == null ? void 0 : e.Changed;
28
28
  return !m(e) && (t === 1 || t === "1" || t === !0);
29
- }, "isTreeGridChangedRow"), j = /* @__PURE__ */ l((e) => {
29
+ }, "isTreeGridChangedRow"), O = /* @__PURE__ */ l((e) => {
30
30
  const t = e == null ? void 0 : e.Deleted;
31
31
  return t === 1 || t === "1" || t === !0;
32
- }, "isTreeGridDeletedRow"), de = /* @__PURE__ */ l((e) => {
33
- const t = D(e) ? e : e ? [e] : le;
32
+ }, "isTreeGridDeletedRow"), ue = /* @__PURE__ */ l((e) => {
33
+ const t = A(e) ? e : e ? [e] : ae;
34
34
  return t.includes("all") ? /* @__PURE__ */ new Set(["all"]) : new Set(
35
35
  t.filter(
36
36
  (r) => r === "added" || r === "changed"
37
37
  )
38
38
  );
39
- }, "normalizeTreeGridRequiredCellTargetRows"), oe = /* @__PURE__ */ l((e, t) => j(e) ? !1 : t.has("all") ? e.Kind === "Data" || m(e) : t.has("added") && m(e) || t.has("changed") && ce(e), "shouldValidateTreeGridRequiredCellRow"), ue = /* @__PURE__ */ l((e) => !!e && !j(e) && (e.Kind === "Data" || m(e)), "shouldValidateExplicitTreeGridRequiredCellRow"), fe = /* @__PURE__ */ l((e, t) => {
39
+ }, "normalizeTreeGridRequiredCellTargetRows"), fe = /* @__PURE__ */ l((e, t) => O(e) ? !1 : t.has("all") ? e.Kind === "Data" || m(e) : t.has("added") && m(e) || t.has("changed") && oe(e), "shouldValidateTreeGridRequiredCellRow"), Re = /* @__PURE__ */ l((e) => !!e && !O(e) && (e.Kind === "Data" || m(e)), "shouldValidateExplicitTreeGridRequiredCellRow"), Te = /* @__PURE__ */ l((e, t) => {
40
40
  var r;
41
41
  if (t)
42
42
  return typeof t.id != "string" ? t : ((r = e.Rows) == null ? void 0 : r[t.id]) ?? t;
43
- }, "resolveLiveTreeGridRequiredCellRow"), Re = /* @__PURE__ */ l((e, t) => {
43
+ }, "resolveLiveTreeGridRequiredCellRow"), Ee = /* @__PURE__ */ l((e, t) => {
44
44
  const r = /* @__PURE__ */ new Set(), n = [];
45
45
  return t.forEach((s) => {
46
- const a = fe(e, s);
47
- !ue(a) || r.has(a) || (r.add(a), n.push(a));
46
+ const a = Te(e, s);
47
+ !Re(a) || r.has(a) || (r.add(a), n.push(a));
48
48
  }), n;
49
- }, "normalizeExplicitTreeGridRequiredCellRows"), Te = /* @__PURE__ */ l((e, t) => {
49
+ }, "normalizeExplicitTreeGridRequiredCellRows"), Ge = /* @__PURE__ */ l((e, t) => {
50
50
  if (t.rows !== void 0)
51
- return Re(e, t.rows);
52
- const r = de(t.targetRows);
51
+ return Ee(e, t.rows);
52
+ const r = ue(t.targetRows);
53
53
  return Object.values(e.Rows ?? {}).filter(
54
- (n) => oe(n, r)
54
+ (n) => fe(n, r)
55
55
  );
56
- }, "getTreeGridRequiredCellRows"), rt = /* @__PURE__ */ l((e, t) => {
56
+ }, "getTreeGridRequiredCellRows"), st = /* @__PURE__ */ l((e, t) => {
57
57
  if (!e || !t)
58
58
  return;
59
59
  const r = e, n = S(
60
- r[E]
60
+ r[G]
61
61
  );
62
- n.includes(t) || (r[E] = [...n, t]);
63
- }, "appendTreeGridAddedRowHighlightColumn"), nt = /* @__PURE__ */ l((e, t) => {
62
+ n.includes(t) || (r[G] = [...n, t]);
63
+ }, "appendTreeGridAddedRowHighlightColumn"), lt = /* @__PURE__ */ l((e, t) => {
64
64
  if (!e || !t)
65
65
  return;
66
66
  const r = e, s = S(
67
- r[E]
67
+ r[G]
68
68
  ).filter((a) => a !== t);
69
69
  if (s.length) {
70
- r[E] = s;
70
+ r[G] = s;
71
71
  return;
72
72
  }
73
- delete r[E];
74
- }, "removeTreeGridAddedRowHighlightColumn"), st = /* @__PURE__ */ l((e) => S(
75
- e == null ? void 0 : e[E]
76
- ), "getTreeGridAddedRowHighlightColumns"), O = /* @__PURE__ */ l((e, t, r) => {
73
+ delete r[G];
74
+ }, "removeTreeGridAddedRowHighlightColumn"), at = /* @__PURE__ */ l((e) => S(
75
+ e == null ? void 0 : e[G]
76
+ ), "getTreeGridAddedRowHighlightColumns"), it = /* @__PURE__ */ l((e) => ie(
77
+ e == null ? void 0 : e[K]
78
+ ), "getTreeGridAddedRowEditableColumns"), x = /* @__PURE__ */ l((e, t, r) => {
77
79
  var a, i, c, d, o;
78
80
  const n = ((a = e.GetType) == null ? void 0 : a.call(e, t, r)) || ((c = (i = e.Cols) == null ? void 0 : i[r]) == null ? void 0 : c.Type) || "", s = ((d = e.GetValue) == null ? void 0 : d.call(e, t, r)) ?? t[r];
79
81
  if (n === "Enum" || n === "Select")
@@ -85,31 +87,31 @@ const te = ["Added", "Changed"], re = ["OWP", "IPX"], ne = /^H{1,2}(?::m{1,2})?(
85
87
  } catch {
86
88
  }
87
89
  return s == null ? "" : `${s}`;
88
- }, "getTreeGridCellComparableValue"), Ge = /* @__PURE__ */ l((e, t) => {
90
+ }, "getTreeGridCellComparableValue"), Ce = /* @__PURE__ */ l((e, t) => {
89
91
  const r = Object.fromEntries(
90
92
  Object.keys(e.Cols ?? {}).map((n) => [
91
93
  n,
92
- O(e, t, n)
94
+ x(e, t, n)
93
95
  ])
94
96
  );
95
- t[K] = r;
96
- }, "markTreeGridAddedRowBaselineValues"), lt = /* @__PURE__ */ l((e, t) => {
97
+ t[j] = r;
98
+ }, "markTreeGridAddedRowBaselineValues"), ct = /* @__PURE__ */ l((e, t) => {
97
99
  var r;
98
- return (r = e == null ? void 0 : e[K]) == null ? void 0 : r[t];
99
- }, "getTreeGridAddedRowBaselineValue"), Ee = /* @__PURE__ */ l((e, t, r) => {
100
+ return (r = e == null ? void 0 : e[j]) == null ? void 0 : r[t];
101
+ }, "getTreeGridAddedRowBaselineValue"), me = /* @__PURE__ */ l((e, t, r) => {
100
102
  var s;
101
103
  const n = t;
102
- n[G] ?? (n[G] = {}), !((s = n[G]) != null && s[r]) && (n[G][r] = {
104
+ n[E] ?? (n[E] = {}), !((s = n[E]) != null && s[r]) && (n[E][r] = {
103
105
  className: e.GetAttribute(t, r, "Class"),
104
106
  color: e.GetAttribute(t, r, "Color")
105
107
  });
106
- }, "preserveTreeGridCellStyleBaseline"), Ce = /* @__PURE__ */ l((e, t) => {
108
+ }, "preserveTreeGridCellStyleBaseline"), he = /* @__PURE__ */ l((e, t) => {
107
109
  var r;
108
- return (r = e[G]) == null ? void 0 : r[t];
109
- }, "getTreeGridCellStyleBaseline"), me = /* @__PURE__ */ l(async () => {
110
+ return (r = e[E]) == null ? void 0 : r[t];
111
+ }, "getTreeGridCellStyleBaseline"), _e = /* @__PURE__ */ l(async () => {
110
112
  const { exportTreeGridExcel: e } = await import("./treeGridExportExcelUtil.js");
111
113
  return e;
112
- }, "loadExportTreeGridExcel"), he = /* @__PURE__ */ l((e) => Object.values((e == null ? void 0 : e.Rows) ?? {}).filter((t) => t.Kind === "Data"), "getDataRows"), ye = /* @__PURE__ */ l((e) => e != null && e.length ? e.map((t) => {
114
+ }, "loadExportTreeGridExcel"), ye = /* @__PURE__ */ l((e) => Object.values((e == null ? void 0 : e.Rows) ?? {}).filter((t) => t.Kind === "Data"), "getDataRows"), De = /* @__PURE__ */ l((e) => e != null && e.length ? e.map((t) => {
113
115
  if (typeof t == "string") {
114
116
  const n = t.trim();
115
117
  return n ? { key: n } : null;
@@ -126,13 +128,13 @@ const te = ["Added", "Changed"], re = ["OWP", "IPX"], ne = /^H{1,2}(?::m{1,2})?(
126
128
  var s;
127
129
  const n = (s = e.CanEdit) == null ? void 0 : s.call(e, t, r);
128
130
  return n === 1 || n === "1" || n === !0;
129
- }, "isTreeGridEditableCell"), _e = /* @__PURE__ */ l((e, t, r) => {
130
- const n = ye(r.columns);
131
+ }, "isTreeGridEditableCell"), Ae = /* @__PURE__ */ l((e, t, r) => {
132
+ const n = De(r.columns);
131
133
  return n.length ? n.filter((s) => {
132
134
  var a;
133
135
  return !!((a = e.Cols) != null && a[s.key]);
134
136
  }) : r.editableOnly ? Object.keys(e.Cols ?? {}).filter((s) => b(e, s) && w(e, t, s)).map((s) => ({ key: s })) : [];
135
- }, "getTreeGridRequiredCellColumns"), De = /* @__PURE__ */ l((e, t) => {
137
+ }, "getTreeGridRequiredCellColumns"), Ie = /* @__PURE__ */ l((e, t) => {
136
138
  var n, s, a;
137
139
  if (t.label)
138
140
  return t.label;
@@ -144,13 +146,13 @@ const te = ["Added", "Changed"], re = ["OWP", "IPX"], ne = /^H{1,2}(?::m{1,2})?(
144
146
  }
145
147
  const r = (a = (s = e.Cols) == null ? void 0 : s[t.key]) == null ? void 0 : a.Caption;
146
148
  return r ? `${r}`.trim() : t.key;
147
- }, "getTreeGridRequiredCellLabel"), Ae = /* @__PURE__ */ l((e, t, r) => t.message ? t.message : (r ?? se)(e), "getTreeGridRequiredCellMessage"), Ie = /* @__PURE__ */ l((e) => e.trim() === "", "isBlankTreeGridRequiredCellValue"), Se = /* @__PURE__ */ l((e, t, r) => {
149
+ }, "getTreeGridRequiredCellLabel"), Se = /* @__PURE__ */ l((e, t, r) => t.message ? t.message : (r ?? le)(e), "getTreeGridRequiredCellMessage"), be = /* @__PURE__ */ l((e) => e.trim() === "", "isBlankTreeGridRequiredCellValue"), Ve = /* @__PURE__ */ l((e, t, r) => {
148
150
  !t || r.focusFirstError === !1 || (e.Focus(t.row, t.col), r.startEditFirstError === !0 && w(e, t.row, t.col) && e.StartEdit(t.row, t.col));
149
- }, "focusFirstTreeGridRequiredCellError"), C = /* @__PURE__ */ l((e) => typeof e == "string" && ne.test(e.trim()), "isTreeGridTimeDateFormat"), x = /* @__PURE__ */ l((e, t, r) => {
151
+ }, "focusFirstTreeGridRequiredCellError"), C = /* @__PURE__ */ l((e) => typeof e == "string" && se.test(e.trim()), "isTreeGridTimeDateFormat"), q = /* @__PURE__ */ l((e, t, r) => {
150
152
  var a;
151
153
  const n = t, s = (a = e.Cols) == null ? void 0 : a[r];
152
154
  return (s == null ? void 0 : s.Type) === "Date" && (C(n[`${r}EditFormat`]) || C(n[`${r}Format`]) || C(s.EditFormat) || C(s.Format));
153
- }, "isTreeGridTimeDateColumn"), q = /* @__PURE__ */ l((e, t, r) => {
155
+ }, "isTreeGridTimeDateColumn"), z = /* @__PURE__ */ l((e, t, r) => {
154
156
  var s;
155
157
  const n = t[r];
156
158
  try {
@@ -160,14 +162,14 @@ const te = ["Added", "Changed"], re = ["OWP", "IPX"], ne = /^H{1,2}(?::m{1,2})?(
160
162
  } catch {
161
163
  }
162
164
  return n == null ? "" : `${n}`;
163
- }, "getTreeGridTimeDateDisplayValue"), be = /* @__PURE__ */ l((e, t) => {
165
+ }, "getTreeGridTimeDateDisplayValue"), Be = /* @__PURE__ */ l((e, t) => {
164
166
  const r = { ...t };
165
167
  return Object.keys(e.Cols ?? {}).forEach((n) => {
166
- x(e, t, n) && (r[n] = q(e, t, n));
168
+ q(e, t, n) && (r[n] = z(e, t, n));
167
169
  }), r;
168
- }, "normalizeTreeGridExternalRow"), H = /* @__PURE__ */ l((e, t) => t.map((r) => be(e, r)), "normalizeTreeGridExternalRows"), k = /* @__PURE__ */ l((e) => e === 1 || e === !0 || e === "1" || e === "true", "isTreeGridExplicitEnabledConfigValue"), Ve = /* @__PURE__ */ l((e) => k(e.SelectingSingle), "isTreeGridSingleSelectionLayout"), Be = /* @__PURE__ */ l((e) => h(e) ? k(
170
+ }, "normalizeTreeGridExternalRow"), H = /* @__PURE__ */ l((e, t) => t.map((r) => Be(e, r)), "normalizeTreeGridExternalRows"), U = /* @__PURE__ */ l((e) => e === 1 || e === !0 || e === "1" || e === "true", "isTreeGridExplicitEnabledConfigValue"), Le = /* @__PURE__ */ l((e) => U(e.SelectingSingle), "isTreeGridSingleSelectionLayout"), ve = /* @__PURE__ */ l((e) => h(e) ? U(
169
171
  e[y]
170
- ) : !1, "isTreeGridSelectedInitialValue"), Le = /* @__PURE__ */ l((e) => {
172
+ ) : !1, "isTreeGridSelectedInitialValue"), Fe = /* @__PURE__ */ l((e) => {
171
173
  if (!h(e))
172
174
  return e;
173
175
  const t = e;
@@ -176,7 +178,7 @@ const te = ["Added", "Changed"], re = ["OWP", "IPX"], ne = /^H{1,2}(?::m{1,2})?(
176
178
  ([r]) => r !== y
177
179
  )
178
180
  ) : e;
179
- }, "omitTreeGridSelectedInitialValue"), ve = /* @__PURE__ */ l((e, t) => {
181
+ }, "omitTreeGridSelectedInitialValue"), Ke = /* @__PURE__ */ l((e, t) => {
180
182
  const r = (t == null ? void 0 : t.insertPosition) ?? "top", n = t == null ? void 0 : t.parent, s = t == null ? void 0 : t.anchorRow;
181
183
  let a = n ?? (s ? s.parentNode : null) ?? e.GetFirst(), i = null;
182
184
  switch (r) {
@@ -194,11 +196,11 @@ const te = ["Added", "Changed"], re = ["OWP", "IPX"], ne = /^H{1,2}(?::m{1,2})?(
194
196
  break;
195
197
  }
196
198
  return { resolvedParent: a, next: i };
197
- }, "resolveRowInsertionTarget"), Fe = /* @__PURE__ */ l((e, t, r) => {
199
+ }, "resolveRowInsertionTarget"), $e = /* @__PURE__ */ l((e, t, r) => {
198
200
  if (!h(r))
199
201
  return;
200
202
  const n = r, s = Object.keys(n).filter(Boolean), a = t;
201
- a[$] = s, a[A] = Object.fromEntries(
203
+ a[$] = s, a[I] = Object.fromEntries(
202
204
  s.map((i) => [i, n[i]])
203
205
  ), Object.entries(n).forEach(([i, c]) => {
204
206
  var d, o;
@@ -208,56 +210,56 @@ const te = ["Added", "Changed"], re = ["OWP", "IPX"], ne = /^H{1,2}(?::m{1,2})?(
208
210
  }
209
211
  t[i] = c;
210
212
  });
211
- }, "assignInitialRowValues"), $e = /* @__PURE__ */ l((e, t, r) => {
212
- const n = I(r);
213
+ }, "assignInitialRowValues"), je = /* @__PURE__ */ l((e, t, r) => {
214
+ const n = _(r);
213
215
  if (!n.length)
214
216
  return;
215
- const s = t;
216
- n.forEach((a) => {
217
- var i;
218
- (i = e.Cols) != null && i[a] && (s[`${a}CanEdit`] = 1);
219
- });
220
- }, "assignEditableAddedRowColumns"), Ke = /* @__PURE__ */ l((e) => re.some((t) => e.startsWith(t)), "isTreeGridDataKey"), z = /* @__PURE__ */ l((e, t) => {
217
+ const s = t, a = [];
218
+ n.forEach((i) => {
219
+ var c;
220
+ (c = e.Cols) != null && c[i] && (s[`${i}CanEdit`] = 1, a.push(i));
221
+ }), a.length && (t[K] = a);
222
+ }, "assignEditableAddedRowColumns"), Oe = /* @__PURE__ */ l((e) => ne.some((t) => e.startsWith(t)), "isTreeGridDataKey"), k = /* @__PURE__ */ l((e, t) => {
221
223
  var r;
222
224
  return !!((r = e == null ? void 0 : e.Cols) != null && r[t]);
223
- }, "isTreeGridColumnDataKey"), je = /* @__PURE__ */ l((e) => e != null && e !== "", "hasTreeGridUploadValue"), Oe = /* @__PURE__ */ l((e) => e === 0 || e === !1 || e === "0", "isHiddenTreeGridValue"), b = /* @__PURE__ */ l((e, t) => {
225
+ }, "isTreeGridColumnDataKey"), xe = /* @__PURE__ */ l((e) => e != null && e !== "", "hasTreeGridUploadValue"), we = /* @__PURE__ */ l((e) => e === 0 || e === !1 || e === "0", "isHiddenTreeGridValue"), b = /* @__PURE__ */ l((e, t) => {
224
226
  var r, n;
225
- return !Oe((n = (r = e == null ? void 0 : e.Cols) == null ? void 0 : r[t]) == null ? void 0 : n.Visible);
226
- }, "isVisibleTreeGridColumn"), U = /* @__PURE__ */ l((e) => I(
227
+ return !we((n = (r = e == null ? void 0 : e.Cols) == null ? void 0 : r[t]) == null ? void 0 : n.Visible);
228
+ }, "isVisibleTreeGridColumn"), N = /* @__PURE__ */ l((e) => _(
227
229
  e == null ? void 0 : e[$]
228
- ), "getTreeGridAddedRowInitialValueKeys"), N = /* @__PURE__ */ l((e, t) => U(e).includes(t), "isTreeGridAddedRowInitialValueKey"), we = /* @__PURE__ */ l((e, t) => {
229
- const r = e == null ? void 0 : e[A];
230
+ ), "getTreeGridAddedRowInitialValueKeys"), P = /* @__PURE__ */ l((e, t) => N(e).includes(t), "isTreeGridAddedRowInitialValueKey"), qe = /* @__PURE__ */ l((e, t) => {
231
+ const r = e == null ? void 0 : e[I];
230
232
  return Object.prototype.hasOwnProperty.call(r ?? {}, t);
231
- }, "hasTreeGridAddedRowInitialValue"), xe = /* @__PURE__ */ l((e, t) => {
233
+ }, "hasTreeGridAddedRowInitialValue"), ze = /* @__PURE__ */ l((e, t) => {
232
234
  var r;
233
- return (r = e == null ? void 0 : e[A]) == null ? void 0 : r[t];
234
- }, "getTreeGridAddedRowInitialValue"), qe = /* @__PURE__ */ l((e, t) => {
235
+ return (r = e == null ? void 0 : e[I]) == null ? void 0 : r[t];
236
+ }, "getTreeGridAddedRowInitialValue"), He = /* @__PURE__ */ l((e, t) => {
235
237
  var r;
236
238
  return typeof t.id == "string" ? (r = e == null ? void 0 : e.Rows) == null ? void 0 : r[t.id] : null;
237
- }, "getLiveTreeGridChangedRow"), P = /* @__PURE__ */ l((e, t, r, n) => !n || !z(e, r) || b(e, r) ? !1 : N(t, r), "shouldUseTreeGridAddedRowInitialValue"), W = /* @__PURE__ */ l((e, t, r, n, s) => P(e, r, n, s) && we(r, n) ? xe(r, n) : t[n], "resolveTreeGridChangeDataValue"), He = /* @__PURE__ */ l((e, t, r, n = !1) => {
239
+ }, "getLiveTreeGridChangedRow"), W = /* @__PURE__ */ l((e, t, r, n) => !n || !k(e, r) || b(e, r) ? !1 : P(t, r), "shouldUseTreeGridAddedRowInitialValue"), Y = /* @__PURE__ */ l((e, t, r, n, s) => W(e, r, n, s) && qe(r, n) ? ze(r, n) : t[n], "resolveTreeGridChangeDataValue"), Ue = /* @__PURE__ */ l((e, t, r, n = !1) => {
238
240
  const s = L(Object.keys(e), ...t);
239
241
  return n ? L(
240
- [.../* @__PURE__ */ new Set([...s, ...U(r)])],
242
+ [.../* @__PURE__ */ new Set([...s, ...N(r)])],
241
243
  ...t
242
244
  ) : s;
243
245
  }, "getTreeGridChangeDataKeys"), ke = /* @__PURE__ */ l((e, t, r, n, s = !1) => {
244
- const a = P(
246
+ const a = W(
245
247
  e,
246
248
  r,
247
249
  n,
248
250
  s
249
- ), i = W(
251
+ ), i = Y(
250
252
  e,
251
253
  t,
252
254
  r,
253
255
  n,
254
256
  s
255
257
  );
256
- return !je(i) && !(a && i === "") ? !1 : z(e, n) ? !s || b(e, n) || a : Ke(n) ? !0 : N(r, n);
258
+ return !xe(i) && !(a && i === "") ? !1 : k(e, n) ? !s || b(e, n) || a : Oe(n) ? !0 : P(r, n);
257
259
  }, "shouldIncludeTreeGridChangeDataKey"), v = /* @__PURE__ */ l((e, t, r, n = !1, s = !1) => {
258
- const a = n ? qe(e, t) : null;
260
+ const a = n ? He(e, t) : null;
259
261
  return Object.fromEntries(
260
- He(t, r, a, n).filter(
262
+ Ue(t, r, a, n).filter(
261
263
  (i) => ke(
262
264
  e,
263
265
  t,
@@ -267,29 +269,29 @@ const te = ["Added", "Changed"], re = ["OWP", "IPX"], ne = /^H{1,2}(?::m{1,2})?(
267
269
  )
268
270
  ).map((i) => [
269
271
  i,
270
- W(e, t, a, i, s)
272
+ Y(e, t, a, i, s)
271
273
  ])
272
274
  );
273
- }, "normalizeTreeGridChangeRow"), ze = /* @__PURE__ */ l((e, t, r) => t.filter((n) => Z(n, r) === "1" && n.Deleted !== "1").map(
275
+ }, "normalizeTreeGridChangeRow"), Ne = /* @__PURE__ */ l((e, t, r) => t.filter((n) => ee(n, r) === "1" && n.Deleted !== "1").map(
274
276
  (n) => r === "Changed" ? v(e, n, ["id", "Changed"]) : v(e, n, ["id"], !0, !0)
275
- ).filter((n) => !ee(n)), "getChangedRowsByStatus"), Ue = /* @__PURE__ */ l((e, t) => e ? t.map((r) => {
277
+ ).filter((n) => !te(n)), "getChangedRowsByStatus"), Pe = /* @__PURE__ */ l((e, t) => e ? t.map((r) => {
276
278
  const n = typeof r.id == "string" ? e.Rows[r.id] : null;
277
279
  if (!n)
278
280
  return r;
279
281
  const s = { ...r };
280
282
  return Object.keys(r).forEach((a) => {
281
- x(e, n, a) && (s[a] = q(e, n, a));
283
+ q(e, n, a) && (s[a] = z(e, n, a));
282
284
  }), s;
283
- }) : t, "normalizeTreeGridChangedRows"), Ne = /* @__PURE__ */ l((e) => {
285
+ }) : t, "normalizeTreeGridChangedRows"), We = /* @__PURE__ */ l((e) => {
284
286
  var t;
285
287
  try {
286
288
  (t = e == null ? void 0 : e.EndEdit) == null || t.call(e, 1);
287
289
  } catch {
288
290
  }
289
- }, "commitTreeGridActiveEdit"), f = /* @__PURE__ */ l((e) => Grids[e], "getTreeGridById"), at = /* @__PURE__ */ l((e) => {
291
+ }, "commitTreeGridActiveEdit"), f = /* @__PURE__ */ l((e) => Grids[e], "getTreeGridById"), dt = /* @__PURE__ */ l((e) => {
290
292
  const t = f(e);
291
- return t ? H(t, he(t)) : [];
292
- }, "getTreeGridDataRowsById"), it = /* @__PURE__ */ l((e, t) => {
293
+ return t ? H(t, ye(t)) : [];
294
+ }, "getTreeGridDataRowsById"), ot = /* @__PURE__ */ l((e, t) => {
293
295
  const r = f(e);
294
296
  if (!r)
295
297
  return;
@@ -299,26 +301,26 @@ const te = ["Added", "Changed"], re = ["OWP", "IPX"], ne = /^H{1,2}(?::m{1,2})?(
299
301
  Data: { Body: [t || []] },
300
302
  Url: ""
301
303
  }, r.ReloadBody(), window.setTimeout(() => {
302
- _(e);
304
+ D(e);
303
305
  }, 0);
304
- }, "reloadTreeGridBodyById"), ct = /* @__PURE__ */ l((e, t) => {
306
+ }, "reloadTreeGridBodyById"), ut = /* @__PURE__ */ l((e, t) => {
305
307
  const r = f(e);
306
308
  if (!r)
307
309
  return;
308
- const n = t == null ? void 0 : t.canSelect, s = t == null ? void 0 : t.initialValues, a = t == null ? void 0 : t.editableColumns, i = Ve(r), c = !!n && i, d = c && Be(s), o = d ? Le(s) : s;
310
+ const n = t == null ? void 0 : t.canSelect, s = t == null ? void 0 : t.initialValues, a = t == null ? void 0 : t.editableColumns, i = Le(r), c = !!n && i, d = c && ve(s), o = d ? Fe(s) : s;
309
311
  c && V(e);
310
- const { resolvedParent: R, next: T } = ve(r, t), u = r.AddRow(R, T, 1);
311
- ae(u), Fe(r, u, o), Ge(r, u), u.CanEdit = 1, u.CanDelete = 1, u.CanSelect = n ? 1 : 0, $e(r, u, a), d && r.SelectRow(u, 1), r.Focus(u), r.RefreshRow(u), r.Calculate(1, 1), window.setTimeout(() => {
312
- _(e);
312
+ const { resolvedParent: R, next: T } = Ke(r, t), u = r.AddRow(R, T, 1);
313
+ ce(u), $e(r, u, o), Ce(r, u), u.CanEdit = 1, u.CanDelete = 1, u.CanSelect = n ? 1 : 0, je(r, u, a), d && r.SelectRow(u, 1), r.Focus(u), r.RefreshRow(u), r.Calculate(1, 1), window.setTimeout(() => {
314
+ D(e);
313
315
  }, 0);
314
- }, "addTreeGridRowById"), dt = /* @__PURE__ */ l((e, t) => {
316
+ }, "addTreeGridRowById"), ft = /* @__PURE__ */ l((e, t) => {
315
317
  const r = f(e);
316
318
  if (!r)
317
319
  return { valid: !1, errors: [] };
318
- const n = Te(r, t), s = [], a = t.refresh === !1 ? 0 : 1;
320
+ const n = Ge(r, t), s = [], a = t.refresh === !1 ? 0 : 1;
319
321
  n.forEach((c) => {
320
- _e(r, c, t).forEach((d) => {
321
- const o = d.key, R = O(r, c, o), T = De(r, d), u = {
322
+ Ae(r, c, t).forEach((d) => {
323
+ const o = d.key, R = x(r, c, o), T = Ie(r, d), u = {
322
324
  grid: r,
323
325
  row: c,
324
326
  col: o,
@@ -326,54 +328,54 @@ const te = ["Added", "Changed"], re = ["OWP", "IPX"], ne = /^H{1,2}(?::m{1,2})?(
326
328
  label: T,
327
329
  value: R
328
330
  };
329
- if (!Ie(R)) {
331
+ if (!be(R)) {
330
332
  r.SetAttribute(c, o, "Error", "", a);
331
333
  return;
332
334
  }
333
- const B = Ae(
335
+ const B = Se(
334
336
  u,
335
337
  d,
336
338
  t.messageFactory
337
- ), Y = { ...u, message: B };
338
- r.SetAttribute(c, o, "Error", B, a), s.push(Y);
339
+ ), p = { ...u, message: B };
340
+ r.SetAttribute(c, o, "Error", B, a), s.push(p);
339
341
  });
340
342
  });
341
343
  const i = s[0];
342
- return Se(r, i, t), {
344
+ return Ve(r, i, t), {
343
345
  valid: !i,
344
346
  errors: s,
345
347
  firstError: i
346
348
  };
347
- }, "validateTreeGridRequiredCellsById"), ot = /* @__PURE__ */ l((e) => {
349
+ }, "validateTreeGridRequiredCellsById"), Rt = /* @__PURE__ */ l((e) => {
348
350
  const t = f(e);
349
- Ne(t);
351
+ We(t);
350
352
  const r = Q(t == null ? void 0 : t.GetXmlData("changes,allcols,nogrid,noio"));
351
- return D(r) ? Object.fromEntries(
352
- te.map((n) => [
353
- J(n),
354
- ze(
353
+ return A(r) ? Object.fromEntries(
354
+ re.map((n) => [
355
+ Z(n),
356
+ Ne(
355
357
  t,
356
- Ue(t, r),
358
+ Pe(t, r),
357
359
  n
358
360
  )
359
361
  ])
360
362
  ) : { added: [], changed: [] };
361
- }, "getTreeGridRowChangesById"), ut = /* @__PURE__ */ l((e, t) => {
363
+ }, "getTreeGridRowChangesById"), Tt = /* @__PURE__ */ l((e, t) => {
362
364
  const r = f(e);
363
- r && me().then(
365
+ r && _e().then(
364
366
  (n) => n(r, { exportName: t ?? "" })
365
367
  );
366
- }, "exportTreeGridToExcelById"), ft = /* @__PURE__ */ l((e, t) => {
368
+ }, "exportTreeGridToExcelById"), Et = /* @__PURE__ */ l((e, t) => {
367
369
  const r = f(e), n = r == null ? void 0 : r.GetSelRows();
368
370
  if (!r || !n)
369
371
  return [];
370
- const s = g(
372
+ const s = J(
371
373
  r,
372
374
  n,
373
375
  t
374
376
  );
375
377
  return H(r, s);
376
- }, "getTreeGridSelectedRowsById"), Rt = /* @__PURE__ */ l((e, t) => {
378
+ }, "getTreeGridSelectedRowsById"), Gt = /* @__PURE__ */ l((e, t) => {
377
379
  const r = f(e);
378
380
  if (!r || !(t != null && t.targetKey))
379
381
  return;
@@ -383,28 +385,28 @@ const te = ["Added", "Changed"], re = ["OWP", "IPX"], ne = /^H{1,2}(?::m{1,2})?(
383
385
  return;
384
386
  }
385
387
  r.HideCol(n);
386
- }, "setTreeGridColumnVisibilityById"), Tt = /* @__PURE__ */ l((e, t) => {
388
+ }, "setTreeGridColumnVisibilityById"), Ct = /* @__PURE__ */ l((e, t) => {
387
389
  const r = f(e), n = t == null ? void 0 : t.row, s = t == null ? void 0 : t.col;
388
- !r || !n || !s || (Ee(r, n, s), r.SetValue(n, `${s}Class`, X), r.SetValue(n, `${s}Color`, t.backgroundColor ?? p), t.refresh !== !1 && r.RefreshCell(n, s));
389
- }, "highlightTreeGridCellById"), Gt = /* @__PURE__ */ l((e, t) => {
390
+ !r || !n || !s || (me(r, n, s), r.SetValue(n, `${s}Class`, X), r.SetValue(n, `${s}Color`, t.backgroundColor ?? g), t.refresh !== !1 && r.RefreshCell(n, s));
391
+ }, "highlightTreeGridCellById"), mt = /* @__PURE__ */ l((e, t) => {
390
392
  const r = f(e), n = t == null ? void 0 : t.row, s = t == null ? void 0 : t.col;
391
393
  if (!r || !n || !s)
392
394
  return;
393
- const a = Ce(n, s);
395
+ const a = he(n, s);
394
396
  r.SetValue(n, `${s}Class`, (a == null ? void 0 : a.className) ?? ""), r.SetValue(n, `${s}Color`, (a == null ? void 0 : a.color) ?? ""), r.RefreshCell(n, s);
395
397
  }, "clearTreeGridCellHighlightById"), V = /* @__PURE__ */ l((e) => {
396
398
  const t = f(e);
397
399
  t && t.ActionDeselectAll(1, 0);
398
- }, "resetTreeGridSelectionById"), Et = /* @__PURE__ */ l((e) => {
400
+ }, "resetTreeGridSelectionById"), ht = /* @__PURE__ */ l((e) => {
399
401
  e.forEach(V);
400
- }, "resetTreeGridSelectionsByIds"), Pe = /* @__PURE__ */ l((e) => {
402
+ }, "resetTreeGridSelectionsByIds"), Ye = /* @__PURE__ */ l((e) => {
401
403
  const t = f(e);
402
404
  t && (t.ActionUndoAll(1, 0), V(e), t.Calculate(1, 1), window.setTimeout(() => {
403
- _(e);
405
+ D(e);
404
406
  }, 0));
405
- }, "resetTreeGridChangesById"), Ct = /* @__PURE__ */ l((e) => {
406
- e.forEach(Pe);
407
- }, "resetTreeGridChangesByIds"), mt = /* @__PURE__ */ l((e, t, r, n, s) => {
407
+ }, "resetTreeGridChangesById"), _t = /* @__PURE__ */ l((e) => {
408
+ e.forEach(Ye);
409
+ }, "resetTreeGridChangesByIds"), yt = /* @__PURE__ */ l((e, t, r, n, s) => {
408
410
  if (!(r != null && r.length))
409
411
  return;
410
412
  const a = f(e);
@@ -418,31 +420,32 @@ const te = ["Added", "Changed"], re = ["OWP", "IPX"], ne = /^H{1,2}(?::m{1,2})?(
418
420
  }, "setTreeGridColumnEnumOptionsById");
419
421
  export {
420
422
  X as TREEGRID_CELL_CHANGED_CLASS,
421
- p as TREEGRID_CELL_HIGHLIGHT_COLOR,
422
- _t as TREEGRID_INPUT_CELL_COLOR,
423
- Dt as TREEGRID_WARNING_CELL_COLOR,
424
- ct as addTreeGridRowById,
425
- rt as appendTreeGridAddedRowHighlightColumn,
426
- Gt as clearTreeGridCellHighlightById,
427
- ut as exportTreeGridToExcelById,
428
- lt as getTreeGridAddedRowBaselineValue,
429
- st as getTreeGridAddedRowHighlightColumns,
423
+ g as TREEGRID_CELL_HIGHLIGHT_COLOR,
424
+ It as TREEGRID_INPUT_CELL_COLOR,
425
+ St as TREEGRID_WARNING_CELL_COLOR,
426
+ ut as addTreeGridRowById,
427
+ st as appendTreeGridAddedRowHighlightColumn,
428
+ mt as clearTreeGridCellHighlightById,
429
+ Tt as exportTreeGridToExcelById,
430
+ ct as getTreeGridAddedRowBaselineValue,
431
+ it as getTreeGridAddedRowEditableColumns,
432
+ at as getTreeGridAddedRowHighlightColumns,
430
433
  f as getTreeGridById,
431
- O as getTreeGridCellComparableValue,
432
- at as getTreeGridDataRowsById,
433
- ot as getTreeGridRowChangesById,
434
- ft as getTreeGridSelectedRowsById,
435
- Tt as highlightTreeGridCellById,
436
- ie as isTreeGridRowAddedById,
434
+ x as getTreeGridCellComparableValue,
435
+ dt as getTreeGridDataRowsById,
436
+ Rt as getTreeGridRowChangesById,
437
+ Et as getTreeGridSelectedRowsById,
438
+ Ct as highlightTreeGridCellById,
439
+ de as isTreeGridRowAddedById,
437
440
  H as normalizeTreeGridExternalRows,
438
- it as reloadTreeGridBodyById,
439
- nt as removeTreeGridAddedRowHighlightColumn,
440
- Pe as resetTreeGridChangesById,
441
- Ct as resetTreeGridChangesByIds,
441
+ ot as reloadTreeGridBodyById,
442
+ lt as removeTreeGridAddedRowHighlightColumn,
443
+ Ye as resetTreeGridChangesById,
444
+ _t as resetTreeGridChangesByIds,
442
445
  V as resetTreeGridSelectionById,
443
- Et as resetTreeGridSelectionsByIds,
444
- mt as setTreeGridColumnEnumOptionsById,
445
- Rt as setTreeGridColumnVisibilityById,
446
- dt as validateTreeGridRequiredCellsById
446
+ ht as resetTreeGridSelectionsByIds,
447
+ yt as setTreeGridColumnEnumOptionsById,
448
+ Gt as setTreeGridColumnVisibilityById,
449
+ ft as validateTreeGridRequiredCellsById
447
450
  };
448
451
  //# sourceMappingURL=treeGridUtil.js.map