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