@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.
- package/dist/_virtual/index10.js +2 -2
- package/dist/_virtual/index12.js +2 -2
- package/dist/_virtual/index13.js +2 -2
- package/dist/_virtual/index14.js +2 -2
- package/dist/_virtual/index15.js +2 -2
- package/dist/_virtual/index16.js +4 -4
- package/dist/_virtual/index17.js +4 -4
- package/dist/_virtual/index18.js +4 -4
- package/dist/_virtual/index19.js +4 -4
- package/dist/_virtual/index5.js +2 -2
- package/dist/components/OwpTreeGrid/internal/treeGridRuntime.js +455 -444
- package/dist/components/OwpTreeGrid/internal/treeGridRuntime.js.map +1 -1
- package/dist/layout/components/toggles/NavigationSearchToggle.js +3 -3
- package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/CODE128/index.js +1 -1
- package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/CODE39/index.js +1 -1
- package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/CODE93/index.js +1 -1
- package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/EAN_UPC/index.js +1 -1
- package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/GenericBarcode/index.js +1 -1
- package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/ITF/index.js +1 -1
- package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/MSI/index.js +1 -1
- package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/codabar/index.js +1 -1
- package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/pharmacode/index.js +1 -1
- package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/renderers/index.js +1 -1
- package/dist/node_modules/.pnpm/react-is@16.13.1/node_modules/react-is/index.js +1 -1
- 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
- package/dist/types/utils/treeGridUtil.d.ts +5 -0
- package/dist/utils/treeGridUtil.js +153 -150
- package/dist/utils/treeGridUtil.js.map +1 -1
- package/dist/utils.js +41 -40
- package/package.json +1 -1
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
var
|
|
2
|
-
var o = (e, n) =>
|
|
3
|
-
import { getTreeGridTextResourceUrl as
|
|
4
|
-
import { isTreeGridRowAddedById as
|
|
5
|
-
import { applyTreeGridLayoutToGrid as
|
|
6
|
-
import { resolveTreeGridSelectedRows as
|
|
7
|
-
import { TREE_GRID_PANEL_CHECKBOX_SELECT_CLASS as In, TREE_GRID_SELECT_ALL_CHECKED_CLASS as
|
|
8
|
-
import { countTreeGridPerf as
|
|
1
|
+
var Rn = Object.defineProperty;
|
|
2
|
+
var o = (e, n) => Rn(e, "name", { value: n, configurable: !0 });
|
|
3
|
+
import { getTreeGridTextResourceUrl as An, TREEGRID_CELL_CHANGED_CLASS as Xe, TREEGRID_ADDED_ROW_BACKGROUND_COLOR as gn } from "../../../constants/treeGrid.js";
|
|
4
|
+
import { isTreeGridRowAddedById as I, getTreeGridAddedRowHighlightColumns as q, getTreeGridAddedRowEditableColumns as _e, getTreeGridCellComparableValue as ue, clearTreeGridCellHighlightById as We, highlightTreeGridCellById as Je, normalizeTreeGridExternalRows as _n, getTreeGridAddedRowBaselineValue as mn, removeTreeGridAddedRowHighlightColumn as Ln, appendTreeGridAddedRowHighlightColumn as On } from "../../../utils/treeGridUtil.js";
|
|
5
|
+
import { applyTreeGridLayoutToGrid as xn } from "./treeGridLayout.js";
|
|
6
|
+
import { resolveTreeGridSelectedRows as bn } from "./treeGridSelection.js";
|
|
7
|
+
import { TREE_GRID_PANEL_CHECKBOX_SELECT_CLASS as In, TREE_GRID_SELECT_ALL_CHECKED_CLASS as me, TREE_GRID_SELECT_ALL_INDETERMINATE_CLASS as Le, TREE_GRID_SELECT_ALL_UNCHECKED_CLASS as Oe, TREE_GRID_SELECTED_CHANGED_CELL_CLASS as xe, TREE_GRID_THEME_WRAPPER_CLASS as wn, TREE_GRID_ADDED_ROW_BOX_CELL_CLASS as Dn, TREE_GRID_ERROR_CELL_CLASS as yn, TREE_GRID_ADDED_ROW_BOX_START_CLASS as Pn, TREE_GRID_ADDED_ROW_BOX_END_CLASS as $n } from "./treeGridTheme.js";
|
|
8
|
+
import { countTreeGridPerf as Ke, logTreeGridPerf as vn, measureTreeGridPerf as je } from "./utils/perf.js";
|
|
9
9
|
import { debounce as Y } from "../../../node_modules/.pnpm/es-toolkit@1.39.10/node_modules/es-toolkit/dist/compat/function/debounce.js";
|
|
10
|
-
import { isEmpty as
|
|
10
|
+
import { isEmpty as Bn } from "../../../node_modules/.pnpm/es-toolkit@1.39.10/node_modules/es-toolkit/dist/compat/predicate/isEmpty.js";
|
|
11
11
|
import { get as Fn } from "../../../node_modules/.pnpm/es-toolkit@1.39.10/node_modules/es-toolkit/dist/compat/object/get.js";
|
|
12
|
-
const
|
|
12
|
+
const Pr = 300, Nn = 3, kn = {
|
|
13
13
|
1: {
|
|
14
14
|
onEnter: "TabDownEdit",
|
|
15
15
|
onEnterEdit: "AcceptEdit AND TabDownEdit,1"
|
|
@@ -26,37 +26,37 @@ const yr = 300, Bn = 3, Nn = {
|
|
|
26
26
|
onEnter: "TabRightEditAdd",
|
|
27
27
|
onEnterEdit: "AcceptEdit AND TabRightEditAdd,1"
|
|
28
28
|
}
|
|
29
|
-
},
|
|
29
|
+
}, Un = [240, 240, 240], Vn = [248, 248, 248], Mn = [255, 255, 255], Xn = [255, 255, 254], Wn = [242, 242, 242], Jn = [
|
|
30
30
|
[255, 210, 210],
|
|
31
31
|
[249, 209, 209],
|
|
32
32
|
[115, 16, 11]
|
|
33
|
-
],
|
|
33
|
+
], Kn = "transparent", be = "Button", jn = /* @__PURE__ */ new Set(["Panel"]), Ie = Xe.split(/\s+/).filter(
|
|
34
34
|
Boolean
|
|
35
|
-
),
|
|
35
|
+
), Hn = /* @__PURE__ */ new Set([
|
|
36
36
|
"Text",
|
|
37
37
|
"Lines",
|
|
38
38
|
"Int",
|
|
39
39
|
"Float",
|
|
40
40
|
"Date",
|
|
41
41
|
"Pass"
|
|
42
|
-
]), we = /* @__PURE__ */ o((e) => !!(e && /\b(?:EnterMode|OnEnterEdit|OnEnter)\s*[:=]/.test(e)), "hasTreeGridExplicitEnterMode"),
|
|
42
|
+
]), we = /* @__PURE__ */ o((e) => !!(e && /\b(?:EnterMode|OnEnterEdit|OnEnter)\s*[:=]/.test(e)), "hasTreeGridExplicitEnterMode"), zn = {
|
|
43
43
|
Visible: "1",
|
|
44
44
|
CanHide: "0",
|
|
45
45
|
Delete: "1",
|
|
46
46
|
Width: "33"
|
|
47
|
-
},
|
|
47
|
+
}, Yn = {
|
|
48
48
|
Spanned: "1"
|
|
49
49
|
}, W = {
|
|
50
50
|
OnClickCell: "Focus"
|
|
51
51
|
}, J = {
|
|
52
52
|
OnClickPanelSelectAll: "SelectAll OR DeselectAll"
|
|
53
|
-
},
|
|
53
|
+
}, He = "Panel", ze = ["Formula", "FormulaFormula"], Zn = /<Grid\b[^>]*>/i, qn = /<\/Grid\s*>/i, Qn = /<Toolbar\b[^>]*\/?>/i, et = [
|
|
54
54
|
"Undo",
|
|
55
55
|
"Deleting",
|
|
56
56
|
"Selecting",
|
|
57
57
|
"SelectingSingle",
|
|
58
58
|
"SuppressCfg"
|
|
59
|
-
],
|
|
59
|
+
], nt = {
|
|
60
60
|
addRow: ["Add", "AddRows", "AddChildren", "AddRowsChildren"],
|
|
61
61
|
deleteRow: [
|
|
62
62
|
"Delete",
|
|
@@ -77,28 +77,28 @@ const yr = 300, Bn = 3, Nn = {
|
|
|
77
77
|
"UndeleteVisibleRowsChildren"
|
|
78
78
|
],
|
|
79
79
|
selectRow: ["Select", "SelectRows", "Deselect", "DeselectRows"]
|
|
80
|
-
}, Q = /* @__PURE__ */ new WeakMap(),
|
|
80
|
+
}, Q = /* @__PURE__ */ new WeakMap(), g = /* @__PURE__ */ o((e) => typeof e == "object" && e !== null && !Array.isArray(e), "isTreeGridJsonRecord"), y = /* @__PURE__ */ o((e) => e === 0 || e === !1 || e === "0" || e === "false", "isTreeGridDisabledConfigValue"), ee = /* @__PURE__ */ o((e) => e === 1 || e === !0 || e === "1" || e === "true", "isTreeGridExplicitEnabledConfigValue"), tt = /* @__PURE__ */ o((e) => e === 1 || e === !0 || e === "1" || e === "true", "isTreeGridExplicitHiddenConfigValue"), N = /* @__PURE__ */ o((e, n) => String(e ?? "").trim().toLowerCase() === n.toLowerCase(), "isTreeGridConfigValue"), fe = /* @__PURE__ */ o((e, n) => !y(e) && !ee(n), "isTreeGridCheckboxSelectionMode"), Ye = /* @__PURE__ */ o((e) => {
|
|
81
81
|
const n = e.Cfg;
|
|
82
|
-
return Array.isArray(n) ? n.filter(
|
|
82
|
+
return Array.isArray(n) ? n.filter(g) : g(n) ? [n] : [];
|
|
83
83
|
}, "getTreeGridJsonCfgRecords"), ne = /* @__PURE__ */ o((e, n) => {
|
|
84
84
|
let t;
|
|
85
|
-
return
|
|
85
|
+
return Ye(e).forEach((r) => {
|
|
86
86
|
n in r && (t = r[n]);
|
|
87
87
|
}), t;
|
|
88
|
-
}, "getTreeGridJsonCfgValue"),
|
|
88
|
+
}, "getTreeGridJsonCfgValue"), Ze = /* @__PURE__ */ o((e, n) => {
|
|
89
89
|
const t = new RegExp(`\\b${n}\\s*=\\s*(['"])(.*?)\\1`, "i").exec(
|
|
90
90
|
e
|
|
91
91
|
);
|
|
92
92
|
return t == null ? void 0 : t[2];
|
|
93
|
-
}, "getTreeGridXmlTagAttributeValue"),
|
|
93
|
+
}, "getTreeGridXmlTagAttributeValue"), F = /* @__PURE__ */ o((e, n) => new RegExp(`\\b${n}\\s*=`, "i").test(e), "hasTreeGridXmlTagAttribute"), qe = /* @__PURE__ */ o((e) => String(e).replace(/&/g, "&").replace(/"/g, """).replace(/</g, "<"), "escapeTreeGridXmlAttributeValue"), k = /* @__PURE__ */ o((e, n, t) => {
|
|
94
94
|
const r = e.endsWith("/>") ? e.length - 2 : e.length - 1;
|
|
95
|
-
return `${e.slice(0, r)} ${n}="${
|
|
95
|
+
return `${e.slice(0, r)} ${n}="${qe(
|
|
96
96
|
t
|
|
97
97
|
)}"${e.slice(r)}`;
|
|
98
|
-
}, "appendTreeGridXmlTagAttribute"), te = /* @__PURE__ */ o((e, n, t) =>
|
|
98
|
+
}, "appendTreeGridXmlTagAttribute"), te = /* @__PURE__ */ o((e, n, t) => F(e, n) ? e.replace(
|
|
99
99
|
new RegExp(`\\b${n}\\s*=\\s*(['"])(.*?)\\1`, "i"),
|
|
100
|
-
() => `${n}="${
|
|
101
|
-
) : k(e, n, t), "setTreeGridXmlTagAttribute"),
|
|
100
|
+
() => `${n}="${qe(t)}"`
|
|
101
|
+
) : k(e, n, t), "setTreeGridXmlTagAttribute"), Qe = /* @__PURE__ */ o((e, n) => {
|
|
102
102
|
let t = e;
|
|
103
103
|
return Object.entries(n).forEach(([r, i]) => {
|
|
104
104
|
t = te(t, r, i);
|
|
@@ -106,51 +106,51 @@ const yr = 300, Bn = 3, Nn = {
|
|
|
106
106
|
}, "setTreeGridXmlTagAttributes"), j = /* @__PURE__ */ o((e, n) => {
|
|
107
107
|
let t = e;
|
|
108
108
|
return Object.entries(n).forEach(([r, i]) => {
|
|
109
|
-
|
|
109
|
+
F(t, r) || (t = k(t, r, i));
|
|
110
110
|
}), t;
|
|
111
|
-
}, "appendMissingTreeGridXmlTagAttributes"),
|
|
112
|
-
var
|
|
111
|
+
}, "appendMissingTreeGridXmlTagAttributes"), b = /* @__PURE__ */ o((e) => {
|
|
112
|
+
var a;
|
|
113
113
|
const n = /<!--[\s\S]*?-->|<\?[\s\S]*?\?>|<!\[CDATA\[[\s\S]*?\]\]>|<\/?([A-Za-z][\w:-]*)\b[^>]*>/g, t = {
|
|
114
114
|
cfgValues: {}
|
|
115
115
|
};
|
|
116
116
|
let r, i = 0, c = !1;
|
|
117
117
|
for (; r = n.exec(e); ) {
|
|
118
|
-
const
|
|
119
|
-
if (!C ||
|
|
118
|
+
const f = r[0], C = (a = r[1]) == null ? void 0 : a.toLowerCase();
|
|
119
|
+
if (!C || f.startsWith("<!--") || f.startsWith("<?") || f.startsWith("<!"))
|
|
120
120
|
continue;
|
|
121
|
-
!t.hasFastPanel &&
|
|
122
|
-
const
|
|
121
|
+
!t.hasFastPanel && F(f, "FastPanel") && (t.hasFastPanel = !0);
|
|
122
|
+
const p = f.startsWith("</"), S = /\/>\s*$/.test(f);
|
|
123
123
|
if (!c) {
|
|
124
|
-
!
|
|
124
|
+
!p && C === "grid" && (c = !0, t.gridOpenTagEndIndex = r.index + f.length, i = S ? 0 : 1);
|
|
125
125
|
continue;
|
|
126
126
|
}
|
|
127
|
-
if (
|
|
127
|
+
if (p) {
|
|
128
128
|
if (i = Math.max(0, i - 1), C === "grid" && i === 0)
|
|
129
129
|
break;
|
|
130
130
|
continue;
|
|
131
131
|
}
|
|
132
132
|
i === 1 && (C === "cfg" ? (t.defaultCfgTag || (t.defaultCfgTag = {
|
|
133
133
|
index: r.index,
|
|
134
|
-
tag:
|
|
135
|
-
}),
|
|
136
|
-
const m =
|
|
137
|
-
m !== void 0 && (t.cfgValues[
|
|
138
|
-
}), t.lastCfgEndIndex = r.index +
|
|
134
|
+
tag: f
|
|
135
|
+
}), et.forEach((R) => {
|
|
136
|
+
const m = Ze(f, R);
|
|
137
|
+
m !== void 0 && (t.cfgValues[R] = m);
|
|
138
|
+
}), t.lastCfgEndIndex = r.index + f.length) : C === "actions" && !t.defaultActionsTag ? t.defaultActionsTag = {
|
|
139
139
|
index: r.index,
|
|
140
|
-
tag:
|
|
141
|
-
} : C === "panel" && !t.defaultPanelTag &&
|
|
140
|
+
tag: f
|
|
141
|
+
} : C === "panel" && !t.defaultPanelTag && rt(f) ? t.defaultPanelTag = {
|
|
142
142
|
index: r.index,
|
|
143
|
-
tag:
|
|
143
|
+
tag: f
|
|
144
144
|
} : C === "animations" && !t.animationsTag && (t.animationsTag = {
|
|
145
145
|
index: r.index,
|
|
146
|
-
tag:
|
|
146
|
+
tag: f
|
|
147
147
|
})), S || (i += 1);
|
|
148
148
|
}
|
|
149
149
|
return t;
|
|
150
|
-
}, "scanTreeGridXmlDefaultLayout"),
|
|
151
|
-
const n =
|
|
150
|
+
}, "scanTreeGridXmlDefaultLayout"), rt = /* @__PURE__ */ o((e) => {
|
|
151
|
+
const n = Ze(e, "Name");
|
|
152
152
|
return n === void 0 || n === "" || n.toLowerCase() === "panel";
|
|
153
|
-
}, "isTreeGridXmlDefaultPanelTag"),
|
|
153
|
+
}, "isTreeGridXmlDefaultPanelTag"), it = /* @__PURE__ */ o((e) => {
|
|
154
154
|
const n = /<([A-Za-z][\w:-]*)\b[^>]*(?:\/>|>)/g, t = [];
|
|
155
155
|
let r;
|
|
156
156
|
for (; r = n.exec(e); ) {
|
|
@@ -165,21 +165,21 @@ const yr = 300, Bn = 3, Nn = {
|
|
|
165
165
|
});
|
|
166
166
|
}
|
|
167
167
|
return t;
|
|
168
|
-
}, "getLeadingTreeGridXmlHeaderTags"),
|
|
169
|
-
const n =
|
|
168
|
+
}, "getLeadingTreeGridXmlHeaderTags"), ot = /* @__PURE__ */ o((e) => {
|
|
169
|
+
const n = it(e);
|
|
170
170
|
if (n.length <= 1)
|
|
171
171
|
return {
|
|
172
172
|
headContent: e,
|
|
173
173
|
isApplied: !1
|
|
174
174
|
};
|
|
175
175
|
const [t, ...r] = n;
|
|
176
|
-
if (
|
|
176
|
+
if (F(t.tag, "PanelRowSpan") || r.some(({ tag: c }) => /\bPanel[A-Za-z0-9_]*\s*=/i.test(c)))
|
|
177
177
|
return {
|
|
178
178
|
headContent: e,
|
|
179
179
|
isApplied: !1
|
|
180
180
|
};
|
|
181
181
|
let i = t.tag;
|
|
182
|
-
return
|
|
182
|
+
return F(i, "Spanned") || (i = k(i, "Spanned", 1)), i = k(
|
|
183
183
|
i,
|
|
184
184
|
"PanelRowSpan",
|
|
185
185
|
n.length
|
|
@@ -189,47 +189,47 @@ const yr = 300, Bn = 3, Nn = {
|
|
|
189
189
|
)}`,
|
|
190
190
|
isApplied: !0
|
|
191
191
|
};
|
|
192
|
-
}, "applyTreeGridXmlHeadPanelRowSpanDefault"),
|
|
193
|
-
if (n.gridOpenTagEndIndex === void 0 || !
|
|
192
|
+
}, "applyTreeGridXmlHeadPanelRowSpanDefault"), st = /* @__PURE__ */ o((e) => e.lastCfgEndIndex ?? e.gridOpenTagEndIndex, "getTreeGridXmlPanelSpannedInsertionIndex"), ct = /* @__PURE__ */ o((e) => !!e.defaultPanelTag || tn(e.cfgValues) || rn(e.cfgValues), "isTreeGridXmlPanelSpannedDefaultLayout"), lt = /* @__PURE__ */ o((e, n) => {
|
|
193
|
+
if (n.gridOpenTagEndIndex === void 0 || !ct(n))
|
|
194
194
|
return e;
|
|
195
195
|
const t = n.defaultPanelTag;
|
|
196
196
|
if (t) {
|
|
197
197
|
const i = j(
|
|
198
198
|
t.tag,
|
|
199
|
-
|
|
199
|
+
Yn
|
|
200
200
|
);
|
|
201
201
|
return i === t.tag ? e : `${e.slice(0, t.index)}${i}${e.slice(
|
|
202
202
|
t.index + t.tag.length
|
|
203
203
|
)}`;
|
|
204
204
|
}
|
|
205
|
-
const r =
|
|
205
|
+
const r = st(n);
|
|
206
206
|
return r === void 0 ? e : `${e.slice(0, r)}
|
|
207
207
|
<Panel Spanned="1" />${e.slice(
|
|
208
208
|
r
|
|
209
209
|
)}`;
|
|
210
|
-
}, "applyTreeGridXmlDefaultPanelSpannedLayout"),
|
|
210
|
+
}, "applyTreeGridXmlDefaultPanelSpannedLayout"), dt = /* @__PURE__ */ o((e) => {
|
|
211
211
|
if (!/<Head\b/i.test(e) || /\bPanelRowSpan\s*[:=]/i.test(e))
|
|
212
212
|
return e;
|
|
213
213
|
let n = !1;
|
|
214
214
|
const t = e.replace(
|
|
215
215
|
/(<Head\b[^>]*>)([\s\S]*?)(<\/Head>)/i,
|
|
216
|
-
(r, i, c,
|
|
217
|
-
const
|
|
218
|
-
return
|
|
216
|
+
(r, i, c, a) => {
|
|
217
|
+
const f = ot(c);
|
|
218
|
+
return f.isApplied ? (n = !0, `${i}${f.headContent}${a}`) : r;
|
|
219
219
|
}
|
|
220
220
|
);
|
|
221
|
-
return n ?
|
|
221
|
+
return n ? lt(
|
|
222
222
|
t,
|
|
223
|
-
|
|
223
|
+
b(t)
|
|
224
224
|
) : e;
|
|
225
|
-
}, "applyTreeGridDefaultHeaderPanelRowSpanLayout"),
|
|
225
|
+
}, "applyTreeGridDefaultHeaderPanelRowSpanLayout"), en = /* @__PURE__ */ o((e) => fe(
|
|
226
226
|
ne(e, "Selecting"),
|
|
227
227
|
ne(e, "SelectingSingle")
|
|
228
|
-
), "isTreeGridJsonCheckboxSelectionLayout"),
|
|
228
|
+
), "isTreeGridJsonCheckboxSelectionLayout"), nn = /* @__PURE__ */ o((e) => fe(
|
|
229
229
|
e.Selecting,
|
|
230
230
|
e.SelectingSingle
|
|
231
|
-
), "isTreeGridXmlCheckboxSelectionLayout"),
|
|
232
|
-
if (n.gridOpenTagEndIndex === void 0 || !
|
|
231
|
+
), "isTreeGridXmlCheckboxSelectionLayout"), tn = /* @__PURE__ */ o((e) => !y(e.Selecting), "isTreeGridXmlSelectingLayout"), rn = /* @__PURE__ */ o((e) => N(e.Undo, "1") && N(e.Deleting, "2") && N(e.Selecting, "0"), "isTreeGridXmlDeletePanelDefaultLayout"), ut = /* @__PURE__ */ o((e) => e.lastCfgEndIndex ?? e.gridOpenTagEndIndex, "getTreeGridXmlCellClickActionInsertionIndex"), ft = /* @__PURE__ */ o((e, n) => {
|
|
232
|
+
if (n.gridOpenTagEndIndex === void 0 || !tn(n.cfgValues) || /\bOnClickCell\s*=/i.test(e))
|
|
233
233
|
return e;
|
|
234
234
|
const t = n.defaultActionsTag;
|
|
235
235
|
if (t) {
|
|
@@ -241,13 +241,13 @@ const yr = 300, Bn = 3, Nn = {
|
|
|
241
241
|
t.index + t.tag.length
|
|
242
242
|
)}`;
|
|
243
243
|
}
|
|
244
|
-
const r =
|
|
244
|
+
const r = ut(n);
|
|
245
245
|
return r === void 0 ? e : `${e.slice(0, r)}
|
|
246
246
|
<Actions OnClickCell="Focus" />${e.slice(
|
|
247
247
|
r
|
|
248
248
|
)}`;
|
|
249
|
-
}, "applyTreeGridXmlDefaultCellClickActionLayout"),
|
|
250
|
-
if (n.gridOpenTagEndIndex === void 0 || !
|
|
249
|
+
}, "applyTreeGridXmlDefaultCellClickActionLayout"), at = /* @__PURE__ */ o((e) => e.lastCfgEndIndex ?? e.gridOpenTagEndIndex, "getTreeGridXmlSelectAllPanelActionInsertionIndex"), Tt = /* @__PURE__ */ o((e, n) => {
|
|
250
|
+
if (n.gridOpenTagEndIndex === void 0 || !nn(n.cfgValues) || /\bOnClickPanelSelectAll\s*=/i.test(e))
|
|
251
251
|
return e;
|
|
252
252
|
const t = n.defaultActionsTag;
|
|
253
253
|
if (t) {
|
|
@@ -259,7 +259,7 @@ const yr = 300, Bn = 3, Nn = {
|
|
|
259
259
|
t.index + t.tag.length
|
|
260
260
|
)}`;
|
|
261
261
|
}
|
|
262
|
-
const r =
|
|
262
|
+
const r = at(n);
|
|
263
263
|
return r === void 0 ? e : `${e.slice(
|
|
264
264
|
0,
|
|
265
265
|
r
|
|
@@ -267,26 +267,26 @@ const yr = 300, Bn = 3, Nn = {
|
|
|
267
267
|
<Actions OnClickPanelSelectAll="SelectAll OR DeselectAll" />${e.slice(
|
|
268
268
|
r
|
|
269
269
|
)}`;
|
|
270
|
-
}, "applyTreeGridXmlDefaultSelectAllPanelActionLayout"),
|
|
271
|
-
if (n.gridOpenTagEndIndex === void 0 || !
|
|
270
|
+
}, "applyTreeGridXmlDefaultSelectAllPanelActionLayout"), Ct = /* @__PURE__ */ o((e) => e.lastCfgEndIndex ?? e.gridOpenTagEndIndex, "getTreeGridXmlDeletePanelInsertionIndex"), Et = /* @__PURE__ */ o((e, n) => {
|
|
271
|
+
if (n.gridOpenTagEndIndex === void 0 || !rn(n.cfgValues))
|
|
272
272
|
return e;
|
|
273
273
|
const t = n.defaultPanelTag;
|
|
274
274
|
if (t) {
|
|
275
275
|
const c = j(
|
|
276
276
|
t.tag,
|
|
277
|
-
|
|
277
|
+
zn
|
|
278
278
|
);
|
|
279
279
|
return c === t.tag ? e : `${e.slice(0, t.index)}${c}${e.slice(
|
|
280
280
|
t.index + t.tag.length
|
|
281
281
|
)}`;
|
|
282
282
|
}
|
|
283
|
-
const r =
|
|
283
|
+
const r = Ct(n);
|
|
284
284
|
return r === void 0 ? e : `${e.slice(0, r)}
|
|
285
285
|
<Panel Visible="1" CanHide="0" Delete="1" Width="33" />${e.slice(
|
|
286
286
|
r
|
|
287
287
|
)}`;
|
|
288
|
-
}, "applyTreeGridXmlDefaultDeletePanelLayout"),
|
|
289
|
-
if (n.hasFastPanel || !
|
|
288
|
+
}, "applyTreeGridXmlDefaultDeletePanelLayout"), Gt = /* @__PURE__ */ o((e, n) => {
|
|
289
|
+
if (n.hasFastPanel || !nn(n.cfgValues))
|
|
290
290
|
return e;
|
|
291
291
|
const t = n.gridOpenTagEndIndex;
|
|
292
292
|
return t === void 0 ? e : `${e.slice(0, t)}
|
|
@@ -296,77 +296,77 @@ const yr = 300, Bn = 3, Nn = {
|
|
|
296
296
|
}, "applyTreeGridXmlDefaultFastPanelLayout"), pt = /* @__PURE__ */ o((e) => {
|
|
297
297
|
const n = e.Cfg;
|
|
298
298
|
if (Array.isArray(n)) {
|
|
299
|
-
n.some((t) =>
|
|
299
|
+
n.some((t) => g(t) && "FastPanel" in t) || (e.Cfg = [{ FastPanel: 0 }, ...n]);
|
|
300
300
|
return;
|
|
301
301
|
}
|
|
302
|
-
if (
|
|
302
|
+
if (g(n)) {
|
|
303
303
|
"FastPanel" in n || (n.FastPanel = 0);
|
|
304
304
|
return;
|
|
305
305
|
}
|
|
306
306
|
e.Cfg = { FastPanel: 0 };
|
|
307
|
-
}, "applyTreeGridJsonFastPanelDefault"),
|
|
307
|
+
}, "applyTreeGridJsonFastPanelDefault"), St = /* @__PURE__ */ o((e) => {
|
|
308
308
|
const n = e.Actions;
|
|
309
309
|
if (Array.isArray(n)) {
|
|
310
310
|
n.some(
|
|
311
|
-
(t) =>
|
|
311
|
+
(t) => g(t) && "OnClickPanelSelectAll" in t
|
|
312
312
|
) || (e.Actions = [{ ...J }, ...n]);
|
|
313
313
|
return;
|
|
314
314
|
}
|
|
315
|
-
if (
|
|
315
|
+
if (g(n)) {
|
|
316
316
|
"OnClickPanelSelectAll" in n || (n.OnClickPanelSelectAll = J.OnClickPanelSelectAll);
|
|
317
317
|
return;
|
|
318
318
|
}
|
|
319
319
|
n === void 0 && (e.Actions = { ...J });
|
|
320
|
-
}, "applyTreeGridJsonSelectAllPanelActionDefault"),
|
|
320
|
+
}, "applyTreeGridJsonSelectAllPanelActionDefault"), ht = /* @__PURE__ */ o((e) => {
|
|
321
321
|
const n = e.Actions;
|
|
322
322
|
if (Array.isArray(n)) {
|
|
323
|
-
n.some((t) =>
|
|
323
|
+
n.some((t) => g(t) && "OnClickCell" in t) || (e.Actions = [{ ...W }, ...n]);
|
|
324
324
|
return;
|
|
325
325
|
}
|
|
326
|
-
if (
|
|
326
|
+
if (g(n)) {
|
|
327
327
|
"OnClickCell" in n || (n.OnClickCell = W.OnClickCell);
|
|
328
328
|
return;
|
|
329
329
|
}
|
|
330
330
|
n === void 0 && (e.Actions = { ...W });
|
|
331
|
-
}, "applyTreeGridJsonCellClickActionDefault"),
|
|
331
|
+
}, "applyTreeGridJsonCellClickActionDefault"), Rt = /* @__PURE__ */ o((e) => {
|
|
332
332
|
try {
|
|
333
333
|
const n = JSON.parse(e);
|
|
334
|
-
return !
|
|
334
|
+
return !g(n) || y(ne(n, "Selecting")) ? e : (ht(n), JSON.stringify(n));
|
|
335
335
|
} catch {
|
|
336
336
|
return e;
|
|
337
337
|
}
|
|
338
|
-
}, "applyTreeGridJsonDefaultCellClickActionLayout"),
|
|
338
|
+
}, "applyTreeGridJsonDefaultCellClickActionLayout"), De = /* @__PURE__ */ o((e, n) => {
|
|
339
339
|
const t = e.trim();
|
|
340
|
-
return t ? t.startsWith("{") ?
|
|
340
|
+
return t ? t.startsWith("{") ? Rt(e) : ft(
|
|
341
341
|
e,
|
|
342
|
-
n ??
|
|
342
|
+
n ?? b(e)
|
|
343
343
|
) : e;
|
|
344
|
-
}, "applyTreeGridDefaultCellClickActionLayout"),
|
|
344
|
+
}, "applyTreeGridDefaultCellClickActionLayout"), At = /* @__PURE__ */ o((e) => {
|
|
345
345
|
try {
|
|
346
346
|
const n = JSON.parse(e);
|
|
347
|
-
return !
|
|
347
|
+
return !g(n) || !en(n) ? e : (St(n), JSON.stringify(n));
|
|
348
348
|
} catch {
|
|
349
349
|
return e;
|
|
350
350
|
}
|
|
351
|
-
}, "applyTreeGridJsonDefaultSelectAllPanelActionLayout"),
|
|
351
|
+
}, "applyTreeGridJsonDefaultSelectAllPanelActionLayout"), ye = /* @__PURE__ */ o((e, n) => {
|
|
352
352
|
const t = e.trim();
|
|
353
|
-
return t ? t.startsWith("{") ?
|
|
353
|
+
return t ? t.startsWith("{") ? At(e) : Tt(
|
|
354
354
|
e,
|
|
355
|
-
n ??
|
|
355
|
+
n ?? b(e)
|
|
356
356
|
) : e;
|
|
357
|
-
}, "applyTreeGridDefaultSelectAllPanelActionLayout"),
|
|
357
|
+
}, "applyTreeGridDefaultSelectAllPanelActionLayout"), gt = /* @__PURE__ */ o((e, n) => {
|
|
358
358
|
if (n === void 0)
|
|
359
359
|
return e;
|
|
360
360
|
try {
|
|
361
361
|
const t = JSON.parse(e);
|
|
362
|
-
if (!
|
|
362
|
+
if (!g(t))
|
|
363
363
|
return e;
|
|
364
|
-
const r =
|
|
364
|
+
const r = Ye(t);
|
|
365
365
|
return r.some((i) => "SuppressCfg" in i) ? e : (r[0] ? r[0].SuppressCfg = n : t.Cfg = { SuppressCfg: n }, JSON.stringify(t));
|
|
366
366
|
} catch {
|
|
367
367
|
return e;
|
|
368
368
|
}
|
|
369
|
-
}, "applyTreeGridJsonDefaultSuppressCfgLayout"),
|
|
369
|
+
}, "applyTreeGridJsonDefaultSuppressCfgLayout"), _t = /* @__PURE__ */ o((e, n, t) => {
|
|
370
370
|
if (t === void 0 || n.cfgValues.SuppressCfg !== void 0)
|
|
371
371
|
return e;
|
|
372
372
|
const r = n.defaultCfgTag;
|
|
@@ -381,60 +381,60 @@ const yr = 300, Bn = 3, Nn = {
|
|
|
381
381
|
<Cfg SuppressCfg="${t}" />${e.slice(
|
|
382
382
|
i
|
|
383
383
|
)}`;
|
|
384
|
-
}, "applyTreeGridXmlDefaultSuppressCfgLayout"),
|
|
384
|
+
}, "applyTreeGridXmlDefaultSuppressCfgLayout"), mt = /* @__PURE__ */ o((e, n) => {
|
|
385
385
|
const t = e.trim();
|
|
386
|
-
return n === void 0 || !t ? e : t.startsWith("{") ?
|
|
386
|
+
return n === void 0 || !t ? e : t.startsWith("{") ? gt(e, n) : _t(
|
|
387
387
|
e,
|
|
388
|
-
|
|
388
|
+
b(e),
|
|
389
389
|
n
|
|
390
390
|
);
|
|
391
|
-
}, "applyTreeGridDefaultSuppressCfgLayout"),
|
|
392
|
-
const n = e.Toolbar, t = e.Solid, r = Array.isArray(n) ? n.filter(
|
|
393
|
-
(c) =>
|
|
394
|
-
) :
|
|
391
|
+
}, "applyTreeGridDefaultSuppressCfgLayout"), Lt = /* @__PURE__ */ o((e) => ze.some((n) => n in e), "hasTreeGridToolbarFormulaField"), Ot = /* @__PURE__ */ o((e) => {
|
|
392
|
+
const n = e.Toolbar, t = e.Solid, r = Array.isArray(n) ? n.filter(g) : g(n) ? [n] : [], i = Array.isArray(t) ? t.filter(
|
|
393
|
+
(c) => g(c) && N(c.Kind, "Toolbar")
|
|
394
|
+
) : g(t) && N(t.Kind, "Toolbar") ? [t] : [];
|
|
395
395
|
return [...r, ...i];
|
|
396
|
-
}, "getTreeGridJsonToolbarRecords"),
|
|
396
|
+
}, "getTreeGridJsonToolbarRecords"), xt = /* @__PURE__ */ o((e, n) => {
|
|
397
397
|
if (!n)
|
|
398
398
|
return e;
|
|
399
399
|
try {
|
|
400
400
|
const t = JSON.parse(e);
|
|
401
|
-
if (!
|
|
401
|
+
if (!g(t))
|
|
402
402
|
return e;
|
|
403
|
-
const r =
|
|
404
|
-
return r.some(
|
|
403
|
+
const r = Ot(t);
|
|
404
|
+
return r.some(Lt) ? e : (r[0] ? r[0].FormulaFormula = n : t.Toolbar = { FormulaFormula: n }, JSON.stringify(t));
|
|
405
405
|
} catch {
|
|
406
406
|
return e;
|
|
407
407
|
}
|
|
408
|
-
}, "applyTreeGridJsonDefaultToolbarTotalCountLayout"),
|
|
409
|
-
(n) =>
|
|
408
|
+
}, "applyTreeGridJsonDefaultToolbarTotalCountLayout"), bt = /* @__PURE__ */ o((e) => ze.some(
|
|
409
|
+
(n) => F(e, n)
|
|
410
410
|
), "hasTreeGridXmlToolbarFormulaAttribute"), It = /* @__PURE__ */ o((e, n) => {
|
|
411
411
|
if (!n)
|
|
412
412
|
return e;
|
|
413
|
-
const t =
|
|
413
|
+
const t = Qn.exec(e);
|
|
414
414
|
if (t) {
|
|
415
|
-
const
|
|
416
|
-
if (
|
|
415
|
+
const a = t[0];
|
|
416
|
+
if (bt(a))
|
|
417
417
|
return e;
|
|
418
|
-
const
|
|
419
|
-
|
|
418
|
+
const f = te(
|
|
419
|
+
a,
|
|
420
420
|
"Formula",
|
|
421
421
|
n
|
|
422
422
|
);
|
|
423
|
-
return `${e.slice(0, t.index)}${
|
|
424
|
-
t.index +
|
|
423
|
+
return `${e.slice(0, t.index)}${f}${e.slice(
|
|
424
|
+
t.index + a.length
|
|
425
425
|
)}`;
|
|
426
426
|
}
|
|
427
427
|
const r = te(
|
|
428
428
|
"<Toolbar />",
|
|
429
429
|
"Formula",
|
|
430
430
|
n
|
|
431
|
-
), i =
|
|
431
|
+
), i = qn.exec(e);
|
|
432
432
|
if (i)
|
|
433
433
|
return `${e.slice(0, i.index)} ${r}
|
|
434
434
|
${e.slice(
|
|
435
435
|
i.index
|
|
436
436
|
)}`;
|
|
437
|
-
const c =
|
|
437
|
+
const c = Zn.exec(e);
|
|
438
438
|
return c ? `${e.slice(
|
|
439
439
|
0,
|
|
440
440
|
c.index + c[0].length
|
|
@@ -442,41 +442,41 @@ ${e.slice(
|
|
|
442
442
|
${r}${e.slice(c.index + c[0].length)}` : e;
|
|
443
443
|
}, "applyTreeGridXmlDefaultToolbarTotalCountLayout"), wt = /* @__PURE__ */ o((e, n) => {
|
|
444
444
|
const t = e.trim();
|
|
445
|
-
return !n || !t ? e : t.startsWith("{") ?
|
|
445
|
+
return !n || !t ? e : t.startsWith("{") ? xt(
|
|
446
446
|
e,
|
|
447
447
|
n
|
|
448
448
|
) : It(e, n);
|
|
449
|
-
}, "applyTreeGridDefaultToolbarTotalCountLayout"),
|
|
449
|
+
}, "applyTreeGridDefaultToolbarTotalCountLayout"), Dt = /* @__PURE__ */ o((e) => {
|
|
450
450
|
try {
|
|
451
451
|
const n = JSON.parse(e);
|
|
452
|
-
return !
|
|
452
|
+
return !g(n) || !en(n) ? e : (pt(n), JSON.stringify(n));
|
|
453
453
|
} catch {
|
|
454
454
|
return e;
|
|
455
455
|
}
|
|
456
|
-
}, "applyTreeGridJsonDefaultFastPanelLayout"),
|
|
456
|
+
}, "applyTreeGridJsonDefaultFastPanelLayout"), Pe = /* @__PURE__ */ o((e, n) => {
|
|
457
457
|
const t = e.trim();
|
|
458
|
-
return t ? t.startsWith("{") ? /\bFastPanel\s*[:=]/i.test(e) ? e :
|
|
458
|
+
return t ? t.startsWith("{") ? /\bFastPanel\s*[:=]/i.test(e) ? e : Dt(e) : Gt(
|
|
459
459
|
e,
|
|
460
|
-
n ??
|
|
460
|
+
n ?? b(e)
|
|
461
461
|
) : e;
|
|
462
|
-
}, "applyTreeGridDefaultFastPanelLayout"),
|
|
462
|
+
}, "applyTreeGridDefaultFastPanelLayout"), yt = /* @__PURE__ */ o((e) => {
|
|
463
463
|
const n = {};
|
|
464
464
|
return e == null || e.forEach((t) => {
|
|
465
465
|
var r;
|
|
466
|
-
(r =
|
|
466
|
+
(r = nt[t]) == null || r.forEach((i) => {
|
|
467
467
|
n[i] = "";
|
|
468
468
|
});
|
|
469
469
|
}), n;
|
|
470
|
-
}, "getTreeGridDisabledAnimationAttributes"),
|
|
470
|
+
}, "getTreeGridDisabledAnimationAttributes"), Pt = /* @__PURE__ */ o((e, n) => {
|
|
471
471
|
try {
|
|
472
472
|
const t = JSON.parse(e);
|
|
473
|
-
if (!
|
|
473
|
+
if (!g(t))
|
|
474
474
|
return e;
|
|
475
475
|
const r = t.Animations;
|
|
476
476
|
if (Array.isArray(r)) {
|
|
477
|
-
const i = r.find(
|
|
477
|
+
const i = r.find(g);
|
|
478
478
|
i ? Object.assign(i, n) : r.unshift({ ...n });
|
|
479
|
-
} else if (
|
|
479
|
+
} else if (g(r))
|
|
480
480
|
Object.assign(r, n);
|
|
481
481
|
else if (r === void 0)
|
|
482
482
|
t.Animations = n;
|
|
@@ -486,62 +486,62 @@ ${e.slice(
|
|
|
486
486
|
} catch {
|
|
487
487
|
return e;
|
|
488
488
|
}
|
|
489
|
-
}, "applyTreeGridJsonDisabledAnimationsLayout"),
|
|
490
|
-
const t =
|
|
489
|
+
}, "applyTreeGridJsonDisabledAnimationsLayout"), $t = /* @__PURE__ */ o((e) => Qe("<Animations />", e), "createTreeGridDisabledAnimationsTag"), vt = /* @__PURE__ */ o((e, n) => {
|
|
490
|
+
const t = b(e);
|
|
491
491
|
if (t.gridOpenTagEndIndex === void 0)
|
|
492
492
|
return e;
|
|
493
493
|
const r = t.animationsTag;
|
|
494
494
|
if (r) {
|
|
495
|
-
const c =
|
|
495
|
+
const c = Qe(r.tag, n);
|
|
496
496
|
return c === r.tag ? e : `${e.slice(0, r.index)}${c}${e.slice(
|
|
497
497
|
r.index + r.tag.length
|
|
498
498
|
)}`;
|
|
499
499
|
}
|
|
500
500
|
const i = t.lastCfgEndIndex ?? t.gridOpenTagEndIndex;
|
|
501
501
|
return `${e.slice(0, i)}
|
|
502
|
-
${
|
|
502
|
+
${$t(
|
|
503
503
|
n
|
|
504
504
|
)}${e.slice(i)}`;
|
|
505
|
-
}, "applyTreeGridXmlDisabledAnimationsLayout"),
|
|
506
|
-
const t =
|
|
505
|
+
}, "applyTreeGridXmlDisabledAnimationsLayout"), $e = /* @__PURE__ */ o((e, n) => {
|
|
506
|
+
const t = yt(n);
|
|
507
507
|
if (!Object.keys(t).length)
|
|
508
508
|
return e;
|
|
509
509
|
const r = e.trim();
|
|
510
|
-
return r ? r.startsWith("{") ?
|
|
510
|
+
return r ? r.startsWith("{") ? Pt(e, t) : vt(e, t) : e;
|
|
511
511
|
}, "applyTreeGridDisabledAnimationsLayout"), re = /* @__PURE__ */ o((e, n, t, r) => {
|
|
512
512
|
const i = wt(
|
|
513
|
-
|
|
514
|
-
|
|
513
|
+
dt(
|
|
514
|
+
mt(e, r)
|
|
515
515
|
),
|
|
516
516
|
t
|
|
517
517
|
), c = i.trim();
|
|
518
518
|
if (!c || c.startsWith("{"))
|
|
519
|
-
return
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
519
|
+
return $e(
|
|
520
|
+
Pe(
|
|
521
|
+
De(
|
|
522
|
+
ye(i)
|
|
523
523
|
)
|
|
524
524
|
),
|
|
525
525
|
n
|
|
526
526
|
);
|
|
527
|
-
const
|
|
527
|
+
const a = b(i), f = ye(
|
|
528
528
|
i,
|
|
529
|
-
|
|
530
|
-
), C =
|
|
531
|
-
|
|
529
|
+
a
|
|
530
|
+
), C = f === i ? a : b(f), p = De(
|
|
531
|
+
f,
|
|
532
532
|
C
|
|
533
|
-
), S =
|
|
534
|
-
return
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
533
|
+
), S = p === f ? C : b(p);
|
|
534
|
+
return $e(
|
|
535
|
+
Et(
|
|
536
|
+
Pe(
|
|
537
|
+
p,
|
|
538
538
|
S
|
|
539
539
|
),
|
|
540
540
|
S
|
|
541
541
|
),
|
|
542
542
|
n
|
|
543
543
|
);
|
|
544
|
-
}, "applyTreeGridDefaultLayout"),
|
|
544
|
+
}, "applyTreeGridDefaultLayout"), Bt = /* @__PURE__ */ o((e) => {
|
|
545
545
|
var n;
|
|
546
546
|
return typeof document > "u" ? null : ((n = document.getElementById(e)) == null ? void 0 : n.closest(`.${wn}`)) ?? null;
|
|
547
547
|
}, "getTreeGridWrapperElement"), Ft = /* @__PURE__ */ o((e) => {
|
|
@@ -551,10 +551,10 @@ ${e.slice(
|
|
|
551
551
|
return "unchecked";
|
|
552
552
|
let n = 0, t = 0;
|
|
553
553
|
return U(e).forEach((r) => {
|
|
554
|
-
!
|
|
554
|
+
!A(r) || y(r.CanSelect) || (n += 1, ee(e.IsSelected(r)) && (t += 1));
|
|
555
555
|
}), t ? n > 0 && t >= n ? "checked" : "indeterminate" : "unchecked";
|
|
556
556
|
}, "getTreeGridSelectAllState"), ie = /* @__PURE__ */ o((e, n) => {
|
|
557
|
-
const t =
|
|
557
|
+
const t = Bt(n), r = !y(e.Selecting), i = fe(
|
|
558
558
|
e.Selecting,
|
|
559
559
|
e.SelectingSingle
|
|
560
560
|
), c = e.Header;
|
|
@@ -563,25 +563,25 @@ ${e.slice(
|
|
|
563
563
|
i
|
|
564
564
|
), !i)
|
|
565
565
|
t == null || t.classList.remove(
|
|
566
|
-
_e,
|
|
567
566
|
me,
|
|
568
|
-
Le
|
|
567
|
+
Le,
|
|
568
|
+
Oe
|
|
569
569
|
);
|
|
570
570
|
else {
|
|
571
|
-
const
|
|
571
|
+
const a = Ft(e);
|
|
572
572
|
t == null || t.classList.toggle(
|
|
573
|
-
_e,
|
|
574
|
-
f === "checked"
|
|
575
|
-
), t == null || t.classList.toggle(
|
|
576
573
|
me,
|
|
577
|
-
|
|
574
|
+
a === "checked"
|
|
578
575
|
), t == null || t.classList.toggle(
|
|
579
576
|
Le,
|
|
580
|
-
|
|
577
|
+
a === "indeterminate"
|
|
578
|
+
), t == null || t.classList.toggle(
|
|
579
|
+
Oe,
|
|
580
|
+
a === "unchecked"
|
|
581
581
|
);
|
|
582
582
|
}
|
|
583
583
|
c && r && (c.CanSelect = i ? 1 : 0);
|
|
584
|
-
}, "syncTreeGridSelectionPanelState"), Z = /* @__PURE__ */ new Map(),
|
|
584
|
+
}, "syncTreeGridSelectionPanelState"), Z = /* @__PURE__ */ new Map(), ve = /* @__PURE__ */ o((e, n) => {
|
|
585
585
|
if (typeof window > "u")
|
|
586
586
|
return;
|
|
587
587
|
const t = Z.get(n);
|
|
@@ -590,54 +590,61 @@ ${e.slice(
|
|
|
590
590
|
Z.delete(n), ie(e, n);
|
|
591
591
|
}, 0);
|
|
592
592
|
Z.set(n, r);
|
|
593
|
-
}, "scheduleTreeGridSelectionPanelStateSync"),
|
|
593
|
+
}, "scheduleTreeGridSelectionPanelStateSync"), Nt = /* @__PURE__ */ o((e, n) => {
|
|
594
594
|
e.EnterMode = n;
|
|
595
|
-
const t =
|
|
595
|
+
const t = kn[n];
|
|
596
596
|
if (!t)
|
|
597
597
|
return;
|
|
598
598
|
const r = e;
|
|
599
599
|
r.Actions ?? (r.Actions = {}), r.Actions.OnEnter = t.onEnter, r.Actions.OnEnterEdit = t.onEnterEdit;
|
|
600
|
-
}, "applyTreeGridDefaultEnterMode"),
|
|
600
|
+
}, "applyTreeGridDefaultEnterMode"), on = /* @__PURE__ */ o((e) => (e == null ? void 0 : e.startsWith("data:")) || (e == null ? void 0 : e.startsWith("blob:")), "isTreeGridInlineUrl"), Be = /* @__PURE__ */ new Map(), kt = /* @__PURE__ */ o((e) => {
|
|
601
601
|
if (!e || !e.startsWith("data:"))
|
|
602
602
|
return e;
|
|
603
|
-
const n =
|
|
603
|
+
const n = Be.get(e);
|
|
604
604
|
if (n)
|
|
605
605
|
return n;
|
|
606
606
|
try {
|
|
607
|
-
const [t, r = ""] = e.split(",", 2), i = /^data:([^;]*)(;base64)?$/i.exec(t), c = (i == null ? void 0 : i[1]) || "application/octet-stream",
|
|
608
|
-
for (let
|
|
609
|
-
|
|
610
|
-
const C = URL.createObjectURL(new Blob([
|
|
611
|
-
return
|
|
607
|
+
const [t, r = ""] = e.split(",", 2), i = /^data:([^;]*)(;base64)?$/i.exec(t), c = (i == null ? void 0 : i[1]) || "application/octet-stream", a = i != null && i[2] ? atob(r) : decodeURIComponent(r), f = new Uint8Array(a.length);
|
|
608
|
+
for (let p = 0; p < a.length; p += 1)
|
|
609
|
+
f[p] = a.charCodeAt(p);
|
|
610
|
+
const C = URL.createObjectURL(new Blob([f], { type: c }));
|
|
611
|
+
return Be.set(e, C), C;
|
|
612
612
|
} catch {
|
|
613
613
|
return e;
|
|
614
614
|
}
|
|
615
615
|
}, "resolveTreeGridInlineUrl"), oe = /* @__PURE__ */ o((e) => {
|
|
616
|
-
if (!e ||
|
|
617
|
-
return
|
|
616
|
+
if (!e || on(e))
|
|
617
|
+
return kt(e);
|
|
618
618
|
const n = e.indexOf("#"), [t, r] = n >= 0 ? [e.slice(0, n), e.slice(n)] : [e, ""], i = t.includes("?") ? "&" : "?";
|
|
619
619
|
return `${t}${i}noCache=${Date.now()}${r}`;
|
|
620
620
|
}, "appendNoCacheQuery"), Fe = /* @__PURE__ */ o((e, n, t) => {
|
|
621
621
|
if (!e)
|
|
622
622
|
return;
|
|
623
|
-
const r = t.canEdit, i = t.
|
|
624
|
-
if (!(r === void 0 && !
|
|
623
|
+
const r = t.canEdit, i = t.editableColumns ?? [], c = t.editableCanEdit, a = t.highlightColumns ?? [], f = t.highlightBackgroundColor;
|
|
624
|
+
if (!(r === void 0 && c === void 0 && !a.length)) {
|
|
625
625
|
typeof e.StartUpdate == "function" && e.StartUpdate();
|
|
626
626
|
try {
|
|
627
|
-
r !== void 0 && (n.CanEdit = r),
|
|
628
|
-
|
|
627
|
+
if (r !== void 0 && (n.CanEdit = r), c !== void 0) {
|
|
628
|
+
const C = n;
|
|
629
|
+
i.forEach((p) => {
|
|
630
|
+
var S;
|
|
631
|
+
!p || !((S = e.Cols) != null && S[p]) || (C[`${p}CanEdit`] = c);
|
|
632
|
+
});
|
|
633
|
+
}
|
|
634
|
+
a.forEach((C) => {
|
|
635
|
+
C && (e.SetValue(
|
|
629
636
|
n,
|
|
630
|
-
`${
|
|
631
|
-
|
|
637
|
+
`${C}Class`,
|
|
638
|
+
f ? Xe : "",
|
|
632
639
|
0
|
|
633
|
-
), e.SetValue(n, `${
|
|
640
|
+
), e.SetValue(n, `${C}Color`, f ?? "", 0));
|
|
634
641
|
});
|
|
635
642
|
} finally {
|
|
636
643
|
typeof e.EndUpdate == "function" && e.EndUpdate();
|
|
637
644
|
}
|
|
638
645
|
typeof e.RefreshRow == "function" && e.RefreshRow(n);
|
|
639
646
|
}
|
|
640
|
-
}, "syncTreeGridDeletedRowState"),
|
|
647
|
+
}, "syncTreeGridDeletedRowState"), Ut = /* @__PURE__ */ o((e) => e ? on(e) || e.includes("assets") ? oe(e) : oe(`undefined/${e}`) : "", "resolveTreeGridDataUrl"), Vt = /* @__PURE__ */ o((e) => (typeof e == "object" || typeof e == "function") && e !== null && typeof e.then == "function", "isTreeGridPromiseLike"), Mt = /* @__PURE__ */ o((e, n, t, r) => {
|
|
641
648
|
if (!(!e || t === "cancel")) {
|
|
642
649
|
if (t === "remove") {
|
|
643
650
|
e.RemoveRow(n), r(e);
|
|
@@ -645,19 +652,19 @@ ${e.slice(
|
|
|
645
652
|
}
|
|
646
653
|
e.DeleteRowT(n, 3);
|
|
647
654
|
}
|
|
648
|
-
}, "applyTreeGridBeforeRowUndeleteAction"),
|
|
655
|
+
}, "applyTreeGridBeforeRowUndeleteAction"), Xt = /* @__PURE__ */ o((e, n, t) => e ? { Url: Ut(n) } : { Data: { Body: [Bn(t) ? [] : t] } }, "buildTreeGridDataSource"), $r = /* @__PURE__ */ o(({
|
|
649
656
|
id: e,
|
|
650
657
|
layoutUrl: n,
|
|
651
658
|
layoutData: t,
|
|
652
659
|
toolbarTotalCountFormula: r,
|
|
653
660
|
suppressCfg: i,
|
|
654
661
|
disabledAnimations: c,
|
|
655
|
-
dataUrl:
|
|
656
|
-
bodyData:
|
|
662
|
+
dataUrl: a,
|
|
663
|
+
bodyData: f,
|
|
657
664
|
useDataUrl: C,
|
|
658
|
-
width:
|
|
665
|
+
width: p,
|
|
659
666
|
height: S,
|
|
660
|
-
languageId:
|
|
667
|
+
languageId: R
|
|
661
668
|
}) => ({
|
|
662
669
|
id: e,
|
|
663
670
|
Layout: t ? {
|
|
@@ -668,14 +675,14 @@ ${e.slice(
|
|
|
668
675
|
i
|
|
669
676
|
)
|
|
670
677
|
} : { Url: oe(n ?? "") },
|
|
671
|
-
Data:
|
|
678
|
+
Data: Xt(C, a, f),
|
|
672
679
|
Text: {
|
|
673
|
-
Url:
|
|
680
|
+
Url: An(R)
|
|
674
681
|
},
|
|
675
|
-
width:
|
|
682
|
+
width: p,
|
|
676
683
|
height: S,
|
|
677
684
|
Debug: "Error"
|
|
678
|
-
}), "buildTreeGridInitializationOptions"),
|
|
685
|
+
}), "buildTreeGridInitializationOptions"), Ne = /* @__PURE__ */ o((e) => Fn(e, "Data.Data.Data.Body.0"), "getTreeGridBodyData"), ke = /* @__PURE__ */ o((e) => {
|
|
679
686
|
if (typeof e == "number")
|
|
680
687
|
return Number.isFinite(e) && e > 0 ? e : void 0;
|
|
681
688
|
if (typeof e != "string")
|
|
@@ -688,97 +695,97 @@ ${e.slice(
|
|
|
688
695
|
}, "parseTreeGridPositiveNumber"), se = /* @__PURE__ */ o((e, n, t, r) => {
|
|
689
696
|
if (!n || !t)
|
|
690
697
|
return;
|
|
691
|
-
const i = e.GetAttribute(n, t, r), c =
|
|
692
|
-
return c !== void 0 ? c :
|
|
698
|
+
const i = e.GetAttribute(n, t, r), c = ke(i);
|
|
699
|
+
return c !== void 0 ? c : ke(
|
|
693
700
|
n[`${t}${r}`]
|
|
694
701
|
);
|
|
695
|
-
}, "getTreeGridHeaderCellSpanAttribute"),
|
|
702
|
+
}, "getTreeGridHeaderCellSpanAttribute"), Wt = /* @__PURE__ */ o((e, n, t) => !n || !t || n.Fixed !== "Head" || (se(e, n, t, "Span") ?? 1) <= 1 ? !1 : (se(e, n, t, "RowSpan") ?? 1) === 1, "isTreeGridGroupHeaderCell"), Ue = /* @__PURE__ */ o((e, n, t) => {
|
|
696
703
|
const r = e.get(n);
|
|
697
704
|
if (r) {
|
|
698
705
|
r.add(t);
|
|
699
706
|
return;
|
|
700
707
|
}
|
|
701
708
|
e.set(n, /* @__PURE__ */ new Set([t]));
|
|
702
|
-
}, "addTreeGridHeaderButtonAttributeTarget"),
|
|
709
|
+
}, "addTreeGridHeaderButtonAttributeTarget"), sn = /* @__PURE__ */ o((e, n, t, r) => {
|
|
703
710
|
const i = /* @__PURE__ */ new Map();
|
|
704
|
-
return n.forEach((c,
|
|
705
|
-
t.forEach((
|
|
706
|
-
if (!
|
|
711
|
+
return n.forEach((c, a) => {
|
|
712
|
+
t.forEach((f, C) => {
|
|
713
|
+
if (!Wt(e, c, f) || (Ue(i, c, f), !r))
|
|
707
714
|
return;
|
|
708
|
-
const
|
|
709
|
-
for (let
|
|
710
|
-
const m = n[
|
|
715
|
+
const p = Math.floor(se(e, c, f, "Span") ?? 1), S = Math.min(t.length, C + p);
|
|
716
|
+
for (let R = a + 1; R < n.length; R += 1) {
|
|
717
|
+
const m = n[R];
|
|
711
718
|
for (let L = C; L < S; L += 1)
|
|
712
|
-
|
|
719
|
+
Ue(i, m, t[L]);
|
|
713
720
|
}
|
|
714
721
|
});
|
|
715
722
|
}), i;
|
|
716
|
-
}, "getTreeGridGroupHeaderSortButtonTargets"),
|
|
717
|
-
var
|
|
723
|
+
}, "getTreeGridGroupHeaderSortButtonTargets"), Jt = /* @__PURE__ */ o((e, n, t, r) => {
|
|
724
|
+
var a;
|
|
718
725
|
if (!n || !t || n.Fixed !== "Head")
|
|
719
726
|
return !1;
|
|
720
|
-
const i = typeof e.GetFixedRows == "function" ? e.GetFixedRows().filter((
|
|
721
|
-
return !i.length || !c.length ? !1 : ((
|
|
727
|
+
const i = typeof e.GetFixedRows == "function" ? e.GetFixedRows().filter((f) => f.Fixed === "Head") : [], c = typeof e.GetCols == "function" ? e.GetCols() : [];
|
|
728
|
+
return !i.length || !c.length ? !1 : ((a = sn(
|
|
722
729
|
e,
|
|
723
730
|
i,
|
|
724
731
|
c,
|
|
725
732
|
r
|
|
726
|
-
).get(n)) == null ? void 0 :
|
|
727
|
-
}, "isTreeGridGroupHeaderSortButtonTarget"),
|
|
728
|
-
const i = typeof performance < "u" ? performance.now() : Date.now(), c = typeof e.GetFixedRows == "function" ? e.GetFixedRows().filter((S) => S.Fixed === "Head") : [],
|
|
729
|
-
if (!c.length || !
|
|
733
|
+
).get(n)) == null ? void 0 : a.has(t)) === !0;
|
|
734
|
+
}, "isTreeGridGroupHeaderSortButtonTarget"), Ve = /* @__PURE__ */ o((e, n, t = !1, r = !0) => {
|
|
735
|
+
const i = typeof performance < "u" ? performance.now() : Date.now(), c = typeof e.GetFixedRows == "function" ? e.GetFixedRows().filter((S) => S.Fixed === "Head") : [], a = typeof e.GetCols == "function" ? e.GetCols() : [];
|
|
736
|
+
if (!c.length || !a.length)
|
|
730
737
|
return;
|
|
731
|
-
const
|
|
738
|
+
const f = /* @__PURE__ */ new Set();
|
|
732
739
|
let C = 0;
|
|
733
|
-
const
|
|
740
|
+
const p = sn(
|
|
734
741
|
e,
|
|
735
742
|
c,
|
|
736
|
-
|
|
743
|
+
a,
|
|
737
744
|
r
|
|
738
745
|
);
|
|
739
|
-
if (
|
|
746
|
+
if (p.size) {
|
|
740
747
|
typeof e.StartUpdate == "function" && e.StartUpdate();
|
|
741
748
|
try {
|
|
742
|
-
|
|
749
|
+
p.forEach((S, R) => {
|
|
743
750
|
S.forEach((m) => {
|
|
744
|
-
e.GetAttribute(
|
|
751
|
+
e.GetAttribute(R, m, be) !== "" && (e.SetAttribute(R, m, be, "", 0, 0), f.add(R), C += 1);
|
|
745
752
|
});
|
|
746
753
|
});
|
|
747
754
|
} finally {
|
|
748
755
|
typeof e.EndUpdate == "function" && e.EndUpdate();
|
|
749
756
|
}
|
|
750
|
-
|
|
757
|
+
f.size && (t && f.forEach((S) => {
|
|
751
758
|
typeof e.RefreshRow == "function" && e.RefreshRow(S);
|
|
752
|
-
}),
|
|
759
|
+
}), Ke(n, "group header button attribute apply"), je(n, "group header button attribute apply", i, {
|
|
753
760
|
updatedCellCount: C,
|
|
754
|
-
updatedRowCount:
|
|
761
|
+
updatedRowCount: f.size
|
|
755
762
|
}));
|
|
756
763
|
}
|
|
757
|
-
}, "applyTreeGridGroupHeaderSortButtonAttributes"),
|
|
764
|
+
}, "applyTreeGridGroupHeaderSortButtonAttributes"), Kt = /* @__PURE__ */ o((e) => Array.isArray(e) ? e.length : 0, "getTreeGridBodyDataCount"), jt = /* @__PURE__ */ o((e) => {
|
|
758
765
|
const n = e == null ? void 0 : e.Visible;
|
|
759
766
|
return !!e && n !== 0 && n !== !1 && n !== "0";
|
|
760
767
|
}, "isVisibleTreeGridRow"), P = /* @__PURE__ */ o((e) => {
|
|
761
768
|
const n = e == null ? void 0 : e.Added;
|
|
762
769
|
return !!e && n !== 0 && n !== !1 && n !== "0" && n !== void 0;
|
|
763
|
-
}, "isAddedTreeGridRow"),
|
|
770
|
+
}, "isAddedTreeGridRow"), cn = /* @__PURE__ */ o((e) => {
|
|
764
771
|
const n = e == null ? void 0 : e.Deleted;
|
|
765
772
|
return !!e && n !== 0 && n !== !1 && n !== "0" && n !== void 0;
|
|
766
|
-
}, "isDeletedTreeGridRow"),
|
|
773
|
+
}, "isDeletedTreeGridRow"), A = /* @__PURE__ */ o((e) => !e || e.Fixed === "Foot" || !jt(e) ? !1 : e.Kind === "Data" || P(e), "isDisplayTreeGridRow"), H = /* @__PURE__ */ o((e) => Object.keys(e.Cols ?? {}).filter(Boolean), "getTreeGridColumnNames"), Ht = /* @__PURE__ */ o((e, n) => {
|
|
767
774
|
var r;
|
|
768
775
|
const t = (r = e.Cols) == null ? void 0 : r[n];
|
|
769
|
-
return !!t && !y(t.Visible) && !
|
|
770
|
-
}, "isVisibleTreeGridColumn"), X = /* @__PURE__ */ o((e, n) => typeof e == "number" && Number.isFinite(e) ? e : n, "resolveTreeGridColumnOrderValue"),
|
|
776
|
+
return !!t && !y(t.Visible) && !tt(t.Hidden);
|
|
777
|
+
}, "isVisibleTreeGridColumn"), X = /* @__PURE__ */ o((e, n) => typeof e == "number" && Number.isFinite(e) ? e : n, "resolveTreeGridColumnOrderValue"), zt = /* @__PURE__ */ o((e) => {
|
|
771
778
|
const n = Q.get(e);
|
|
772
779
|
if (n)
|
|
773
780
|
return n;
|
|
774
781
|
const t = new Map(
|
|
775
|
-
H(e).map((c,
|
|
782
|
+
H(e).map((c, a) => [c, a])
|
|
776
783
|
), r = [...t.keys()].filter(
|
|
777
|
-
(c) => !
|
|
778
|
-
).sort((c,
|
|
779
|
-
var L,
|
|
780
|
-
const
|
|
781
|
-
return
|
|
784
|
+
(c) => !jn.has(c) && Ht(e, c)
|
|
785
|
+
).sort((c, a) => {
|
|
786
|
+
var L, w;
|
|
787
|
+
const f = (L = e.Cols) == null ? void 0 : L[c], C = (w = e.Cols) == null ? void 0 : w[a], p = t.get(c) ?? 0, S = t.get(a) ?? 0, R = X(f == null ? void 0 : f.Sec, p) - X(C == null ? void 0 : C.Sec, S);
|
|
788
|
+
return R !== 0 ? R : X(f == null ? void 0 : f.Pos, p) - X(C == null ? void 0 : C.Pos, S) || p - S;
|
|
782
789
|
}), i = {
|
|
783
790
|
columnSet: new Set(r),
|
|
784
791
|
firstColumn: r[0],
|
|
@@ -796,68 +803,68 @@ ${e.slice(
|
|
|
796
803
|
return n;
|
|
797
804
|
}
|
|
798
805
|
return Object.values(e.Rows ?? {});
|
|
799
|
-
}, "getTreeGridRows"), ce = /* @__PURE__ */ new WeakMap(),
|
|
806
|
+
}, "getTreeGridRows"), ce = /* @__PURE__ */ new WeakMap(), x = /* @__PURE__ */ o((e) => {
|
|
800
807
|
e && ce.delete(e);
|
|
801
|
-
}, "clearTreeGridSelectionRowSpanAnchorRowMap"),
|
|
808
|
+
}, "clearTreeGridSelectionRowSpanAnchorRowMap"), ln = /* @__PURE__ */ o((e, n) => {
|
|
802
809
|
const t = e, r = t == null ? void 0 : t[`${n}RowSpan`], i = typeof r == "number" ? r : Number.parseFloat(String(r ?? ""));
|
|
803
810
|
return Number.isFinite(i) && i > 1 ? Math.floor(i) : 1;
|
|
804
|
-
}, "getTreeGridRowSpanCount"),
|
|
811
|
+
}, "getTreeGridRowSpanCount"), Yt = /* @__PURE__ */ o((e) => {
|
|
805
812
|
const n = /* @__PURE__ */ new WeakMap();
|
|
806
813
|
let t = null, r = -1;
|
|
807
814
|
return U(e).forEach((i, c) => {
|
|
808
|
-
if (!
|
|
815
|
+
if (!A(i)) {
|
|
809
816
|
n.set(i, null);
|
|
810
817
|
return;
|
|
811
818
|
}
|
|
812
|
-
const
|
|
813
|
-
if (
|
|
814
|
-
t = i, r = c +
|
|
819
|
+
const a = ln(i, He);
|
|
820
|
+
if (a > 1) {
|
|
821
|
+
t = i, r = c + a - 1, n.set(i, i);
|
|
815
822
|
return;
|
|
816
823
|
}
|
|
817
824
|
n.set(i, t && c <= r ? t : null), c >= r && (t = null, r = -1);
|
|
818
825
|
}), n;
|
|
819
826
|
}, "createTreeGridSelectionRowSpanAnchorRowMap"), ae = /* @__PURE__ */ o((e, n) => {
|
|
820
|
-
if (!n || !
|
|
827
|
+
if (!n || !A(n))
|
|
821
828
|
return null;
|
|
822
829
|
let t = ce.get(e);
|
|
823
|
-
return t != null && t.has(n) || (t =
|
|
824
|
-
}, "getTreeGridSelectionRowSpanAnchorRow"),
|
|
830
|
+
return t != null && t.has(n) || (t = Yt(e), ce.set(e, t)), t.get(n) ?? null;
|
|
831
|
+
}, "getTreeGridSelectionRowSpanAnchorRow"), dn = /* @__PURE__ */ o((e, n) => {
|
|
825
832
|
const t = ae(e, n);
|
|
826
833
|
if (!t)
|
|
827
834
|
return [];
|
|
828
|
-
const r =
|
|
835
|
+
const r = ln(t, He), i = [];
|
|
829
836
|
let c = t;
|
|
830
|
-
for (let
|
|
831
|
-
|
|
837
|
+
for (let a = 0; c && a < r; a += 1)
|
|
838
|
+
A(c) && i.push(c), c = typeof e.GetNext == "function" ? e.GetNext(c) : null;
|
|
832
839
|
return i;
|
|
833
|
-
}, "getTreeGridSelectionRowSpanRows"),
|
|
840
|
+
}, "getTreeGridSelectionRowSpanRows"), Zt = /* @__PURE__ */ o((e) => {
|
|
834
841
|
const n = /* @__PURE__ */ new Set();
|
|
835
842
|
return (e.GetSelRows() ?? []).forEach((t) => {
|
|
836
|
-
|
|
843
|
+
dn(e, t).forEach((r) => {
|
|
837
844
|
n.add(r);
|
|
838
845
|
});
|
|
839
846
|
}), [...n];
|
|
840
|
-
}, "getTreeGridSelectedRowSpanRows"),
|
|
847
|
+
}, "getTreeGridSelectedRowSpanRows"), qt = /* @__PURE__ */ o((e, n) => {
|
|
841
848
|
if (!e)
|
|
842
849
|
return;
|
|
843
850
|
const t = H(e);
|
|
844
851
|
U(e).forEach((r) => {
|
|
845
|
-
|
|
852
|
+
A(r) && n.set(
|
|
846
853
|
r,
|
|
847
854
|
new Map(t.map((i) => [i, ue(e, r, i)]))
|
|
848
855
|
);
|
|
849
856
|
});
|
|
850
|
-
}, "captureTreeGridChangeBaselines"), le = /* @__PURE__ */ o((e) => e != null && e !== "" && e !== 0 && e !== !1 && e !== "0", "isTreeGridChangedFlag"),
|
|
857
|
+
}, "captureTreeGridChangeBaselines"), le = /* @__PURE__ */ o((e) => e != null && e !== "" && e !== 0 && e !== !1 && e !== "0", "isTreeGridChangedFlag"), Qt = /* @__PURE__ */ o((e, n, t) => {
|
|
851
858
|
const r = n;
|
|
852
859
|
return H(e).some((i) => i !== t && le(r[`${i}Changed`]));
|
|
853
|
-
}, "hasOtherTreeGridChangedCells"),
|
|
860
|
+
}, "hasOtherTreeGridChangedCells"), un = /* @__PURE__ */ o((e, n, t) => {
|
|
854
861
|
const r = n;
|
|
855
|
-
r[`${t}Changed`] = 0, !P(n) && !
|
|
856
|
-
}, "clearTreeGridCellChangedState"),
|
|
862
|
+
r[`${t}Changed`] = 0, !P(n) && !I(n) && !Qt(e, n, t) && (r.Changed = 0);
|
|
863
|
+
}, "clearTreeGridCellChangedState"), er = /* @__PURE__ */ o((e, n, t) => {
|
|
857
864
|
const r = e.get(n);
|
|
858
865
|
if (r != null && r.has(t))
|
|
859
866
|
return r.get(t);
|
|
860
|
-
}, "resolveTreeGridCellBaselineValue"),
|
|
867
|
+
}, "resolveTreeGridCellBaselineValue"), nr = /* @__PURE__ */ o(({
|
|
861
868
|
gridId: e,
|
|
862
869
|
grid: n,
|
|
863
870
|
row: t,
|
|
@@ -865,59 +872,59 @@ ${e.slice(
|
|
|
865
872
|
backgroundColor: i,
|
|
866
873
|
highlightRefresh: c
|
|
867
874
|
}) => {
|
|
868
|
-
if (!P(t) && !
|
|
875
|
+
if (!P(t) && !I(t))
|
|
869
876
|
return !1;
|
|
870
877
|
if (n.CanEdit(t, r) !== 1)
|
|
871
878
|
return !0;
|
|
872
|
-
const
|
|
873
|
-
return
|
|
879
|
+
const a = mn(t, r), f = q(t).includes(r);
|
|
880
|
+
return a === void 0 ? !0 : ue(n, t, r) === a ? (Ln(t, r), f && We(e, { row: t, col: r }), un(n, t, r), !0) : (On(t, r), Je(e, {
|
|
874
881
|
row: t,
|
|
875
882
|
col: r,
|
|
876
883
|
backgroundColor: i,
|
|
877
884
|
refresh: c
|
|
878
885
|
}), !0);
|
|
879
|
-
}, "syncTreeGridAddedRowChangedCellHighlight"),
|
|
886
|
+
}, "syncTreeGridAddedRowChangedCellHighlight"), tr = /* @__PURE__ */ o(({
|
|
880
887
|
gridId: e,
|
|
881
888
|
grid: n,
|
|
882
889
|
row: t,
|
|
883
890
|
col: r,
|
|
884
891
|
backgroundColor: i,
|
|
885
892
|
baselineMap: c,
|
|
886
|
-
highlightRefresh:
|
|
893
|
+
highlightRefresh: a
|
|
887
894
|
}) => {
|
|
888
|
-
if (!
|
|
895
|
+
if (!A(t) || nr({
|
|
889
896
|
gridId: e,
|
|
890
897
|
grid: n,
|
|
891
898
|
row: t,
|
|
892
899
|
col: r,
|
|
893
900
|
backgroundColor: i,
|
|
894
|
-
highlightRefresh:
|
|
901
|
+
highlightRefresh: a
|
|
895
902
|
}))
|
|
896
903
|
return;
|
|
897
|
-
const
|
|
898
|
-
if (
|
|
899
|
-
|
|
904
|
+
const f = er(c, t, r), C = ue(n, t, r);
|
|
905
|
+
if (f !== void 0 && C === f) {
|
|
906
|
+
We(e, { row: t, col: r }), un(n, t, r);
|
|
900
907
|
return;
|
|
901
908
|
}
|
|
902
|
-
|
|
909
|
+
Je(e, {
|
|
903
910
|
row: t,
|
|
904
911
|
col: r,
|
|
905
912
|
backgroundColor: i,
|
|
906
|
-
refresh:
|
|
913
|
+
refresh: a
|
|
907
914
|
});
|
|
908
|
-
}, "syncTreeGridChangedCellHighlight"),
|
|
915
|
+
}, "syncTreeGridChangedCellHighlight"), rr = /* @__PURE__ */ o((e, n, t) => !n || !t || !A(n) ? !1 : e.CanEdit(n, t) === 1, "isEditableTreeGridCell"), fn = /* @__PURE__ */ o((e, n, t) => {
|
|
909
916
|
const r = e.GetAttribute(n, t, "Color");
|
|
910
917
|
if (typeof r == "number")
|
|
911
|
-
return
|
|
918
|
+
return Tn(r);
|
|
912
919
|
if (typeof r == "string")
|
|
913
920
|
return r.trim() || void 0;
|
|
914
|
-
}, "getExplicitTreeGridCellColor"),
|
|
915
|
-
if (!n || !t || !
|
|
921
|
+
}, "getExplicitTreeGridCellColor"), ir = /* @__PURE__ */ o((e, n, t) => fn(e, n, t) !== void 0, "hasExplicitTreeGridCellColor"), Te = /* @__PURE__ */ o((e, n, t) => {
|
|
922
|
+
if (!n || !t || !A(n))
|
|
916
923
|
return !1;
|
|
917
924
|
const r = typeof e.IsFocused == "function" ? e.IsFocused(n, t) : e.FRow === n && e.FCol === t;
|
|
918
925
|
return r !== 0 && r !== !1 && r !== void 0 && r !== null;
|
|
919
926
|
}, "isTreeGridFocusedCellState"), V = /* @__PURE__ */ o((e, n, t) => {
|
|
920
|
-
if (!n || !t || !
|
|
927
|
+
if (!n || !t || !A(n))
|
|
921
928
|
return !1;
|
|
922
929
|
const r = e.IsSelected(n, t);
|
|
923
930
|
if (r !== 0 && r !== !1 && r !== void 0 && r !== null)
|
|
@@ -934,11 +941,11 @@ ${e.slice(
|
|
|
934
941
|
return Ie.every(
|
|
935
942
|
(t) => n.includes(t)
|
|
936
943
|
);
|
|
937
|
-
}, "hasTreeGridChangedCellDisplayClass"),
|
|
938
|
-
if (!(!e || e.split(/\s+/).includes(
|
|
939
|
-
return `${e} ${
|
|
940
|
-
}, "appendTreeGridSelectedChangedCellDisplayClass"),
|
|
941
|
-
if (!n || !
|
|
944
|
+
}, "hasTreeGridChangedCellDisplayClass"), or = /* @__PURE__ */ o((e) => {
|
|
945
|
+
if (!(!e || e.split(/\s+/).includes(xe) || !Ce(e)))
|
|
946
|
+
return `${e} ${xe}`;
|
|
947
|
+
}, "appendTreeGridSelectedChangedCellDisplayClass"), sr = /* @__PURE__ */ o((e) => !e || !A(e) ? !1 : Object.entries(e).some(([n, t]) => n.endsWith("Class") && typeof t == "string" && Ce(t)), "hasTreeGridChangedCellDisplayClassInRow"), cr = /* @__PURE__ */ o((e, n) => {
|
|
948
|
+
if (!n || !sr(n) || typeof e.RefreshRow != "function")
|
|
942
949
|
return;
|
|
943
950
|
const t = n;
|
|
944
951
|
window.setTimeout(() => {
|
|
@@ -953,30 +960,30 @@ ${e.slice(
|
|
|
953
960
|
e.RefreshRow(r);
|
|
954
961
|
});
|
|
955
962
|
}, 0);
|
|
956
|
-
}, "scheduleTreeGridRowsRefresh"),
|
|
963
|
+
}, "scheduleTreeGridRowsRefresh"), lr = /* @__PURE__ */ o((e, n) => {
|
|
957
964
|
if (!n)
|
|
958
965
|
return;
|
|
959
|
-
const t =
|
|
966
|
+
const t = dn(e, n);
|
|
960
967
|
t.length <= 1 || M(e, t);
|
|
961
|
-
}, "scheduleTreeGridSelectionRowSpanRefresh"),
|
|
962
|
-
const n = U(e).filter((t) =>
|
|
968
|
+
}, "scheduleTreeGridSelectionRowSpanRefresh"), dr = /* @__PURE__ */ o((e) => {
|
|
969
|
+
const n = U(e).filter((t) => A(t) && ae(e, t));
|
|
963
970
|
M(e, n);
|
|
964
|
-
}, "scheduleTreeGridSelectionRowSpanRefreshAll"),
|
|
965
|
-
if (!(!n || r === void 0 || !
|
|
971
|
+
}, "scheduleTreeGridSelectionRowSpanRefreshAll"), an = /* @__PURE__ */ o((e, n, t, r) => {
|
|
972
|
+
if (!(!n || r === void 0 || !rr(e, n, t) || Te(e, n, t) || V(e, n, t) || ir(e, n, t)))
|
|
966
973
|
return r;
|
|
967
|
-
}, "getEditableTreeGridCellDefaultColor"),
|
|
968
|
-
(r) =>
|
|
969
|
-
), "isTreeGridNativeErrorBackgroundColor"),
|
|
974
|
+
}, "getEditableTreeGridCellDefaultColor"), B = /* @__PURE__ */ o((e, n, t, r) => e === r[0] && n === r[1] && t === r[2], "matchesTreeGridRgbColor"), ur = /* @__PURE__ */ o((e, n, t) => Jn.some(
|
|
975
|
+
(r) => B(e, n, t, r)
|
|
976
|
+
), "isTreeGridNativeErrorBackgroundColor"), Tn = /* @__PURE__ */ o((e) => {
|
|
970
977
|
if (!(e === void 0 || !Number.isFinite(e)))
|
|
971
978
|
return `#${Math.trunc(e).toString(16).padStart(6, "0")}`;
|
|
972
|
-
}, "toTreeGridCssHexColor"), de = /* @__PURE__ */ o((e, n, t) => !n || !t || !
|
|
979
|
+
}, "toTreeGridCssHexColor"), de = /* @__PURE__ */ o((e, n, t) => !n || !t || !A(n) ? "" : e.GetAttribute(n, t, "Error") ?? "", "getTreeGridCellError"), Ee = /* @__PURE__ */ o((e, n, t) => de(e, n, t) !== "", "hasTreeGridCellError"), fr = /* @__PURE__ */ o((e, n) => {
|
|
973
980
|
if (!n)
|
|
974
981
|
return;
|
|
975
982
|
let t = !1;
|
|
976
983
|
H(e).forEach((r) => {
|
|
977
984
|
Ee(e, n, r) && (e.SetAttribute(n, r, "Error", "", 0), t = !0);
|
|
978
985
|
}), t && e.RefreshRow(n);
|
|
979
|
-
}, "clearTreeGridRowErrors"),
|
|
986
|
+
}, "clearTreeGridRowErrors"), ar = /* @__PURE__ */ o((e) => {
|
|
980
987
|
const n = e == null ? void 0 : e.target;
|
|
981
988
|
if (typeof HTMLElement > "u" || typeof Element > "u" || typeof Node > "u")
|
|
982
989
|
return null;
|
|
@@ -986,60 +993,60 @@ ${e.slice(
|
|
|
986
993
|
return c instanceof HTMLElement ? c : i instanceof HTMLElement ? i : null;
|
|
987
994
|
}
|
|
988
995
|
return null;
|
|
989
|
-
}, "getTreeGridMouseEventAnchorElement"),
|
|
990
|
-
if (!e || !n || !
|
|
996
|
+
}, "getTreeGridMouseEventAnchorElement"), Tr = /* @__PURE__ */ o((e, n) => {
|
|
997
|
+
if (!e || !n || !A(e))
|
|
991
998
|
return !1;
|
|
992
999
|
const t = e, r = t[`${n}Class`], i = le(t[`${n}Changed`]) || typeof r == "string" && Ce(r);
|
|
993
|
-
return P(e) ||
|
|
994
|
-
}, "isChangedTreeGridRowOrCell"),
|
|
1000
|
+
return P(e) || I(e) ? i : i || le(t.Changed);
|
|
1001
|
+
}, "isChangedTreeGridRowOrCell"), Cr = /* @__PURE__ */ o((e, n, t) => Hn.has(e.GetType(n, t)), "isTreeGridNativeInputEditType"), Er = /* @__PURE__ */ o((e, n, t) => !n || !t || !A(n) || e.ARow !== n || e.ACol !== t ? !1 : e.CanEdit(n, t) === 0, "isTreeGridReadonlyHoveredCellState"), Gr = /* @__PURE__ */ o((e, n, t) => !n || !t || !A(n) || e.ARow !== n || e.ACol !== t ? !1 : e.CanEdit(n, t) === 2, "isTreeGridPreviewHoveredCellState"), pr = /* @__PURE__ */ o((e, n) => !!n && A(n) && e.FRow === n, "isTreeGridFocusedRowState"), Sr = /* @__PURE__ */ o(({
|
|
995
1002
|
grid: e,
|
|
996
1003
|
row: n,
|
|
997
1004
|
col: t,
|
|
998
1005
|
r,
|
|
999
1006
|
g: i,
|
|
1000
1007
|
b: c,
|
|
1001
|
-
focusedCellBackgroundColor:
|
|
1002
|
-
selectedCellBackgroundColor:
|
|
1008
|
+
focusedCellBackgroundColor: a,
|
|
1009
|
+
selectedCellBackgroundColor: f,
|
|
1003
1010
|
hoverCellBackgroundColor: C,
|
|
1004
|
-
changedCellBackgroundColor:
|
|
1011
|
+
changedCellBackgroundColor: p,
|
|
1005
1012
|
editableCellBackgroundColorValue: S
|
|
1006
1013
|
}) => {
|
|
1007
1014
|
if (Te(e, n, t))
|
|
1008
|
-
return f;
|
|
1009
|
-
if (V(e, n, t))
|
|
1010
1015
|
return a;
|
|
1011
|
-
if (
|
|
1016
|
+
if (V(e, n, t))
|
|
1017
|
+
return f;
|
|
1018
|
+
if (Er(e, n, t) && (B(r, i, c, Un) || B(r, i, c, Vn)) || Gr(e, n, t) && (B(r, i, c, Mn) || B(r, i, c, Xn) || B(r, i, c, Wn)))
|
|
1012
1019
|
return C;
|
|
1013
|
-
if (
|
|
1020
|
+
if (cn(n))
|
|
1014
1021
|
return;
|
|
1015
|
-
const
|
|
1016
|
-
if (!m && !
|
|
1022
|
+
const R = P(n) || I(n), m = Ee(e, n, t) && ur(r, i, c);
|
|
1023
|
+
if (!m && !R)
|
|
1017
1024
|
return;
|
|
1018
|
-
const L =
|
|
1025
|
+
const L = fn(e, n, t);
|
|
1019
1026
|
if (m && L)
|
|
1020
1027
|
return L;
|
|
1021
|
-
if (
|
|
1022
|
-
return
|
|
1023
|
-
const
|
|
1028
|
+
if (Tr(n, t))
|
|
1029
|
+
return p;
|
|
1030
|
+
const w = an(
|
|
1024
1031
|
e,
|
|
1025
1032
|
n,
|
|
1026
1033
|
t,
|
|
1027
1034
|
S
|
|
1028
1035
|
);
|
|
1029
|
-
return
|
|
1036
|
+
return w !== void 0 ? Tn(w) : R ? L ?? gn : Kn;
|
|
1030
1037
|
}, "resolveTreeGridStateBackgroundColor"), K = /* @__PURE__ */ o((e, n) => {
|
|
1031
1038
|
const t = e.split(/\s+/).filter(Boolean);
|
|
1032
1039
|
return t.includes(n) ? e : [...t, n].join(" ");
|
|
1033
|
-
}, "appendTreeGridClassToken"),
|
|
1034
|
-
if (!
|
|
1040
|
+
}, "appendTreeGridClassToken"), hr = /* @__PURE__ */ o((e, n, t, r) => !Ee(e, n, t) || !n ? r : K(r, yn), "appendTreeGridErrorCellDisplayClass"), Rr = /* @__PURE__ */ o((e, n, t, r) => {
|
|
1041
|
+
if (!A(n) || cn(n) || !P(n) && !I(n) || pr(e, n) || V(e, n, t))
|
|
1035
1042
|
return r;
|
|
1036
|
-
const i =
|
|
1043
|
+
const i = zt(e);
|
|
1037
1044
|
if (!i.columnSet.has(t))
|
|
1038
1045
|
return r;
|
|
1039
|
-
let c = K(r,
|
|
1040
|
-
return t === i.firstColumn && (c = K(c,
|
|
1041
|
-
}, "appendTreeGridAddedRowBoxDisplayClass"),
|
|
1042
|
-
const i =
|
|
1046
|
+
let c = K(r, Dn);
|
|
1047
|
+
return t === i.firstColumn && (c = K(c, Pn)), t === i.lastColumn && (c = K(c, $n)), c;
|
|
1048
|
+
}, "appendTreeGridAddedRowBoxDisplayClass"), Ar = /* @__PURE__ */ o((e, n, t, r) => {
|
|
1049
|
+
const i = hr(e, n, t, r), c = Rr(
|
|
1043
1050
|
e,
|
|
1044
1051
|
n,
|
|
1045
1052
|
t,
|
|
@@ -1047,29 +1054,29 @@ ${e.slice(
|
|
|
1047
1054
|
);
|
|
1048
1055
|
if (!V(e, n, t))
|
|
1049
1056
|
return c === r ? void 0 : c;
|
|
1050
|
-
const
|
|
1051
|
-
return
|
|
1052
|
-
}, "resolveTreeGridCellDisplayClass"),
|
|
1053
|
-
const t = n.filter(
|
|
1057
|
+
const a = or(c) ?? c;
|
|
1058
|
+
return a === r ? void 0 : a;
|
|
1059
|
+
}, "resolveTreeGridCellDisplayClass"), Cn = /* @__PURE__ */ o((e) => A(e) && (P(e) || I(e)), "isTreeGridAddedRowBoxDisplayRow"), Me = /* @__PURE__ */ o((e, n) => {
|
|
1060
|
+
const t = n.filter(Cn);
|
|
1054
1061
|
t.length && M(e, t);
|
|
1055
|
-
}, "scheduleTreeGridAddedRowBoxRowsRefresh"),
|
|
1056
|
-
M(e, U(e).filter(
|
|
1057
|
-
}, "scheduleTreeGridAddedRowBoxRowsRefreshAll"),
|
|
1062
|
+
}, "scheduleTreeGridAddedRowBoxRowsRefresh"), gr = /* @__PURE__ */ o((e) => {
|
|
1063
|
+
M(e, U(e).filter(Cn));
|
|
1064
|
+
}, "scheduleTreeGridAddedRowBoxRowsRefreshAll"), vr = /* @__PURE__ */ o((e) => {
|
|
1058
1065
|
if (!e)
|
|
1059
1066
|
return !1;
|
|
1060
1067
|
if (typeof e.GetFirst == "function" && typeof e.GetNext == "function") {
|
|
1061
1068
|
let n = e.GetFirst();
|
|
1062
1069
|
for (; n; ) {
|
|
1063
|
-
if (
|
|
1070
|
+
if (A(n))
|
|
1064
1071
|
return !0;
|
|
1065
1072
|
n = e.GetNext(n);
|
|
1066
1073
|
}
|
|
1067
1074
|
return !1;
|
|
1068
1075
|
}
|
|
1069
|
-
return Object.values(e.Rows ?? {}).some((n) =>
|
|
1070
|
-
}, "hasTreeGridDisplayDataRows"),
|
|
1076
|
+
return Object.values(e.Rows ?? {}).some((n) => A(n));
|
|
1077
|
+
}, "hasTreeGridDisplayDataRows"), Br = /* @__PURE__ */ o((e, n, t) => {
|
|
1071
1078
|
var i;
|
|
1072
|
-
|
|
1079
|
+
x(e);
|
|
1073
1080
|
const r = (i = e.Data) == null ? void 0 : i.Data;
|
|
1074
1081
|
e.Data.Data = {
|
|
1075
1082
|
...r,
|
|
@@ -1083,36 +1090,36 @@ ${e.slice(
|
|
|
1083
1090
|
highlightEditableCellsRef: r,
|
|
1084
1091
|
highlightChangedCellsRef: i,
|
|
1085
1092
|
syncDeletedRowCanEditRef: c,
|
|
1086
|
-
editableCellBackgroundColorValueRef:
|
|
1087
|
-
changedCellBackgroundColorRef:
|
|
1093
|
+
editableCellBackgroundColorValueRef: a,
|
|
1094
|
+
changedCellBackgroundColorRef: f,
|
|
1088
1095
|
focusedCellBackgroundColorRef: C,
|
|
1089
|
-
selectedCellBackgroundColorRef:
|
|
1096
|
+
selectedCellBackgroundColorRef: p,
|
|
1090
1097
|
hoverCellBackgroundColorRef: S,
|
|
1091
|
-
changedCellBaselineRef:
|
|
1098
|
+
changedCellBaselineRef: R,
|
|
1092
1099
|
treeGridInstanceRef: m,
|
|
1093
1100
|
treeGridInitStartedAtRef: L,
|
|
1094
|
-
latestLayoutOverridesRef:
|
|
1095
|
-
latestToolbarTotalCountFormulaRef:
|
|
1096
|
-
latestSuppressCfgRef:
|
|
1101
|
+
latestLayoutOverridesRef: w,
|
|
1102
|
+
latestToolbarTotalCountFormulaRef: Ge,
|
|
1103
|
+
latestSuppressCfgRef: pe,
|
|
1097
1104
|
latestHideChildHeaderSortButtonsRef: z,
|
|
1098
|
-
latestSelectionScopeRef:
|
|
1105
|
+
latestSelectionScopeRef: En,
|
|
1099
1106
|
latestDisabledAnimationsRef: Se,
|
|
1100
|
-
appliedLayoutOverridesRef:
|
|
1107
|
+
appliedLayoutOverridesRef: Gn,
|
|
1101
1108
|
appliedBodyDataPropRef: pn,
|
|
1102
1109
|
hasAppliedInitialLayoutRef: he,
|
|
1103
1110
|
syncHasDisplayDataRows: $,
|
|
1104
|
-
setIsTreeGridReady:
|
|
1105
|
-
showErrorTooltip:
|
|
1111
|
+
setIsTreeGridReady: Sn,
|
|
1112
|
+
showErrorTooltip: hn,
|
|
1106
1113
|
hideErrorTooltip: D
|
|
1107
1114
|
}) => {
|
|
1108
|
-
const
|
|
1115
|
+
const _ = n.current;
|
|
1109
1116
|
if (window.TGSetEvent("OnRowAdd", e, (s, l) => {
|
|
1110
1117
|
var d, u;
|
|
1111
|
-
|
|
1118
|
+
x(s), l.CanEdit = 1, l.CanDelete = 1, (u = (d = n.current) == null ? void 0 : d.onRowAdd) == null || u.call(d, s, l);
|
|
1112
1119
|
}), window.TGSetEvent("OnRowAdded", e, (s) => {
|
|
1113
|
-
|
|
1120
|
+
x(s), $(s);
|
|
1114
1121
|
}), window.TGSetEvent("OnRowRemove", e, (s) => {
|
|
1115
|
-
|
|
1122
|
+
x(s), D(), $(s);
|
|
1116
1123
|
}), window.TGSetEvent("OnColShow", e, (s) => {
|
|
1117
1124
|
v(s);
|
|
1118
1125
|
}), window.TGSetEvent("OnAfterColumnsChanged", e, (s) => {
|
|
@@ -1125,81 +1132,81 @@ ${e.slice(
|
|
|
1125
1132
|
v(s);
|
|
1126
1133
|
}), window.TGSetEvent("OnColUndelete", e, (s) => {
|
|
1127
1134
|
v(s);
|
|
1128
|
-
}), window.TGSetEvent("OnMouseOver", e, (s, l, d, u, T,
|
|
1129
|
-
const
|
|
1130
|
-
if (!
|
|
1135
|
+
}), window.TGSetEvent("OnMouseOver", e, (s, l, d, u, T, G) => {
|
|
1136
|
+
const E = de(s, l, d);
|
|
1137
|
+
if (!E) {
|
|
1131
1138
|
D();
|
|
1132
1139
|
return;
|
|
1133
1140
|
}
|
|
1134
|
-
const
|
|
1135
|
-
if (!
|
|
1141
|
+
const h = ar(G);
|
|
1142
|
+
if (!h) {
|
|
1136
1143
|
D();
|
|
1137
1144
|
return;
|
|
1138
1145
|
}
|
|
1139
|
-
s.HideTip(),
|
|
1146
|
+
s.HideTip(), hn({ anchorEl: h, row: l, col: d, message: E });
|
|
1140
1147
|
}), window.TGSetEvent("OnFocus", e, (s, l, d, u) => {
|
|
1141
|
-
l !== u &&
|
|
1148
|
+
l !== u && Me(s, [l, u]);
|
|
1142
1149
|
}), window.TGSetEvent("OnTip", e, (s, l, d, u) => de(s, l, d) ? "" : u), window.TGSetEvent("OnCanRowDelete", e, (s, l, d) => {
|
|
1143
|
-
var
|
|
1150
|
+
var G;
|
|
1144
1151
|
if (d !== 3)
|
|
1145
1152
|
return d;
|
|
1146
|
-
const u = (
|
|
1153
|
+
const u = (G = n.current) == null ? void 0 : G.onBeforeRowUndelete;
|
|
1147
1154
|
if (typeof u != "function")
|
|
1148
1155
|
return d;
|
|
1149
|
-
const T = /* @__PURE__ */ o((
|
|
1156
|
+
const T = /* @__PURE__ */ o((E) => {
|
|
1150
1157
|
window.setTimeout(() => {
|
|
1151
|
-
|
|
1158
|
+
Mt(
|
|
1152
1159
|
m.current ?? s,
|
|
1153
1160
|
l,
|
|
1154
|
-
|
|
1161
|
+
E,
|
|
1155
1162
|
$
|
|
1156
1163
|
);
|
|
1157
1164
|
}, 0);
|
|
1158
1165
|
}, "scheduleAction");
|
|
1159
1166
|
try {
|
|
1160
|
-
const
|
|
1161
|
-
return
|
|
1167
|
+
const E = u(s, l);
|
|
1168
|
+
return Vt(E) ? (E.then(T).catch(() => {
|
|
1162
1169
|
T("undelete");
|
|
1163
|
-
}), 0) : (T(
|
|
1170
|
+
}), 0) : (T(E), 0);
|
|
1164
1171
|
} catch {
|
|
1165
1172
|
return T("undelete"), 0;
|
|
1166
1173
|
}
|
|
1167
|
-
}), typeof (
|
|
1168
|
-
const s = Y((l, d, u, T,
|
|
1169
|
-
var
|
|
1170
|
-
(
|
|
1171
|
-
|
|
1174
|
+
}), typeof (_ == null ? void 0 : _.onRowClick) == "function" || typeof (_ == null ? void 0 : _.onInternalCellClick) == "function") {
|
|
1175
|
+
const s = Y((l, d, u, T, G, E) => {
|
|
1176
|
+
var h, O;
|
|
1177
|
+
(O = (h = n.current) == null ? void 0 : h.onRowClick) == null || O.call(
|
|
1178
|
+
h,
|
|
1172
1179
|
l,
|
|
1173
1180
|
d,
|
|
1174
1181
|
u,
|
|
1175
1182
|
T,
|
|
1176
|
-
|
|
1177
|
-
|
|
1183
|
+
G,
|
|
1184
|
+
E
|
|
1178
1185
|
);
|
|
1179
1186
|
}, 300);
|
|
1180
|
-
window.TGSetEvent("OnClick", e, (l, d, u, T,
|
|
1181
|
-
var
|
|
1182
|
-
const
|
|
1183
|
-
|
|
1187
|
+
window.TGSetEvent("OnClick", e, (l, d, u, T, G, E) => {
|
|
1188
|
+
var O, Ae, ge;
|
|
1189
|
+
const h = (Ae = (O = n.current) == null ? void 0 : O.onInternalCellClick) == null ? void 0 : Ae.call(
|
|
1190
|
+
O,
|
|
1184
1191
|
l,
|
|
1185
1192
|
d,
|
|
1186
1193
|
u,
|
|
1187
1194
|
T,
|
|
1188
|
-
|
|
1189
|
-
|
|
1195
|
+
G,
|
|
1196
|
+
E
|
|
1190
1197
|
);
|
|
1191
|
-
if (
|
|
1192
|
-
return
|
|
1193
|
-
typeof ((ge = n.current) == null ? void 0 : ge.onRowClick) == "function" && s(l, d, u, T,
|
|
1198
|
+
if (h !== void 0)
|
|
1199
|
+
return h;
|
|
1200
|
+
typeof ((ge = n.current) == null ? void 0 : ge.onRowClick) == "function" && s(l, d, u, T, G, E);
|
|
1194
1201
|
});
|
|
1195
1202
|
}
|
|
1196
|
-
(typeof (
|
|
1203
|
+
(typeof (_ == null ? void 0 : _.onClickButton) == "function" || typeof (_ == null ? void 0 : _.onInternalButtonClick) == "function") && window.TGSetEvent(
|
|
1197
1204
|
"OnClickButton",
|
|
1198
1205
|
e,
|
|
1199
1206
|
(s, l, d, u) => {
|
|
1200
|
-
var
|
|
1201
|
-
const T = (
|
|
1202
|
-
|
|
1207
|
+
var G, E, h, O;
|
|
1208
|
+
const T = (E = (G = n.current) == null ? void 0 : G.onInternalButtonClick) == null ? void 0 : E.call(
|
|
1209
|
+
G,
|
|
1203
1210
|
s,
|
|
1204
1211
|
l,
|
|
1205
1212
|
d,
|
|
@@ -1207,27 +1214,27 @@ ${e.slice(
|
|
|
1207
1214
|
);
|
|
1208
1215
|
if (T !== void 0)
|
|
1209
1216
|
return T;
|
|
1210
|
-
(
|
|
1211
|
-
|
|
1217
|
+
(O = (h = n.current) == null ? void 0 : h.onClickButton) == null || O.call(
|
|
1218
|
+
h,
|
|
1212
1219
|
s,
|
|
1213
1220
|
l,
|
|
1214
1221
|
d,
|
|
1215
1222
|
u
|
|
1216
1223
|
);
|
|
1217
1224
|
}
|
|
1218
|
-
), typeof (
|
|
1225
|
+
), typeof (_ == null ? void 0 : _.onInternalKeyDown) == "function" && (window.TGSetEvent(
|
|
1219
1226
|
"OnKeyDown",
|
|
1220
1227
|
e,
|
|
1221
1228
|
(s, l, d, u, T) => {
|
|
1222
|
-
var
|
|
1223
|
-
return (
|
|
1229
|
+
var G, E;
|
|
1230
|
+
return (E = (G = n.current) == null ? void 0 : G.onInternalKeyDown) == null ? void 0 : E.call(G, s, l, d, u, T);
|
|
1224
1231
|
}
|
|
1225
1232
|
), window.TGSetEvent(
|
|
1226
1233
|
"OnKeyPress",
|
|
1227
1234
|
e,
|
|
1228
1235
|
(s, l, d, u, T) => {
|
|
1229
|
-
var
|
|
1230
|
-
return (
|
|
1236
|
+
var G, E;
|
|
1237
|
+
return (E = (G = n.current) == null ? void 0 : G.onInternalKeyDown) == null ? void 0 : E.call(G, s, l, d, u, T);
|
|
1231
1238
|
}
|
|
1232
1239
|
)), window.TGSetEvent("OnStartEdit", e, (s, l, d) => {
|
|
1233
1240
|
var u, T;
|
|
@@ -1238,87 +1245,91 @@ ${e.slice(
|
|
|
1238
1245
|
d
|
|
1239
1246
|
);
|
|
1240
1247
|
}), window.TGSetEvent("OnRowDelete", e, (s, l, d) => {
|
|
1241
|
-
var
|
|
1242
|
-
|
|
1243
|
-
const u =
|
|
1248
|
+
var h, O;
|
|
1249
|
+
x(s), D(), fr(s, l), s.SelectRow(l, 0);
|
|
1250
|
+
const u = I(l), T = u ? q(l) : [], G = u ? _e(l) : [], E = c.current !== !1;
|
|
1244
1251
|
Fe(s, l, {
|
|
1245
|
-
canEdit:
|
|
1246
|
-
|
|
1247
|
-
|
|
1248
|
-
T
|
|
1252
|
+
canEdit: E ? 2 : void 0,
|
|
1253
|
+
editableColumns: G,
|
|
1254
|
+
editableCanEdit: E && G.length ? 2 : void 0,
|
|
1255
|
+
highlightColumns: T
|
|
1256
|
+
}), $(s), (O = (h = n.current) == null ? void 0 : h.onRowDelete) == null || O.call(
|
|
1257
|
+
h,
|
|
1249
1258
|
s,
|
|
1250
1259
|
l,
|
|
1251
1260
|
d
|
|
1252
1261
|
);
|
|
1253
1262
|
}), window.TGSetEvent("OnRowUndelete", e, (s, l) => {
|
|
1254
|
-
var
|
|
1255
|
-
|
|
1256
|
-
const d =
|
|
1263
|
+
var E, h;
|
|
1264
|
+
x(s), D();
|
|
1265
|
+
const d = I(l), u = d ? q(l) : [], T = d ? _e(l) : [], G = c.current !== !1;
|
|
1257
1266
|
Fe(s, l, {
|
|
1258
|
-
canEdit:
|
|
1259
|
-
|
|
1260
|
-
|
|
1261
|
-
|
|
1267
|
+
canEdit: G ? 1 : void 0,
|
|
1268
|
+
editableColumns: T,
|
|
1269
|
+
editableCanEdit: G && T.length ? 1 : void 0,
|
|
1270
|
+
highlightColumns: u,
|
|
1271
|
+
highlightBackgroundColor: u.length ? f.current : void 0
|
|
1272
|
+
}), $(s), (h = (E = n.current) == null ? void 0 : E.onRowUndelete) == null || h.call(E, s, l);
|
|
1262
1273
|
}), window.TGSetEvent("OnGetDefaultColor", e, (s, l, d) => {
|
|
1263
|
-
if (!(!r.current || !
|
|
1264
|
-
return
|
|
1274
|
+
if (!(!r.current || !A(l)))
|
|
1275
|
+
return an(
|
|
1265
1276
|
s,
|
|
1266
1277
|
l,
|
|
1267
1278
|
d,
|
|
1268
|
-
|
|
1279
|
+
a.current
|
|
1269
1280
|
);
|
|
1270
|
-
}), window.TGSetEvent("OnGetColor", e, (s, l, d, u, T,
|
|
1271
|
-
if (!
|
|
1272
|
-
return
|
|
1281
|
+
}), window.TGSetEvent("OnGetColor", e, (s, l, d, u, T, G, E) => {
|
|
1282
|
+
if (!E)
|
|
1283
|
+
return Sr({
|
|
1273
1284
|
grid: s,
|
|
1274
1285
|
row: l,
|
|
1275
1286
|
col: d,
|
|
1276
1287
|
r: u,
|
|
1277
1288
|
g: T,
|
|
1278
|
-
b:
|
|
1289
|
+
b: G,
|
|
1279
1290
|
focusedCellBackgroundColor: C.current,
|
|
1280
|
-
selectedCellBackgroundColor:
|
|
1291
|
+
selectedCellBackgroundColor: p.current,
|
|
1281
1292
|
hoverCellBackgroundColor: S.current,
|
|
1282
|
-
changedCellBackgroundColor:
|
|
1283
|
-
editableCellBackgroundColorValue:
|
|
1293
|
+
changedCellBackgroundColor: f.current,
|
|
1294
|
+
editableCellBackgroundColorValue: a.current
|
|
1284
1295
|
});
|
|
1285
|
-
}), window.TGSetEvent("OnGetClass", e, (s, l, d, u) =>
|
|
1286
|
-
var
|
|
1287
|
-
if (D(), i.current &&
|
|
1288
|
-
const
|
|
1289
|
-
|
|
1296
|
+
}), window.TGSetEvent("OnGetClass", e, (s, l, d, u) => Ar(s, l, d, typeof u == "string" ? u : "")), window.TGSetEvent("OnAfterValueChanged", e, (s, l, d, u) => {
|
|
1297
|
+
var G, E;
|
|
1298
|
+
if (D(), i.current && A(l)) {
|
|
1299
|
+
const h = !Cr(s, l, d) || V(s, l, d) && !Te(s, l, d);
|
|
1300
|
+
tr({
|
|
1290
1301
|
gridId: e,
|
|
1291
1302
|
grid: s,
|
|
1292
1303
|
row: l,
|
|
1293
1304
|
col: d,
|
|
1294
|
-
backgroundColor:
|
|
1295
|
-
baselineMap:
|
|
1296
|
-
highlightRefresh:
|
|
1305
|
+
backgroundColor: f.current,
|
|
1306
|
+
baselineMap: R.current,
|
|
1307
|
+
highlightRefresh: h
|
|
1297
1308
|
});
|
|
1298
1309
|
}
|
|
1299
|
-
const T = ((
|
|
1310
|
+
const T = ((G = n.current) == null ? void 0 : G.onAfterValueChanged) ?? ((E = n.current) == null ? void 0 : E.onRowChange);
|
|
1300
1311
|
T == null || T(s, l, d, u);
|
|
1301
1312
|
});
|
|
1302
1313
|
const Re = Y((s) => {
|
|
1303
1314
|
var u, T;
|
|
1304
|
-
const l = s.GetSelRows() ?? [], d =
|
|
1305
|
-
selectionScope:
|
|
1315
|
+
const l = s.GetSelRows() ?? [], d = bn(s, l, {
|
|
1316
|
+
selectionScope: En.current
|
|
1306
1317
|
});
|
|
1307
1318
|
(T = (u = n.current) == null ? void 0 : u.onSelect) == null || T.call(
|
|
1308
1319
|
u,
|
|
1309
|
-
|
|
1320
|
+
_n(s, d)
|
|
1310
1321
|
);
|
|
1311
1322
|
}, 100);
|
|
1312
1323
|
window.TGSetEvent("OnSelect", e, (s, l, d, u, T) => {
|
|
1313
|
-
var
|
|
1324
|
+
var E;
|
|
1314
1325
|
if (T)
|
|
1315
1326
|
return;
|
|
1316
|
-
const
|
|
1317
|
-
|
|
1327
|
+
const G = Zt(s);
|
|
1328
|
+
cr(s, l), Me(s, [l]), M(s, G), lr(s, l), ve(s, e), typeof ((E = n.current) == null ? void 0 : E.onSelect) == "function" && Re(s);
|
|
1318
1329
|
}), window.TGSetEvent("OnSelectAll", e, (s, l, d, u) => {
|
|
1319
1330
|
var T;
|
|
1320
|
-
u || (
|
|
1321
|
-
}), typeof (
|
|
1331
|
+
u || (dr(s), gr(s), ve(s, e), typeof ((T = n.current) == null ? void 0 : T.onSelect) == "function" && Re(s));
|
|
1332
|
+
}), typeof (_ == null ? void 0 : _.onSave) == "function" && window.TGSetEvent("OnSave", e, (s, l, d) => {
|
|
1322
1333
|
var u, T;
|
|
1323
1334
|
(T = (u = n.current) == null ? void 0 : u.onSave) == null || T.call(
|
|
1324
1335
|
u,
|
|
@@ -1328,26 +1339,26 @@ ${e.slice(
|
|
|
1328
1339
|
);
|
|
1329
1340
|
}), window.TGSetEvent("OnSort", e, (s, l) => {
|
|
1330
1341
|
var d;
|
|
1331
|
-
if (!(!l || !
|
|
1342
|
+
if (!(!l || !Jt(
|
|
1332
1343
|
s,
|
|
1333
1344
|
s.ARow,
|
|
1334
1345
|
l,
|
|
1335
1346
|
z.current !== !1
|
|
1336
1347
|
)))
|
|
1337
|
-
return
|
|
1348
|
+
return Ke(e, "group header sort blocked"), vn(e, "group header sort blocked", {
|
|
1338
1349
|
rowId: (d = s.ARow) == null ? void 0 : d.id,
|
|
1339
1350
|
col: l
|
|
1340
1351
|
}), -1;
|
|
1341
1352
|
}), window.TGSetEvent("OnSortFinish", e, (s) => {
|
|
1342
|
-
|
|
1353
|
+
x(s);
|
|
1343
1354
|
}), window.TGSetEvent("OnFilterFinish", e, (s) => {
|
|
1344
|
-
|
|
1355
|
+
x(s);
|
|
1345
1356
|
}), window.TGSetEvent("OnGroupFinish", e, (s) => {
|
|
1346
|
-
|
|
1357
|
+
x(s);
|
|
1347
1358
|
}), window.TGSetEvent("OnSearchFinish", e, (s) => {
|
|
1348
|
-
|
|
1359
|
+
x(s);
|
|
1349
1360
|
}), window.TGSetEvent("OnRenderStart", e, (s) => {
|
|
1350
|
-
|
|
1361
|
+
x(s), ie(s, e), Ve(
|
|
1351
1362
|
s,
|
|
1352
1363
|
e,
|
|
1353
1364
|
!1,
|
|
@@ -1361,8 +1372,8 @@ ${e.slice(
|
|
|
1361
1372
|
const u = re(
|
|
1362
1373
|
d,
|
|
1363
1374
|
Se.current,
|
|
1364
|
-
|
|
1365
|
-
|
|
1375
|
+
Ge.current,
|
|
1376
|
+
pe.current
|
|
1366
1377
|
);
|
|
1367
1378
|
return u === d ? null : u;
|
|
1368
1379
|
}
|
|
@@ -1373,8 +1384,8 @@ ${e.slice(
|
|
|
1373
1384
|
const u = re(
|
|
1374
1385
|
d,
|
|
1375
1386
|
Se.current,
|
|
1376
|
-
|
|
1377
|
-
|
|
1387
|
+
Ge.current,
|
|
1388
|
+
pe.current
|
|
1378
1389
|
);
|
|
1379
1390
|
return u === d ? null : u;
|
|
1380
1391
|
}
|
|
@@ -1385,15 +1396,15 @@ ${e.slice(
|
|
|
1385
1396
|
Y((s) => {
|
|
1386
1397
|
var l, d;
|
|
1387
1398
|
if (!he.current) {
|
|
1388
|
-
const u =
|
|
1389
|
-
he.current = !0, !t.current && (s.EnterMode === void 0 || s.EnterMode === null || s.EnterMode === 0) &&
|
|
1399
|
+
const u = w.current;
|
|
1400
|
+
he.current = !0, !t.current && (s.EnterMode === void 0 || s.EnterMode === null || s.EnterMode === 0) && Nt(s, Nn), xn(s, u), m.current = s, Gn.current = u, pn.current = Ne(s), R.current = /* @__PURE__ */ new WeakMap(), qt(s, R.current), $(s), Sn(!0), Ve(
|
|
1390
1401
|
s,
|
|
1391
1402
|
e,
|
|
1392
1403
|
!0,
|
|
1393
1404
|
z.current !== !1
|
|
1394
|
-
),
|
|
1395
|
-
bodyRowCount:
|
|
1396
|
-
|
|
1405
|
+
), je(e, "TreeGrid init ready", L.current, {
|
|
1406
|
+
bodyRowCount: Kt(
|
|
1407
|
+
Ne(s)
|
|
1397
1408
|
)
|
|
1398
1409
|
}), L.current = null, (d = (l = n.current) == null ? void 0 : l.onReady) == null || d.call(l, s);
|
|
1399
1410
|
}
|
|
@@ -1401,14 +1412,14 @@ ${e.slice(
|
|
|
1401
1412
|
);
|
|
1402
1413
|
}, "bindTreeGridEvents");
|
|
1403
1414
|
export {
|
|
1404
|
-
|
|
1415
|
+
Pr as TREE_GRID_BINDING_LOADING_MIN_VISIBLE_MS,
|
|
1405
1416
|
Fr as bindTreeGridEvents,
|
|
1406
|
-
|
|
1407
|
-
|
|
1408
|
-
|
|
1409
|
-
|
|
1417
|
+
$r as buildTreeGridInitializationOptions,
|
|
1418
|
+
qt as captureTreeGridChangeBaselines,
|
|
1419
|
+
Kt as getTreeGridBodyDataCount,
|
|
1420
|
+
vr as hasTreeGridDisplayDataRows,
|
|
1410
1421
|
we as hasTreeGridExplicitEnterMode,
|
|
1411
|
-
|
|
1412
|
-
|
|
1422
|
+
Br as replaceTreeGridBodyData,
|
|
1423
|
+
tr as syncTreeGridChangedCellHighlight
|
|
1413
1424
|
};
|
|
1414
1425
|
//# sourceMappingURL=treeGridRuntime.js.map
|