@sheetxl/io-xlsx 0.8.0-beta.5 → 0.8.0-beta.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/browser/cjs/{DtBN3UOzNJjYBwJ6.cjs → 17tMBnuyu4YIxixh.cjs} +1 -1
- package/browser/cjs/BxU-OlZIQViQl7gX.cjs +1 -0
- package/browser/cjs/DHKWtqZ0vQfXrbq1.cjs +2 -0
- package/browser/cjs/DpZr07y7ifaZGvJ9.cjs +5 -0
- package/browser/cjs/{DULsYP_GcPGLVYSE.cjs → MqKQ_B5qRARrRbO4.cjs} +16 -3
- package/browser/cjs/index.cjs +1 -1
- package/browser/cjs/{DOTve1YXP86VW8ln.cjs → qb-YQ8mGwpogSP08.cjs} +1 -1
- package/browser/esm/{B9qJ5NSreEcSeTPX.mjs → 96C1ntelYWh7kQtW.mjs} +1 -1
- package/browser/esm/{B1yJJD4hEJtoWKFg.mjs → B0E-_6m23g4BDnX6.mjs} +2 -2
- package/browser/esm/{BcWQ-WWSh4k_BbiQ.mjs → B3cYXnqV2Zjaw6Jp.mjs} +4 -4
- package/browser/esm/{BIfJ7hj1nXfdThAg.mjs → BLEHoDT0SLbo8OO2.mjs} +1236 -1150
- package/browser/esm/{DZcQYS8AC3Q4KMNZ.mjs → BYENv_UE3Hv5ghGD.mjs} +599 -597
- package/browser/esm/{EvN99eSJ3aoJPumL.mjs → CGgjL7wM5WHZA6Dt.mjs} +2 -2
- package/browser/esm/{Cka8nUQmzdu2avsT.mjs → D01fs7vrCLlmdHoW.mjs} +899 -795
- package/browser/esm/{DJsvdO0gLkETZXLX.mjs → DdTgGiFy8nAZTQ0d.mjs} +2 -2
- package/browser/esm/{VMf5ikEX-Pl2qTh8.mjs → FwrsLfi1iEAQGIjj.mjs} +246 -154
- package/browser/esm/{CEbxib7xV2WuS-D3.mjs → gicSNvWtBLkvLsIw.mjs} +3 -3
- package/browser/esm/index.mjs +2 -2
- package/browser/esm/{CCD-nLdFzaQd6BuH.mjs → k-aEFzUZ8aU9FPf4.mjs} +1 -1
- package/node/esm/{CT9_4oNvQhBAW0fh.mjs → B-g20MoPHbZFapp8.mjs} +1652 -1545
- package/node/esm/{BJHtwV9ss8ol7zme.mjs → Bu9QkKpBW4G2ULAg.mjs} +177 -83
- package/node/esm/{CwK9xIdlW4XaFkip.mjs → CHl-WFsto0oTmBtB.mjs} +380 -288
- package/node/esm/{DqkQZkjIOnAGH7ah.mjs → Co5_sjvEk9d-x9gx.mjs} +576 -574
- package/node/esm/{DmlGXhQHqcwqLA05.mjs → D-l0hqYTXUIEFoTg.mjs} +2 -2
- package/node/esm/{CRjza0eYeRMSvbQf.mjs → DWF_5NYPdrlTVvHi.mjs} +1 -1
- package/node/esm/{CsrSCSuGVvpk7uBv.mjs → ZWSOYqmTKEmEOz2u.mjs} +2 -2
- package/node/esm/{C0lFi5Rstdk8y5VR.mjs → am47EU_k1uSVm7yW.mjs} +2 -2
- package/node/esm/index.mjs +4 -4
- package/package.json +3 -3
- package/types/src/reader/domVisitors/CommentVisitor.d.ts +7 -2
- package/types/src/reader/domVisitors/DrawingElementVisitor.d.ts +4 -0
- package/types/src/reader/domVisitors/ThreadedCommentVisitor.d.ts +9 -0
- package/types/src/utils/VmlNoteShapes.d.ts +82 -22
- package/types/src/writer/emitters/CommentsEmitter.d.ts +9 -3
- package/types/src/writer/emitters/ThreadedCommentsEmitter.d.ts +7 -1
- package/browser/cjs/C8oC1tPbhgR0Dqtx.cjs +0 -2
- package/browser/cjs/CUhvQ38mNlw3YIEp.cjs +0 -5
- package/browser/cjs/sNZR19Wk-XQ2xZ9E.cjs +0 -1
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @license @sheetxl/io-xlsx - SheetXL - Import/Export from/to Excel - v0.8.0-beta.
|
|
2
|
+
* @license @sheetxl/io-xlsx - SheetXL - Import/Export from/to Excel - v0.8.0-beta.6
|
|
3
3
|
*
|
|
4
4
|
* (C) 2026-present SheetXL Inc. & Michael T. Ford
|
|
5
5
|
* License: The license can be found at https://www.sheetxl.com/license.
|
|
6
6
|
*/
|
|
7
7
|
import { AddressUtils as e, FormulaError as r, FormulaText as t, FunctionDeclarations as n, ICalculation as o, ICondition as a, parseFormulaLiteral as s } from "@sheetxl/sdk";
|
|
8
|
-
var
|
|
8
|
+
var i = "http://schemas.microsoft.com/office/spreadsheetml/2009/9/main", E = "http://schemas.microsoft.com/office/excel/2006/main", l = "{CCE6A557-97BC-4b89-ADB6-D9C93CAAB3DF}", c = "{78C0D931-6437-407d-A8EE-F0AAD7539E65}", u = "{78C0D931-6839-4c89-B8D6-976A2CC4E5B4}", p = "{B025F937-C7B1-47D3-B67F-A62EFF666E3E}", T = "{A8765BA9-456A-4dab-B4F3-ACF838C121DE}", A = "{3A4CF648-6AED-40f4-86FF-DC5316D8AED3}", S = {
|
|
9
9
|
"{05C60535-1F16-4FD2-B633-F4F36F0B64E0}": "sparklines",
|
|
10
10
|
"{7E03D99C-DC04-49D9-9315-930204A7B6E9}": "timelines",
|
|
11
11
|
"{01252117-D84E-4E92-8308-4BE1C098FCBB}": "ignoredErrors",
|
|
12
12
|
"{F7C9EE02-42E1-4005-9D12-6889AFFD525C}": "workbook protection extensions"
|
|
13
|
-
},
|
|
14
|
-
function
|
|
13
|
+
}, f = /* @__PURE__ */ new Set(["{77BFE23E-C014-4D31-8A63-9C772DBF06B6}"]);
|
|
14
|
+
function R(e) {
|
|
15
15
|
return (e ?? "").toUpperCase();
|
|
16
16
|
}
|
|
17
17
|
function O(e) {
|
|
@@ -976,12 +976,12 @@ var y = "191029", M = "<ext uri=\"{B58B0392-4F1F-4190-BB64-5DF3571DCE5F}\" xmlns
|
|
|
976
976
|
["WEIBULL", {}],
|
|
977
977
|
["WEIBULL.DIST", { prefix: v }],
|
|
978
978
|
["YEAR", {}]
|
|
979
|
-
]),
|
|
979
|
+
]), g = (e) => "never" === d.get(e)?.intersect, h = (e, r) => !0 === d.get(e)?.slotNever?.includes(r), U = (e, r) => !0 === d.get(e)?.slotAlways?.includes(r), F = (e) => !0 === d.get(e)?.valueReturn, B = (e) => d.get(e)?.readsPerCell, G = (e) => "opens" === d.get(e)?.arrayScope, V = (e, r) => ({
|
|
980
980
|
type: "function",
|
|
981
981
|
value: e,
|
|
982
982
|
inputs: r ?? null
|
|
983
983
|
});
|
|
984
|
-
function
|
|
984
|
+
function b(e) {
|
|
985
985
|
return (r, t) => {
|
|
986
986
|
const n = r.type, o = r.value;
|
|
987
987
|
if ("function" === n) {
|
|
@@ -1039,10 +1039,10 @@ function W(e) {
|
|
|
1039
1039
|
var a;
|
|
1040
1040
|
};
|
|
1041
1041
|
}
|
|
1042
|
-
var
|
|
1042
|
+
var W = (e, r) => e.length > r.length && e.substring(0, r.length).toLowerCase() === r, H = (e) => {
|
|
1043
1043
|
if ("named" !== e?.type) return;
|
|
1044
1044
|
const r = e.value, t = r?.name;
|
|
1045
|
-
return !t || r.scope ||
|
|
1045
|
+
return !t || r.scope || W(t, "_xlpm.") ? void 0 : W(t, "_xleta.") ? t.substring(7) : t;
|
|
1046
1046
|
}, w = (e, r) => ({
|
|
1047
1047
|
...e,
|
|
1048
1048
|
value: {
|
|
@@ -1050,7 +1050,7 @@ var H = (e, r) => e.length > r.length && e.substring(0, r.length).toLowerCase()
|
|
|
1050
1050
|
scope: null
|
|
1051
1051
|
}
|
|
1052
1052
|
}), Y = (e, r) => {
|
|
1053
|
-
const t =
|
|
1053
|
+
const t = H(e);
|
|
1054
1054
|
if (void 0 !== t) return t.toUpperCase() === r ? w(e, t) : e;
|
|
1055
1055
|
const n = e.inputs;
|
|
1056
1056
|
if (!n) return e;
|
|
@@ -1071,11 +1071,11 @@ var H = (e, r) => e.length > r.length && e.substring(0, r.length).toLowerCase()
|
|
|
1071
1071
|
let o;
|
|
1072
1072
|
const a = (e) => (o ?? t)[e], s = (e, r) => {
|
|
1073
1073
|
r !== a(e) && (o || (o = [...t]), o[e] = r);
|
|
1074
|
-
},
|
|
1075
|
-
if ("LAMBDA" === r) for (let e = 0; e < n - 1; e++)
|
|
1076
|
-
else for (let e = 0; e + 1 < n; e += 2)
|
|
1077
|
-
for (const [e, r] of
|
|
1078
|
-
const t = a(e), o =
|
|
1074
|
+
}, i = [];
|
|
1075
|
+
if ("LAMBDA" === r) for (let e = 0; e < n - 1; e++) i.push([e, n - 1]);
|
|
1076
|
+
else for (let e = 0; e + 1 < n; e += 2) i.push([e, e + 2]);
|
|
1077
|
+
for (const [e, r] of i) {
|
|
1078
|
+
const t = a(e), o = H(t);
|
|
1079
1079
|
if (void 0 === o) continue;
|
|
1080
1080
|
s(e, !0 === t.value?.optional ? {
|
|
1081
1081
|
...t,
|
|
@@ -1084,10 +1084,10 @@ var H = (e, r) => e.length > r.length && e.substring(0, r.length).toLowerCase()
|
|
|
1084
1084
|
scope: null
|
|
1085
1085
|
}
|
|
1086
1086
|
} : w(t, o));
|
|
1087
|
-
const
|
|
1087
|
+
const i = o.toUpperCase();
|
|
1088
1088
|
for (let e = r; e < n; e++) {
|
|
1089
1089
|
const r = a(e);
|
|
1090
|
-
r && s(e, Y(r,
|
|
1090
|
+
r && s(e, Y(r, i));
|
|
1091
1091
|
}
|
|
1092
1092
|
}
|
|
1093
1093
|
return o;
|
|
@@ -1155,7 +1155,7 @@ function k() {
|
|
|
1155
1155
|
};
|
|
1156
1156
|
} else if ("named" === r) {
|
|
1157
1157
|
const r = e.value, t = r?.name ?? "";
|
|
1158
|
-
if (
|
|
1158
|
+
if (W(t, "_xlop.")) {
|
|
1159
1159
|
const n = _(t.substring(6));
|
|
1160
1160
|
return {
|
|
1161
1161
|
...e,
|
|
@@ -1209,14 +1209,14 @@ var q = (e) => {
|
|
|
1209
1209
|
if (!t) return !1;
|
|
1210
1210
|
for (let e = 0; e < t.length; e++) if (Q(t[e])) return !0;
|
|
1211
1211
|
return !1;
|
|
1212
|
-
},
|
|
1212
|
+
}, z = (e, r) => {
|
|
1213
1213
|
if (!e) return !1;
|
|
1214
1214
|
if (ue(e, r)) return !0;
|
|
1215
1215
|
const t = e.inputs;
|
|
1216
1216
|
if (!t) return !1;
|
|
1217
|
-
for (let e = 0; e < t.length; e++) if (
|
|
1217
|
+
for (let e = 0; e < t.length; e++) if (z(t[e], r)) return !0;
|
|
1218
1218
|
return !1;
|
|
1219
|
-
},
|
|
1219
|
+
}, Z = /* @__PURE__ */ new Set([
|
|
1220
1220
|
"+",
|
|
1221
1221
|
"-",
|
|
1222
1222
|
"*",
|
|
@@ -1294,32 +1294,32 @@ var q = (e) => {
|
|
|
1294
1294
|
return -1;
|
|
1295
1295
|
}, se = (e, r, t) => {
|
|
1296
1296
|
const n = oe(r), o = ae(n, t);
|
|
1297
|
-
return o < 0 ? null : !!
|
|
1298
|
-
},
|
|
1297
|
+
return o < 0 ? null : !!U(e, o) || !g(e) && !h(e, o) && !n.accepts[o];
|
|
1298
|
+
}, ie = (e, r) => r && "function" === e.type ? !((e) => {
|
|
1299
1299
|
const r = d.get(e)?.arrayScope;
|
|
1300
1300
|
return "consumer" === r || "lazy" === r;
|
|
1301
|
-
})(te(e)) : r,
|
|
1302
|
-
const n =
|
|
1301
|
+
})(te(e)) : r, Ee = (e, r, t) => {
|
|
1302
|
+
const n = ie(e, t);
|
|
1303
1303
|
if ("function" !== e.type) return () => n;
|
|
1304
1304
|
const o = te(e), a = G(o), s = n && void 0 !== ((e) => d.get(e))(o)?.scopeClears;
|
|
1305
1305
|
if (!a && !s) return () => n;
|
|
1306
|
-
const
|
|
1307
|
-
if (!
|
|
1308
|
-
const
|
|
1306
|
+
const i = r.getFunction(o);
|
|
1307
|
+
if (!i) return () => n;
|
|
1308
|
+
const E = oe(i);
|
|
1309
1309
|
return (e) => {
|
|
1310
|
-
const r = ae(
|
|
1310
|
+
const r = ae(E, e);
|
|
1311
1311
|
return !(r >= 0 && ((e, r) => !0 === d.get(e)?.scopeClears?.includes(r))(o, r)) && (n || ((e, r, t) => {
|
|
1312
1312
|
if (!G(e) || !r.isBuiltIn()) return !1;
|
|
1313
1313
|
const n = oe(r), o = ae(n, t);
|
|
1314
|
-
return !(o < 0) && !
|
|
1315
|
-
})(o,
|
|
1314
|
+
return !(o < 0) && !U(e, o) && n.accepts[o];
|
|
1315
|
+
})(o, i, e));
|
|
1316
1316
|
};
|
|
1317
|
-
},
|
|
1317
|
+
}, le = (e, r, t) => {
|
|
1318
1318
|
if (!t) return () => !1;
|
|
1319
1319
|
const n = e.type;
|
|
1320
1320
|
if ("paren" === n) return () => !0;
|
|
1321
1321
|
if ("prefix" === n) return () => J.has(e.value);
|
|
1322
|
-
if ("infix" === n) return () =>
|
|
1322
|
+
if ("infix" === n) return () => Z.has(e.value);
|
|
1323
1323
|
if ("function" !== n) return () => !1;
|
|
1324
1324
|
const o = r.getFunction(te(e));
|
|
1325
1325
|
if (!o) return () => !1;
|
|
@@ -1328,18 +1328,18 @@ var q = (e) => {
|
|
|
1328
1328
|
const r = ae(a, e);
|
|
1329
1329
|
return r >= 0 && !a.accepts[r];
|
|
1330
1330
|
};
|
|
1331
|
-
},
|
|
1331
|
+
}, ce = (e, r, t, n) => {
|
|
1332
1332
|
if (!e) return !1;
|
|
1333
1333
|
const o = e.type;
|
|
1334
1334
|
if ("prefix" === o) {
|
|
1335
1335
|
const o = e.value;
|
|
1336
|
-
return "@" !== o && !!J.has(o) &&
|
|
1336
|
+
return "@" !== o && !!J.has(o) && ce(e.inputs?.[0], r, t, n);
|
|
1337
1337
|
}
|
|
1338
1338
|
if ("infix" === o && j.has(e.value)) return !0;
|
|
1339
1339
|
if ("postfix" === o && "#" === e.value) return !0;
|
|
1340
1340
|
if ("tableReference" === o) return !0;
|
|
1341
1341
|
if ("array" === o) return n;
|
|
1342
|
-
if ("paren" === o) return
|
|
1342
|
+
if ("paren" === o) return ce(e.inputs?.[0], r, t, n);
|
|
1343
1343
|
if ("cell" === o) {
|
|
1344
1344
|
const r = ee(e);
|
|
1345
1345
|
return null !== r && !(1 === r.rows && 1 === r.cols);
|
|
@@ -1352,12 +1352,12 @@ var q = (e) => {
|
|
|
1352
1352
|
t.add(a);
|
|
1353
1353
|
try {
|
|
1354
1354
|
const e = r.getNamedRoot(o, n.scope);
|
|
1355
|
-
return !!e &&
|
|
1355
|
+
return !!e && ce(e, r, t, !0);
|
|
1356
1356
|
} finally {
|
|
1357
1357
|
t.delete(a);
|
|
1358
1358
|
}
|
|
1359
1359
|
}
|
|
1360
|
-
if ("infix" === o &&
|
|
1360
|
+
if ("infix" === o && Z.has(e.value)) return ce(e.inputs?.[0], r, t, n) || ce(e.inputs?.[1], r, t, n);
|
|
1361
1361
|
if ("call" === o) return ue(e, r);
|
|
1362
1362
|
if ("function" === o) {
|
|
1363
1363
|
const o = te(e), a = r.getFunction(o);
|
|
@@ -1370,9 +1370,9 @@ var q = (e) => {
|
|
|
1370
1370
|
switch (r) {
|
|
1371
1371
|
case "OFFSET": {
|
|
1372
1372
|
const e = a[3], r = a[4];
|
|
1373
|
-
if (void 0 === e && void 0 === r) return
|
|
1374
|
-
const t = s ? ee(s) : null,
|
|
1375
|
-
return !(
|
|
1373
|
+
if (void 0 === e && void 0 === r) return ce(s, n, o, !0);
|
|
1374
|
+
const t = s ? ee(s) : null, i = void 0 === e ? 1 === t?.rows : 1 === re(e), E = void 0 === r ? 1 === t?.cols : 1 === re(r);
|
|
1375
|
+
return !(i && E);
|
|
1376
1376
|
}
|
|
1377
1377
|
case "INDEX": {
|
|
1378
1378
|
const e = a[1], r = a[2], t = s ? ee(s) : null;
|
|
@@ -1385,7 +1385,7 @@ var q = (e) => {
|
|
|
1385
1385
|
return !(n(e, t?.rows) && n(r, t?.cols));
|
|
1386
1386
|
}
|
|
1387
1387
|
case "XLOOKUP": {
|
|
1388
|
-
if (a[3] &&
|
|
1388
|
+
if (a[3] && ce(a[3], n, o, !0)) return !0;
|
|
1389
1389
|
const e = a[1] ? ee(a[1]) : null, r = a[2] ? ee(a[2]) : null;
|
|
1390
1390
|
return !(e && r && (1 === e.rows && 1 === e.cols ? 1 === r.rows && 1 === r.cols : 1 === e.cols ? 1 === r.cols : 1 === e.rows && 1 === r.rows));
|
|
1391
1391
|
}
|
|
@@ -1393,17 +1393,17 @@ var q = (e) => {
|
|
|
1393
1393
|
}
|
|
1394
1394
|
})(e, o, a, r, t);
|
|
1395
1395
|
if (null !== s) return s;
|
|
1396
|
-
const
|
|
1397
|
-
if (void 0 !==
|
|
1396
|
+
const i = B(o);
|
|
1397
|
+
if (void 0 !== i && a.isBuiltIn()) return ce(e.inputs?.[i], r, t, !0);
|
|
1398
1398
|
if (a.isBuiltIn() && ((e) => !0 === d.get(e)?.arrayReturn)(o)) return !0;
|
|
1399
|
-
const
|
|
1400
|
-
if (null !==
|
|
1401
|
-
const
|
|
1402
|
-
if (null !==
|
|
1403
|
-
const
|
|
1404
|
-
if (!
|
|
1405
|
-
const u =
|
|
1406
|
-
for (let e = 0; e <
|
|
1399
|
+
const E = a.getDeclaration().getReturnType();
|
|
1400
|
+
if (null !== E.getRangeType()) return !0;
|
|
1401
|
+
const l = a.isBuiltIn() && F(o);
|
|
1402
|
+
if (null !== E.getScalarType() && !l) return !1;
|
|
1403
|
+
const c = e.inputs;
|
|
1404
|
+
if (!c) return !1;
|
|
1405
|
+
const u = l || n;
|
|
1406
|
+
for (let e = 0; e < c.length; e++) if (ce(c[e], r, t, u)) return !0;
|
|
1407
1407
|
return !1;
|
|
1408
1408
|
}
|
|
1409
1409
|
return !1;
|
|
@@ -1417,65 +1417,65 @@ var q = (e) => {
|
|
|
1417
1417
|
return !!n?.name && r.hasFunctions() && null === r.getNamedRoot(n.name, n.scope);
|
|
1418
1418
|
}
|
|
1419
1419
|
return !1;
|
|
1420
|
-
},
|
|
1420
|
+
}, pe = (e, r, t) => {
|
|
1421
1421
|
if (!e || "function" !== e.type) return !1;
|
|
1422
1422
|
const n = te(e);
|
|
1423
|
-
return !(!F(n) && void 0 === B(n)) && !!r.getFunction(n)?.isBuiltIn() &&
|
|
1424
|
-
},
|
|
1423
|
+
return !(!F(n) && void 0 === B(n)) && !!r.getFunction(n)?.isBuiltIn() && ce(e, r, t, !0);
|
|
1424
|
+
}, Te = (e, r, t, n = !1, o = !1) => {
|
|
1425
1425
|
const a = e.inputs;
|
|
1426
1426
|
if (!a) return null;
|
|
1427
|
-
if (
|
|
1428
|
-
const s = e.type,
|
|
1429
|
-
let
|
|
1430
|
-
if ("infix" === s &&
|
|
1431
|
-
for (let e = 0; e < 2; e++)
|
|
1432
|
-
return
|
|
1427
|
+
if (ie(e, n)) return null;
|
|
1428
|
+
const s = e.type, i = le(e, r, o);
|
|
1429
|
+
let E = null;
|
|
1430
|
+
if ("infix" === s && Z.has(e.value)) {
|
|
1431
|
+
for (let e = 0; e < 2; e++) ce(a[e], r, t, i(e)) && (E ??= []).push(e);
|
|
1432
|
+
return E;
|
|
1433
1433
|
}
|
|
1434
|
-
if ("prefix" === s && J.has(e.value)) return
|
|
1434
|
+
if ("prefix" === s && J.has(e.value)) return ce(a[0], r, t, i(0)) && (E = [0]), E;
|
|
1435
1435
|
if ("function" !== s) return null;
|
|
1436
|
-
const
|
|
1437
|
-
if (!
|
|
1438
|
-
const u = oe(
|
|
1436
|
+
const l = te(e), c = r.getFunction(l);
|
|
1437
|
+
if (!c) return null;
|
|
1438
|
+
const u = oe(c);
|
|
1439
1439
|
for (let e = 0; e < a.length; e++) {
|
|
1440
|
-
const n = se(
|
|
1440
|
+
const n = se(l, c, e);
|
|
1441
1441
|
if (null === n) break;
|
|
1442
1442
|
if (n) {
|
|
1443
|
-
|
|
1443
|
+
ce(a[e], r, t, i(e)) && (E ??= []).push(e);
|
|
1444
1444
|
continue;
|
|
1445
1445
|
}
|
|
1446
|
-
if (
|
|
1446
|
+
if (g(l)) continue;
|
|
1447
1447
|
const o = ae(u, e);
|
|
1448
|
-
o < 0 || !u.valueTyped[o] ||
|
|
1448
|
+
o < 0 || !u.valueTyped[o] || h(l, o) || pe(a[e], r, t) && (E ??= []).push(e);
|
|
1449
1449
|
}
|
|
1450
|
-
return
|
|
1451
|
-
},
|
|
1450
|
+
return E;
|
|
1451
|
+
}, Ae = (e) => {
|
|
1452
1452
|
const r = "paren" === e?.type ? e.inputs?.[0] : void 0;
|
|
1453
1453
|
return r ? {
|
|
1454
1454
|
...e,
|
|
1455
|
-
inputs: [
|
|
1455
|
+
inputs: [Ae(r)]
|
|
1456
1456
|
} : {
|
|
1457
1457
|
type: "prefix",
|
|
1458
1458
|
value: "@",
|
|
1459
1459
|
inputs: [e],
|
|
1460
1460
|
isReference: !0
|
|
1461
1461
|
};
|
|
1462
|
-
},
|
|
1462
|
+
}, Se = (e, r) => {
|
|
1463
1463
|
if (!e) return !1;
|
|
1464
1464
|
const t = /* @__PURE__ */ new Set();
|
|
1465
|
-
if (
|
|
1465
|
+
if (ce(e, r, t, !0)) return !0;
|
|
1466
1466
|
let n = !1;
|
|
1467
1467
|
const o = (e, a, s) => {
|
|
1468
1468
|
if (n || !e) return;
|
|
1469
1469
|
if ("call" === e.type && !ue(e, r)) return void (n = !0);
|
|
1470
|
-
if (
|
|
1471
|
-
const
|
|
1472
|
-
if (!
|
|
1473
|
-
const
|
|
1474
|
-
for (let e = 0; e <
|
|
1470
|
+
if (Te(e, r, t, a, s)) return void (n = !0);
|
|
1471
|
+
const i = e.inputs;
|
|
1472
|
+
if (!i) return;
|
|
1473
|
+
const E = Ee(e, r, a), l = le(e, r, s);
|
|
1474
|
+
for (let e = 0; e < i.length && !n; e++) i[e] && o(i[e], E(e), l(e));
|
|
1475
1475
|
};
|
|
1476
1476
|
return o(e, !1, !0), n;
|
|
1477
1477
|
};
|
|
1478
|
-
function
|
|
1478
|
+
function fe(e) {
|
|
1479
1479
|
const r = k();
|
|
1480
1480
|
return {
|
|
1481
1481
|
base: (e, t) => {
|
|
@@ -1489,37 +1489,37 @@ function Re(e) {
|
|
|
1489
1489
|
if (!e) return e;
|
|
1490
1490
|
const t = /* @__PURE__ */ new Set(), n = (e, o, a) => {
|
|
1491
1491
|
const s = e.inputs;
|
|
1492
|
-
let
|
|
1492
|
+
let i = e;
|
|
1493
1493
|
if (s) {
|
|
1494
|
-
const t =
|
|
1495
|
-
let
|
|
1494
|
+
const t = Ee(e, r, o), E = le(e, r, a);
|
|
1495
|
+
let l;
|
|
1496
1496
|
for (let e = 0; e < s.length; e++) {
|
|
1497
1497
|
const r = s[e];
|
|
1498
1498
|
if (!r) continue;
|
|
1499
|
-
const o = n(r, t(e),
|
|
1500
|
-
o !== r && (
|
|
1499
|
+
const o = n(r, t(e), E(e));
|
|
1500
|
+
o !== r && (l || (l = [...s]), l[e] = o);
|
|
1501
1501
|
}
|
|
1502
|
-
|
|
1502
|
+
l && (i = {
|
|
1503
1503
|
...e,
|
|
1504
|
-
inputs:
|
|
1504
|
+
inputs: l
|
|
1505
1505
|
});
|
|
1506
1506
|
}
|
|
1507
|
-
const
|
|
1508
|
-
if (!
|
|
1509
|
-
const
|
|
1510
|
-
for (const e of
|
|
1507
|
+
const E = Te(i, r, t, o, a);
|
|
1508
|
+
if (!E) return i;
|
|
1509
|
+
const l = [...i.inputs];
|
|
1510
|
+
for (const e of E) l[e] = Ae(l[e]);
|
|
1511
1511
|
return {
|
|
1512
|
-
...
|
|
1513
|
-
inputs:
|
|
1512
|
+
...i,
|
|
1513
|
+
inputs: l
|
|
1514
1514
|
};
|
|
1515
1515
|
}, o = n(e, !1, !0);
|
|
1516
|
-
return
|
|
1516
|
+
return ce(o, r, t, !0) ? Ae(o) : o;
|
|
1517
1517
|
})(o, e);
|
|
1518
1518
|
return a === t ? void 0 : a;
|
|
1519
1519
|
}
|
|
1520
1520
|
};
|
|
1521
1521
|
}
|
|
1522
|
-
var
|
|
1522
|
+
var Re = "xlsxFormulaDialect";
|
|
1523
1523
|
function Oe(e, r) {
|
|
1524
1524
|
const o = /* @__PURE__ */ new Set();
|
|
1525
1525
|
if (r) for (let e = 0; e < r.length; e++) o.add(String(r[e]).toUpperCase());
|
|
@@ -1530,34 +1530,34 @@ function Oe(e, r) {
|
|
|
1530
1530
|
let o = a.get(n);
|
|
1531
1531
|
o || a.set(n, o = []), o.push(t);
|
|
1532
1532
|
}
|
|
1533
|
-
const s = k(),
|
|
1533
|
+
const s = k(), i = /* @__PURE__ */ new Map(), E = {
|
|
1534
1534
|
getFunction: (e) => n.get(e),
|
|
1535
1535
|
hasFunctions: () => !0,
|
|
1536
1536
|
getNamedRoot: (e, r) => {
|
|
1537
1537
|
const n = a.get(e.toUpperCase());
|
|
1538
1538
|
if (!n) return null;
|
|
1539
|
-
const o = r ? r.toUpperCase() : null,
|
|
1540
|
-
if ("string" != typeof
|
|
1541
|
-
const
|
|
1539
|
+
const o = r ? r.toUpperCase() : null, E = o ? n.find((e) => String(e.scope ?? "").toUpperCase() === o) ?? n[0] : n.find((e) => !e.scope) ?? n[0], l = E?.ref;
|
|
1540
|
+
if ("string" != typeof l) return null;
|
|
1541
|
+
const c = `${String(E.scope ?? "").toUpperCase()}!${e.toUpperCase()}`, u = i.get(c);
|
|
1542
1542
|
if (void 0 !== u) return u;
|
|
1543
|
-
const
|
|
1544
|
-
return
|
|
1543
|
+
const p = t.parse(l), T = p ? t.transform(p, s) : null;
|
|
1544
|
+
return i.set(c, T), T;
|
|
1545
1545
|
}
|
|
1546
|
-
},
|
|
1546
|
+
}, l = fe(E), c = b({ has: (e) => a.has(e.toUpperCase()) }), u = function(e, r) {
|
|
1547
1547
|
const t = k();
|
|
1548
1548
|
return (n, o) => {
|
|
1549
1549
|
const a = e(n, o) ?? n;
|
|
1550
1550
|
if (void 0 !== o) return a === n ? void 0 : a;
|
|
1551
|
-
const s = /* @__PURE__ */ new Map(),
|
|
1552
|
-
if (0 === s.size ||
|
|
1553
|
-
const
|
|
1554
|
-
for (const e of Le(
|
|
1551
|
+
const s = /* @__PURE__ */ new Map(), i = Ce(a, void 0, t, s);
|
|
1552
|
+
if (0 === s.size || Se(i, r)) return a === n ? void 0 : a;
|
|
1553
|
+
const E = /* @__PURE__ */ new Set();
|
|
1554
|
+
for (const e of Le(i, r)) {
|
|
1555
1555
|
const r = s.get(e);
|
|
1556
|
-
r &&
|
|
1556
|
+
r && E.add(r);
|
|
1557
1557
|
}
|
|
1558
|
-
return 0 ===
|
|
1558
|
+
return 0 === E.size ? a === n ? void 0 : a : De(a, E);
|
|
1559
1559
|
};
|
|
1560
|
-
}(
|
|
1560
|
+
}(c, E), p = (e, r, n) => {
|
|
1561
1561
|
const o = t.parse(e, { anchor: r });
|
|
1562
1562
|
if (!o) return e;
|
|
1563
1563
|
const a = t.transform(o, n);
|
|
@@ -1568,10 +1568,10 @@ function Oe(e, r) {
|
|
|
1568
1568
|
anchor: r,
|
|
1569
1569
|
normalize: !0
|
|
1570
1570
|
}),
|
|
1571
|
-
readText: (e, r, t) =>
|
|
1572
|
-
readDetached: (e) =>
|
|
1571
|
+
readText: (e, r, t) => p(e, r, t ? l.base : l.legacy),
|
|
1572
|
+
readDetached: (e) => p(e, void 0, l.base),
|
|
1573
1573
|
annotate: (e) => {
|
|
1574
|
-
const r =
|
|
1574
|
+
const r = Se(e, E), t = Q(e) || z(e, E);
|
|
1575
1575
|
if (!r && !t) return;
|
|
1576
1576
|
const n = {};
|
|
1577
1577
|
return r && (n.cm = !0), t && (n.ca = !0), n;
|
|
@@ -1593,9 +1593,9 @@ function Oe(e, r) {
|
|
|
1593
1593
|
};
|
|
1594
1594
|
}
|
|
1595
1595
|
})(n)) : e;
|
|
1596
|
-
return t.transform(a, r ?
|
|
1596
|
+
return t.transform(a, r ? c : u);
|
|
1597
1597
|
},
|
|
1598
|
-
writeName: (e) =>
|
|
1598
|
+
writeName: (e) => p(e, void 0, c)
|
|
1599
1599
|
};
|
|
1600
1600
|
}
|
|
1601
1601
|
function Ie(r, t) {
|
|
@@ -1603,15 +1603,15 @@ function Ie(r, t) {
|
|
|
1603
1603
|
const n = r.tables;
|
|
1604
1604
|
if (!n) return;
|
|
1605
1605
|
for (let r = 0; r < n.length; r++) {
|
|
1606
|
-
const o = n[r], a = Array.isArray(o) ? o[0] : o?.r, s = Array.isArray(o) ? o[1] : o?.v,
|
|
1607
|
-
if (!
|
|
1608
|
-
const
|
|
1609
|
-
for (let e = 0; e <
|
|
1610
|
-
const r =
|
|
1606
|
+
const o = n[r], a = Array.isArray(o) ? o[0] : o?.r, s = Array.isArray(o) ? o[1] : o?.v, i = s?.columns;
|
|
1607
|
+
if (!i || "string" != typeof a) continue;
|
|
1608
|
+
const E = e.fastStringToRange(a), l = E.rowStart + (s.headerRowCount ?? 1);
|
|
1609
|
+
for (let e = 0; e < i.length; e++) {
|
|
1610
|
+
const r = i[e];
|
|
1611
1611
|
if (!r || "object" != typeof r) continue;
|
|
1612
1612
|
const n = {
|
|
1613
|
-
rowIndex:
|
|
1614
|
-
colIndex:
|
|
1613
|
+
rowIndex: l,
|
|
1614
|
+
colIndex: E.colStart + e
|
|
1615
1615
|
}, o = r.calculatedColumnFormula;
|
|
1616
1616
|
"string" == typeof o && o && (r.calculatedColumnFormula = t.readText(o, n, !1));
|
|
1617
1617
|
const a = r.totalsRowFormula;
|
|
@@ -1629,38 +1629,38 @@ function Ie(r, t) {
|
|
|
1629
1629
|
for (let r = 0; r < n.length; r++) {
|
|
1630
1630
|
const a = n[r], s = a[1];
|
|
1631
1631
|
if ("string" != typeof s) continue;
|
|
1632
|
-
const
|
|
1633
|
-
rowIndex:
|
|
1634
|
-
colIndex:
|
|
1635
|
-
},
|
|
1636
|
-
|
|
1632
|
+
const i = e.fastStringToRange(String(a[0])), E = {
|
|
1633
|
+
rowIndex: i.rowStart,
|
|
1634
|
+
colIndex: i.colStart
|
|
1635
|
+
}, l = t.readText(s, E, o.has(`${i.rowStart},${i.colStart}`));
|
|
1636
|
+
l !== s && (a[1] = l);
|
|
1637
1637
|
}
|
|
1638
1638
|
}
|
|
1639
1639
|
var Ne = (e) => "prefix" === e?.type && "@" === e.value && !!e.inputs?.[0], Le = (e, r) => {
|
|
1640
1640
|
const t = /* @__PURE__ */ new Set();
|
|
1641
1641
|
if (!e) return t;
|
|
1642
1642
|
const n = /* @__PURE__ */ new Set(), o = (e, a, s) => {
|
|
1643
|
-
const
|
|
1644
|
-
if (!
|
|
1645
|
-
let
|
|
1646
|
-
for (let e = 0; e <
|
|
1647
|
-
const r =
|
|
1648
|
-
Ne(r) && "paren" !== r.inputs[0].type && (
|
|
1643
|
+
const i = e.inputs;
|
|
1644
|
+
if (!i) return;
|
|
1645
|
+
let E;
|
|
1646
|
+
for (let e = 0; e < i.length; e++) {
|
|
1647
|
+
const r = i[e];
|
|
1648
|
+
Ne(r) && "paren" !== r.inputs[0].type && (E || (E = [...i]), E[e] = r.inputs[0]);
|
|
1649
1649
|
}
|
|
1650
|
-
if (
|
|
1651
|
-
const o =
|
|
1650
|
+
if (E) {
|
|
1651
|
+
const o = Te({
|
|
1652
1652
|
...e,
|
|
1653
|
-
inputs:
|
|
1653
|
+
inputs: E
|
|
1654
1654
|
}, r, n, a, s);
|
|
1655
|
-
if (o) for (const e of o)
|
|
1655
|
+
if (o) for (const e of o) E[e] !== i[e] && t.add(i[e]);
|
|
1656
1656
|
}
|
|
1657
|
-
const
|
|
1658
|
-
for (let e = 0; e <
|
|
1659
|
-
const r =
|
|
1660
|
-
r && o(r,
|
|
1657
|
+
const l = Ee(e, r, a), c = le(e, r, s);
|
|
1658
|
+
for (let e = 0; e < i.length; e++) {
|
|
1659
|
+
const r = i[e];
|
|
1660
|
+
r && o(r, l(e), c(e));
|
|
1661
1661
|
}
|
|
1662
1662
|
};
|
|
1663
|
-
return o(e, !1, !0), Ne(e) && "paren" !== e.inputs[0].type &&
|
|
1663
|
+
return o(e, !1, !0), Ne(e) && "paren" !== e.inputs[0].type && ce(e.inputs[0], r, n, !0) && t.add(e), t;
|
|
1664
1664
|
}, Ce = (e, r, t, n) => {
|
|
1665
1665
|
const o = e.inputs;
|
|
1666
1666
|
let a = e;
|
|
@@ -1669,8 +1669,8 @@ var Ne = (e) => "prefix" === e?.type && "@" === e.value && !!e.inputs?.[0], Le =
|
|
|
1669
1669
|
for (let a = 0; a < o.length; a++) {
|
|
1670
1670
|
const s = o[a];
|
|
1671
1671
|
if (!s) continue;
|
|
1672
|
-
const
|
|
1673
|
-
|
|
1672
|
+
const i = Ce(s, e, t, n);
|
|
1673
|
+
i !== s && (r || (r = [...o]), r[a] = i);
|
|
1674
1674
|
}
|
|
1675
1675
|
r && (a = {
|
|
1676
1676
|
...e,
|
|
@@ -2237,11 +2237,11 @@ var de = /* @__PURE__ */ new Set([
|
|
|
2237
2237
|
"WORKGROUP.OPTIONS",
|
|
2238
2238
|
"WORKSPACE",
|
|
2239
2239
|
"ZOOM"
|
|
2240
|
-
]),
|
|
2240
|
+
]), ge = "__xludf.DUMMYFUNCTION", he = "\"COMPUTED_VALUE\"", Ue = (e) => `"${e.replace(/"/g, "\"\"")}"`, Fe = (e) => {
|
|
2241
2241
|
if (null == e) return "\"\"";
|
|
2242
2242
|
if ("number" == typeof e) return Number.isFinite(e) ? "" + e : null;
|
|
2243
2243
|
if ("boolean" == typeof e) return e ? "TRUE" : "FALSE";
|
|
2244
|
-
if ("string" == typeof e) return
|
|
2244
|
+
if ("string" == typeof e) return Ue(e);
|
|
2245
2245
|
const t = e;
|
|
2246
2246
|
if ("function" == typeof t?.getCode) {
|
|
2247
2247
|
const e = t.getCode();
|
|
@@ -2250,10 +2250,10 @@ var de = /* @__PURE__ */ new Set([
|
|
|
2250
2250
|
return null;
|
|
2251
2251
|
}, Be = (e, r) => {
|
|
2252
2252
|
const t = Fe(r);
|
|
2253
|
-
return null === t ? null : `IFERROR(${
|
|
2253
|
+
return null === t ? null : `IFERROR(${ge}(${Ue(e)}),${t})`;
|
|
2254
2254
|
}, Ge = (e) => {
|
|
2255
2255
|
const r = Fe(e);
|
|
2256
|
-
return null === r ? null : `IFERROR(${
|
|
2256
|
+
return null === r ? null : `IFERROR(${ge}(${Ue(he)}),${r})`;
|
|
2257
2257
|
}, Ve = async (e, r) => {
|
|
2258
2258
|
const t = /* @__PURE__ */ new Set();
|
|
2259
2259
|
if (0 === r.size) return t;
|
|
@@ -2274,7 +2274,7 @@ var de = /* @__PURE__ */ new Set([
|
|
|
2274
2274
|
"Sheets" !== n && "SheetXL" !== n || t.add(e.toUpperCase());
|
|
2275
2275
|
}
|
|
2276
2276
|
return t;
|
|
2277
|
-
},
|
|
2277
|
+
}, be = (e) => -1 === e.indexOf("_x") ? e : e.replace(/_x([0-9A-Fa-f]{4})_/g, (e, r) => String.fromCharCode(parseInt(r, 16))), We = (e) => He(e) ? e.replace(/(_x[0-9A-Fa-f]{4}_)/g, "_x005F$1").replace(/[\x00-\x08\x0B-\x1F]/g, (e) => `_x${e.charCodeAt(0).toString(16).toUpperCase().padStart(4, "0")}_`) : e, He = (e) => {
|
|
2278
2278
|
const r = e.length;
|
|
2279
2279
|
for (let t = 0; t < r; t++) {
|
|
2280
2280
|
const n = e.charCodeAt(t);
|
|
@@ -2430,47 +2430,47 @@ function qe(e) {
|
|
|
2430
2430
|
function Qe(e) {
|
|
2431
2431
|
return `"${e.split("\"").join("\"\"")}"`;
|
|
2432
2432
|
}
|
|
2433
|
-
var
|
|
2434
|
-
equal: { operator:
|
|
2433
|
+
var ze = "aboveAverage", Ze = "beginsWith", Je = "cellIs", je = "colorScale", er = "containsBlanks", rr = "containsErrors", tr = "containsText", nr = "dataBar", or = "duplicateValues", ar = "endsWith", sr = "expression", ir = "iconSet", Er = "notContainsBlanks", lr = "notContainsErrors", cr = "notContainsText", ur = "timePeriod", pr = "top10", Tr = "uniqueValues", Ar = a.BuiltInOperatorNames, Sr = {
|
|
2434
|
+
equal: { operator: Ar.EqualTo },
|
|
2435
2435
|
notEqual: {
|
|
2436
|
-
operator:
|
|
2436
|
+
operator: Ar.EqualTo,
|
|
2437
2437
|
negate: !0
|
|
2438
2438
|
},
|
|
2439
|
-
greaterThan: { operator:
|
|
2440
|
-
greaterThanOrEqual: { operator:
|
|
2441
|
-
lessThan: { operator:
|
|
2442
|
-
lessThanOrEqual: { operator:
|
|
2443
|
-
between: { operator:
|
|
2439
|
+
greaterThan: { operator: Ar.GreaterThan },
|
|
2440
|
+
greaterThanOrEqual: { operator: Ar.GreaterThanEqualTo },
|
|
2441
|
+
lessThan: { operator: Ar.LessThan },
|
|
2442
|
+
lessThanOrEqual: { operator: Ar.LessThanEqualTo },
|
|
2443
|
+
between: { operator: Ar.Between },
|
|
2444
2444
|
notBetween: {
|
|
2445
|
-
operator:
|
|
2445
|
+
operator: Ar.Between,
|
|
2446
2446
|
negate: !0
|
|
2447
2447
|
}
|
|
2448
|
-
},
|
|
2449
|
-
[
|
|
2448
|
+
}, fr = {
|
|
2449
|
+
[Ar.EqualTo]: {
|
|
2450
2450
|
plain: "equal",
|
|
2451
2451
|
negated: "notEqual"
|
|
2452
2452
|
},
|
|
2453
|
-
[
|
|
2453
|
+
[Ar.GreaterThan]: {
|
|
2454
2454
|
plain: "greaterThan",
|
|
2455
2455
|
negated: ""
|
|
2456
2456
|
},
|
|
2457
|
-
[
|
|
2457
|
+
[Ar.GreaterThanEqualTo]: {
|
|
2458
2458
|
plain: "greaterThanOrEqual",
|
|
2459
2459
|
negated: ""
|
|
2460
2460
|
},
|
|
2461
|
-
[
|
|
2461
|
+
[Ar.LessThan]: {
|
|
2462
2462
|
plain: "lessThan",
|
|
2463
2463
|
negated: ""
|
|
2464
2464
|
},
|
|
2465
|
-
[
|
|
2465
|
+
[Ar.LessThanEqualTo]: {
|
|
2466
2466
|
plain: "lessThanOrEqual",
|
|
2467
2467
|
negated: ""
|
|
2468
2468
|
},
|
|
2469
|
-
[
|
|
2469
|
+
[Ar.Between]: {
|
|
2470
2470
|
plain: "between",
|
|
2471
2471
|
negated: "notBetween"
|
|
2472
2472
|
}
|
|
2473
|
-
},
|
|
2473
|
+
}, Rr = /* @__PURE__ */ new Set([
|
|
2474
2474
|
"today",
|
|
2475
2475
|
"yesterday",
|
|
2476
2476
|
"tomorrow",
|
|
@@ -2490,7 +2490,7 @@ function Ir(e) {
|
|
|
2490
2490
|
}
|
|
2491
2491
|
function Nr(e, r) {
|
|
2492
2492
|
return r ? {
|
|
2493
|
-
operator:
|
|
2493
|
+
operator: Ar.Not,
|
|
2494
2494
|
param: e
|
|
2495
2495
|
} : e;
|
|
2496
2496
|
}
|
|
@@ -2501,11 +2501,11 @@ function Lr(e, r) {
|
|
|
2501
2501
|
switch (t) {
|
|
2502
2502
|
case je:
|
|
2503
2503
|
case nr:
|
|
2504
|
-
case
|
|
2504
|
+
case ir: return null;
|
|
2505
2505
|
case Je: {
|
|
2506
|
-
const t = e.operator ?
|
|
2506
|
+
const t = e.operator ? Sr[e.operator] : void 0;
|
|
2507
2507
|
if (!t) return r?.(`Conditional format operator '${e.operator}' is not a known cellIs operator.`), null;
|
|
2508
|
-
const o = t.operator ===
|
|
2508
|
+
const o = t.operator === Ar.Between ? {
|
|
2509
2509
|
from: Or(n[0]),
|
|
2510
2510
|
to: Or(n[1])
|
|
2511
2511
|
} : Or(n[0]);
|
|
@@ -2515,52 +2515,52 @@ function Lr(e, r) {
|
|
|
2515
2515
|
}, t.negate);
|
|
2516
2516
|
}
|
|
2517
2517
|
case sr: return {
|
|
2518
|
-
operator:
|
|
2518
|
+
operator: Ar.Expression,
|
|
2519
2519
|
param: n[0] ?? ""
|
|
2520
2520
|
};
|
|
2521
2521
|
case tr: return {
|
|
2522
|
-
operator:
|
|
2522
|
+
operator: Ar.TextContains,
|
|
2523
2523
|
param: e.text
|
|
2524
2524
|
};
|
|
2525
|
-
case
|
|
2526
|
-
operator:
|
|
2525
|
+
case cr: return Nr({
|
|
2526
|
+
operator: Ar.TextContains,
|
|
2527
2527
|
param: e.text
|
|
2528
2528
|
}, !0);
|
|
2529
|
-
case
|
|
2530
|
-
operator:
|
|
2529
|
+
case Ze: return {
|
|
2530
|
+
operator: Ar.TextStartsWith,
|
|
2531
2531
|
param: e.text
|
|
2532
2532
|
};
|
|
2533
2533
|
case ar: return {
|
|
2534
|
-
operator:
|
|
2534
|
+
operator: Ar.TextEndsWith,
|
|
2535
2535
|
param: e.text
|
|
2536
2536
|
};
|
|
2537
|
-
case er: return { operator:
|
|
2538
|
-
case
|
|
2539
|
-
case rr: return { operator:
|
|
2540
|
-
case
|
|
2541
|
-
case
|
|
2542
|
-
case or: return Nr({ operator:
|
|
2537
|
+
case er: return { operator: Ar.Blank };
|
|
2538
|
+
case Er: return Nr({ operator: Ar.Blank }, !0);
|
|
2539
|
+
case rr: return { operator: Ar.Error };
|
|
2540
|
+
case lr: return Nr({ operator: Ar.Error }, !0);
|
|
2541
|
+
case Tr: return { operator: Ar.Unique };
|
|
2542
|
+
case or: return Nr({ operator: Ar.Unique }, !0);
|
|
2543
2543
|
case ur: {
|
|
2544
2544
|
const r = {};
|
|
2545
2545
|
return e.timePeriod && (r.type = e.timePeriod), {
|
|
2546
|
-
operator:
|
|
2546
|
+
operator: Ar.TimePeriod,
|
|
2547
2547
|
param: r
|
|
2548
2548
|
};
|
|
2549
2549
|
}
|
|
2550
|
-
case
|
|
2550
|
+
case pr: {
|
|
2551
2551
|
const r = {
|
|
2552
2552
|
top: !e.bottom,
|
|
2553
2553
|
percent: e.percent ?? !1
|
|
2554
2554
|
};
|
|
2555
2555
|
return void 0 !== e.rank && (r.limit = e.rank), {
|
|
2556
|
-
operator:
|
|
2556
|
+
operator: Ar.TopN,
|
|
2557
2557
|
param: r
|
|
2558
2558
|
};
|
|
2559
2559
|
}
|
|
2560
|
-
case
|
|
2560
|
+
case ze: {
|
|
2561
2561
|
const r = e.aboveAverage ?? !0, t = e.equalAverage ?? !1, n = { type: r ? t ? a.AverageType.AboveOrEqual : a.AverageType.Above : t ? a.AverageType.BelowOrEqual : a.AverageType.Below };
|
|
2562
2562
|
return void 0 !== e.stdDev && (n.stdDevs = e.stdDev), {
|
|
2563
|
-
operator:
|
|
2563
|
+
operator: Ar.Average,
|
|
2564
2564
|
param: n
|
|
2565
2565
|
};
|
|
2566
2566
|
}
|
|
@@ -2569,29 +2569,29 @@ function Lr(e, r) {
|
|
|
2569
2569
|
}
|
|
2570
2570
|
function Cr(e, r, t) {
|
|
2571
2571
|
if (!e) return null;
|
|
2572
|
-
const n = e.operator ===
|
|
2572
|
+
const n = e.operator === Ar.Not, o = (n ? e.param : e) ?? {}, s = o.operator, i = o.param;
|
|
2573
2573
|
if (!s) return null;
|
|
2574
|
-
const
|
|
2575
|
-
if (
|
|
2576
|
-
const e = n ?
|
|
2574
|
+
const E = fr[s];
|
|
2575
|
+
if (E) {
|
|
2576
|
+
const e = n ? E.negated : E.plain;
|
|
2577
2577
|
if (!e) return t?.(`Conditional format operator 'not(${s})' has no OOXML form.`), null;
|
|
2578
2578
|
return {
|
|
2579
2579
|
type: Je,
|
|
2580
2580
|
operator: e,
|
|
2581
|
-
formulas: s ===
|
|
2581
|
+
formulas: s === Ar.Between ? [Ir(i?.from), Ir(i?.to)] : [Ir(i)]
|
|
2582
2582
|
};
|
|
2583
2583
|
}
|
|
2584
2584
|
switch (s) {
|
|
2585
|
-
case
|
|
2585
|
+
case Ar.Expression:
|
|
2586
2586
|
if (n) break;
|
|
2587
2587
|
return {
|
|
2588
2588
|
type: sr,
|
|
2589
|
-
formulas: [null ==
|
|
2589
|
+
formulas: [null == i ? "" : String(i)]
|
|
2590
2590
|
};
|
|
2591
|
-
case
|
|
2592
|
-
const e = String(
|
|
2591
|
+
case Ar.TextContains: {
|
|
2592
|
+
const e = String(i ?? "");
|
|
2593
2593
|
return n ? {
|
|
2594
|
-
type:
|
|
2594
|
+
type: cr,
|
|
2595
2595
|
text: e,
|
|
2596
2596
|
formulas: [`ISERROR(SEARCH(${Qe(e)},${r}))`]
|
|
2597
2597
|
} : {
|
|
@@ -2600,62 +2600,62 @@ function Cr(e, r, t) {
|
|
|
2600
2600
|
formulas: [`NOT(ISERROR(SEARCH(${Qe(e)},${r})))`]
|
|
2601
2601
|
};
|
|
2602
2602
|
}
|
|
2603
|
-
case
|
|
2603
|
+
case Ar.TextStartsWith: {
|
|
2604
2604
|
if (n) break;
|
|
2605
|
-
const e = String(
|
|
2605
|
+
const e = String(i ?? "");
|
|
2606
2606
|
return {
|
|
2607
|
-
type:
|
|
2607
|
+
type: Ze,
|
|
2608
2608
|
text: e,
|
|
2609
2609
|
formulas: [`LEFT(${r},LEN(${Qe(e)}))=${Qe(e)}`]
|
|
2610
2610
|
};
|
|
2611
2611
|
}
|
|
2612
|
-
case
|
|
2612
|
+
case Ar.TextEndsWith: {
|
|
2613
2613
|
if (n) break;
|
|
2614
|
-
const e = String(
|
|
2614
|
+
const e = String(i ?? "");
|
|
2615
2615
|
return {
|
|
2616
2616
|
type: ar,
|
|
2617
2617
|
text: e,
|
|
2618
2618
|
formulas: [`RIGHT(${r},LEN(${Qe(e)}))=${Qe(e)}`]
|
|
2619
2619
|
};
|
|
2620
2620
|
}
|
|
2621
|
-
case
|
|
2622
|
-
type:
|
|
2621
|
+
case Ar.Blank: return n ? {
|
|
2622
|
+
type: Er,
|
|
2623
2623
|
formulas: [`LEN(TRIM(${r}))>0`]
|
|
2624
2624
|
} : {
|
|
2625
2625
|
type: er,
|
|
2626
2626
|
formulas: [`LEN(TRIM(${r}))=0`]
|
|
2627
2627
|
};
|
|
2628
|
-
case
|
|
2629
|
-
type:
|
|
2628
|
+
case Ar.Error: return n ? {
|
|
2629
|
+
type: lr,
|
|
2630
2630
|
formulas: [`NOT(ISERROR(${r}))`]
|
|
2631
2631
|
} : {
|
|
2632
2632
|
type: rr,
|
|
2633
2633
|
formulas: [`ISERROR(${r})`]
|
|
2634
2634
|
};
|
|
2635
|
-
case
|
|
2636
|
-
case
|
|
2635
|
+
case Ar.Unique: return { type: n ? or : Tr };
|
|
2636
|
+
case Ar.TimePeriod: {
|
|
2637
2637
|
if (n) break;
|
|
2638
|
-
const e =
|
|
2639
|
-
return e && !
|
|
2638
|
+
const e = i?.type;
|
|
2639
|
+
return e && !Rr.has(e) ? (t?.(`Conditional format time period '${e}' has no OOXML form; rule skipped.`), null) : {
|
|
2640
2640
|
type: ur,
|
|
2641
2641
|
timePeriod: e
|
|
2642
2642
|
};
|
|
2643
2643
|
}
|
|
2644
|
-
case
|
|
2644
|
+
case Ar.TopN: {
|
|
2645
2645
|
if (n) break;
|
|
2646
|
-
const e =
|
|
2646
|
+
const e = i ?? {};
|
|
2647
2647
|
return {
|
|
2648
|
-
type:
|
|
2648
|
+
type: pr,
|
|
2649
2649
|
bottom: !(e.top ?? 1),
|
|
2650
2650
|
percent: e.percent ?? !1,
|
|
2651
2651
|
rank: e.limit
|
|
2652
2652
|
};
|
|
2653
2653
|
}
|
|
2654
|
-
case
|
|
2654
|
+
case Ar.Average: {
|
|
2655
2655
|
if (n) break;
|
|
2656
|
-
const e =
|
|
2656
|
+
const e = i ?? {}, r = e.type ?? a.AverageType.Above;
|
|
2657
2657
|
return {
|
|
2658
|
-
type:
|
|
2658
|
+
type: ze,
|
|
2659
2659
|
aboveAverage: r === a.AverageType.Above || r === a.AverageType.AboveOrEqual,
|
|
2660
2660
|
equalAverage: r === a.AverageType.AboveOrEqual || r === a.AverageType.BelowOrEqual,
|
|
2661
2661
|
stdDev: e.stdDevs
|
|
@@ -2674,7 +2674,7 @@ var Dr = "equal", mr = "notEqual", xr = "greaterThan", yr = "greaterThanOrEqual"
|
|
|
2674
2674
|
[yr]: { operator: Pr.GreaterThanEqualTo },
|
|
2675
2675
|
[Mr]: { operator: Pr.LessThan },
|
|
2676
2676
|
[vr]: { operator: Pr.LessThanEqualTo }
|
|
2677
|
-
},
|
|
2677
|
+
}, gr = {
|
|
2678
2678
|
[Pr.EqualTo]: {
|
|
2679
2679
|
plain: Dr,
|
|
2680
2680
|
negated: mr
|
|
@@ -2696,10 +2696,10 @@ var Dr = "equal", mr = "notEqual", xr = "greaterThan", yr = "greaterThanOrEqual"
|
|
|
2696
2696
|
negated: xr
|
|
2697
2697
|
}
|
|
2698
2698
|
};
|
|
2699
|
-
function gr(e) {
|
|
2700
|
-
return "string" == typeof e && void 0 !== Ur[e];
|
|
2701
|
-
}
|
|
2702
2699
|
function hr(e) {
|
|
2700
|
+
return "string" == typeof e && void 0 !== gr[e];
|
|
2701
|
+
}
|
|
2702
|
+
function Ur(e) {
|
|
2703
2703
|
if (null != e) return "" + e;
|
|
2704
2704
|
}
|
|
2705
2705
|
function Fr(e, r) {
|
|
@@ -2727,24 +2727,24 @@ function Br(e, r) {
|
|
|
2727
2727
|
if (!e) return null;
|
|
2728
2728
|
const t = e.operator === Pr.Not, n = (t ? e.param : e) ?? {}, o = n.operator;
|
|
2729
2729
|
if (!o) return null;
|
|
2730
|
-
const a =
|
|
2730
|
+
const a = gr[o];
|
|
2731
2731
|
return a ? {
|
|
2732
2732
|
operator: t ? a.negated : a.plain,
|
|
2733
|
-
val:
|
|
2733
|
+
val: Ur(n.param)
|
|
2734
2734
|
} : !t && dr[o] ? {
|
|
2735
2735
|
operator: o,
|
|
2736
|
-
val:
|
|
2736
|
+
val: Ur(n.param)
|
|
2737
2737
|
} : (r?.(`AutoFilter operator '${t ? `not(${o})` : o}' has no OOXML form.`), null);
|
|
2738
2738
|
}
|
|
2739
|
-
var Gr = "custom", Vr = "date",
|
|
2739
|
+
var Gr = "custom", Vr = "date", br = "decimal", Wr = "list", Hr = "none", wr = "textLength", Yr = "time", Kr = "whole", Xr = a.BuiltInOperatorNames, _r = a.BuiltInSelectorNames, $r = {
|
|
2740
2740
|
[Kr]: _r.Whole,
|
|
2741
|
-
[
|
|
2741
|
+
[br]: _r.Number,
|
|
2742
2742
|
[Vr]: _r.Date,
|
|
2743
2743
|
[Yr]: _r.Time,
|
|
2744
2744
|
[wr]: _r.TextLength
|
|
2745
2745
|
}, kr = {
|
|
2746
2746
|
[_r.Whole]: Kr,
|
|
2747
|
-
[_r.Number]:
|
|
2747
|
+
[_r.Number]: br,
|
|
2748
2748
|
[_r.Date]: Vr,
|
|
2749
2749
|
[_r.DateTime]: Vr,
|
|
2750
2750
|
[_r.Time]: Yr,
|
|
@@ -2765,6 +2765,11 @@ var Gr = "custom", Vr = "date", Wr = "decimal", Hr = "list", br = "none", wr = "
|
|
|
2765
2765
|
lessThan: { operator: Xr.LessThan },
|
|
2766
2766
|
lessThanOrEqual: { operator: Xr.LessThanEqualTo }
|
|
2767
2767
|
}, Qr = {
|
|
2768
|
+
[Xr.GreaterThan]: Xr.After,
|
|
2769
|
+
[Xr.GreaterThanEqualTo]: Xr.AfterEqualTo,
|
|
2770
|
+
[Xr.LessThan]: Xr.Before,
|
|
2771
|
+
[Xr.LessThanEqualTo]: Xr.BeforeEqualTo
|
|
2772
|
+
}, zr = {
|
|
2768
2773
|
[Xr.Between]: {
|
|
2769
2774
|
plain: "between",
|
|
2770
2775
|
negated: "notBetween"
|
|
@@ -2788,24 +2793,40 @@ var Gr = "custom", Vr = "date", Wr = "decimal", Hr = "list", br = "none", wr = "
|
|
|
2788
2793
|
[Xr.LessThanEqualTo]: {
|
|
2789
2794
|
plain: "lessThanOrEqual",
|
|
2790
2795
|
negated: ""
|
|
2796
|
+
},
|
|
2797
|
+
[Xr.After]: {
|
|
2798
|
+
plain: "greaterThan",
|
|
2799
|
+
negated: ""
|
|
2800
|
+
},
|
|
2801
|
+
[Xr.AfterEqualTo]: {
|
|
2802
|
+
plain: "greaterThanOrEqual",
|
|
2803
|
+
negated: ""
|
|
2804
|
+
},
|
|
2805
|
+
[Xr.Before]: {
|
|
2806
|
+
plain: "lessThan",
|
|
2807
|
+
negated: ""
|
|
2808
|
+
},
|
|
2809
|
+
[Xr.BeforeEqualTo]: {
|
|
2810
|
+
plain: "lessThanOrEqual",
|
|
2811
|
+
negated: ""
|
|
2791
2812
|
}
|
|
2792
2813
|
};
|
|
2793
2814
|
function Zr(e, r) {
|
|
2794
|
-
return r ===
|
|
2815
|
+
return r === Wr || r === Gr ? e : ke(e);
|
|
2795
2816
|
}
|
|
2796
|
-
function
|
|
2817
|
+
function Jr(e) {
|
|
2797
2818
|
return qe(e);
|
|
2798
2819
|
}
|
|
2799
|
-
function
|
|
2820
|
+
function jr(e, r, t) {
|
|
2800
2821
|
if ("string" != typeof e || e.length <= 255) return e;
|
|
2801
2822
|
let n = 255;
|
|
2802
2823
|
const o = e.charCodeAt(n - 1);
|
|
2803
2824
|
return o >= 55296 && o <= 56319 && n--, t?.(`DataValidation ${r} is ${e.length} characters; Excel opens no more than 255, so it is cut.`, `xlsx.dv.${r}.length`), e.substring(0, n);
|
|
2804
2825
|
}
|
|
2805
|
-
function
|
|
2826
|
+
function et(e, r) {
|
|
2806
2827
|
const t = e.type;
|
|
2807
|
-
if (!t || t ===
|
|
2808
|
-
if (t ===
|
|
2828
|
+
if (!t || t === Hr) return null;
|
|
2829
|
+
if (t === Wr) return {
|
|
2809
2830
|
selector: _r.List,
|
|
2810
2831
|
operator: Xr.InSet,
|
|
2811
2832
|
param: { items: e.formula1 }
|
|
@@ -2825,24 +2846,24 @@ function jr(e, r) {
|
|
|
2825
2846
|
const s = a.operator === Xr.Between ? {
|
|
2826
2847
|
from: e.formula1,
|
|
2827
2848
|
to: e.formula2
|
|
2828
|
-
} : e.formula1,
|
|
2829
|
-
operator: a.operator,
|
|
2849
|
+
} : e.formula1, i = {
|
|
2850
|
+
operator: (t === Vr || t === Yr) && Qr[a.operator] || a.operator,
|
|
2830
2851
|
param: s
|
|
2831
2852
|
};
|
|
2832
2853
|
return a.negate ? {
|
|
2833
2854
|
selector: n,
|
|
2834
2855
|
operator: Xr.Not,
|
|
2835
|
-
param:
|
|
2856
|
+
param: i
|
|
2836
2857
|
} : {
|
|
2837
2858
|
selector: n,
|
|
2838
|
-
...
|
|
2859
|
+
...i
|
|
2839
2860
|
};
|
|
2840
2861
|
}
|
|
2841
|
-
function
|
|
2862
|
+
function rt(e, r) {
|
|
2842
2863
|
if (!e) return null;
|
|
2843
2864
|
const t = e.operator === Xr.Not, n = (t ? e.param : e) ?? {}, o = n.operator, a = n.param;
|
|
2844
2865
|
if (!o) return null;
|
|
2845
|
-
if (!t && (o === Xr.InSet || o ===
|
|
2866
|
+
if (!t && (o === Xr.InSet || o === Wr)) {
|
|
2846
2867
|
const e = "string" == typeof a ? a : Array.isArray(a?.items) ? `"${a.items.join(",").replace(/"/g, "\"\"")}"` : a?.items;
|
|
2847
2868
|
return "string" == typeof e && function(e) {
|
|
2848
2869
|
const r = e.startsWith("=") ? e.substring(1) : e, t = [];
|
|
@@ -2873,7 +2894,7 @@ function et(e, r) {
|
|
|
2873
2894
|
}
|
|
2874
2895
|
return !1;
|
|
2875
2896
|
}(e) ? (r?.(`DataValidation list source '${e}' is a union, which Excel cannot open; the rule is written without its list.`, "xlsx.dv.listUnion"), null) : {
|
|
2876
|
-
type:
|
|
2897
|
+
type: Wr,
|
|
2877
2898
|
formula1: e
|
|
2878
2899
|
};
|
|
2879
2900
|
}
|
|
@@ -2881,31 +2902,44 @@ function et(e, r) {
|
|
|
2881
2902
|
type: Gr,
|
|
2882
2903
|
formula1: "string" == typeof a ? a : a?.formula ?? a?.formula1
|
|
2883
2904
|
};
|
|
2884
|
-
const s =
|
|
2905
|
+
const s = zr[o];
|
|
2885
2906
|
if (!s) return !t && qr[o] ? {
|
|
2886
|
-
type:
|
|
2907
|
+
type: tt(e.selector),
|
|
2887
2908
|
operator: o,
|
|
2888
|
-
formula1:
|
|
2889
|
-
formula2:
|
|
2909
|
+
formula1: Jr(a?.from ?? a),
|
|
2910
|
+
formula2: Jr(a?.to)
|
|
2890
2911
|
} : (r?.(`DataValidation operator '${t ? `not(${o})` : o}' has no OOXML form.`), null);
|
|
2891
|
-
const
|
|
2892
|
-
return
|
|
2893
|
-
type:
|
|
2894
|
-
operator:
|
|
2895
|
-
formula1:
|
|
2896
|
-
formula2: o === Xr.Between ?
|
|
2912
|
+
const i = t ? s.negated : s.plain;
|
|
2913
|
+
return i ? {
|
|
2914
|
+
type: tt(e.selector),
|
|
2915
|
+
operator: i,
|
|
2916
|
+
formula1: Jr(o === Xr.Between ? a?.from : a),
|
|
2917
|
+
formula2: o === Xr.Between ? Jr(a?.to) : void 0
|
|
2897
2918
|
} : (r?.(`DataValidation operator 'not(${o})' has no OOXML form.`), null);
|
|
2898
2919
|
}
|
|
2899
|
-
function
|
|
2900
|
-
return (e ? kr[e] : void 0) ??
|
|
2920
|
+
function tt(e) {
|
|
2921
|
+
return (e ? kr[e] : void 0) ?? br;
|
|
2901
2922
|
}
|
|
2902
|
-
var
|
|
2903
|
-
|
|
2923
|
+
var nt = /\s*<v:shape\b[\s\S]*?<\/v:shape>/g, ot = /<x:ClientData\b[^>]*\bObjectType="Note"/, at = /<x:Row>\s*(-?\d+)\s*<\/x:Row>/, st = /<x:Column>\s*(-?\d+)\s*<\/x:Column>/, it = /<x:Anchor>([\s\d,-]*)<\/x:Anchor>/, Et = /<x:Visible\s*(?:\/>|>([^<]*)<\/x:Visible>)/, lt = /\s*<\/xml>\s*$/, ct = /^\s*<v:shape\b((?:[^>"']|"[^"]*"|'[^']*')*)>/, ut = /([\w:.-]+)\s*=\s*(?:"([^"]*)"|'([^']*)')/g, pt = /<o:idmap\b[^>]*\bdata="([^"]*)"/, Tt = /* @__PURE__ */ new Set([
|
|
2924
|
+
"position",
|
|
2925
|
+
"margin-left",
|
|
2926
|
+
"margin-top",
|
|
2927
|
+
"width",
|
|
2928
|
+
"height",
|
|
2929
|
+
"z-index",
|
|
2930
|
+
"visibility"
|
|
2931
|
+
]), At = /* @__PURE__ */ new Set([
|
|
2932
|
+
"id",
|
|
2933
|
+
"o:spid",
|
|
2934
|
+
"alt",
|
|
2935
|
+
"style"
|
|
2936
|
+
]);
|
|
2937
|
+
function St(e) {
|
|
2904
2938
|
const r = [];
|
|
2905
2939
|
return {
|
|
2906
|
-
rest: e.replace(
|
|
2907
|
-
if (!
|
|
2908
|
-
const t =
|
|
2940
|
+
rest: e.replace(nt, (e) => {
|
|
2941
|
+
if (!ot.test(e)) return e;
|
|
2942
|
+
const t = at.exec(e), n = st.exec(e);
|
|
2909
2943
|
return t && n ? (r.push({
|
|
2910
2944
|
xml: e,
|
|
2911
2945
|
row: parseInt(t[1], 10),
|
|
@@ -2915,45 +2949,103 @@ function pt(e) {
|
|
|
2915
2949
|
notes: r
|
|
2916
2950
|
};
|
|
2917
2951
|
}
|
|
2918
|
-
|
|
2919
|
-
const
|
|
2920
|
-
|
|
2921
|
-
|
|
2922
|
-
|
|
2923
|
-
const
|
|
2924
|
-
|
|
2925
|
-
|
|
2926
|
-
|
|
2927
|
-
|
|
2952
|
+
var ft = (e) => e.replace(/"/g, "\"").replace(/'/g, "'").replace(/</g, "<").replace(/>/g, ">").replace(/&/g, "&"), Rt = (e) => {
|
|
2953
|
+
const r = [], t = e.split(";");
|
|
2954
|
+
for (let e = 0; e < t.length; e++) {
|
|
2955
|
+
const n = t[e].trim();
|
|
2956
|
+
if (!n) continue;
|
|
2957
|
+
const o = n.substring(0, n.indexOf(":")).trim().toLowerCase();
|
|
2958
|
+
Tt.has(o) || r.push(n.replace(/\s+/g, " "));
|
|
2959
|
+
}
|
|
2960
|
+
return r.join(";");
|
|
2961
|
+
}, Ot = (e) => {
|
|
2962
|
+
const r = ct.exec(e);
|
|
2963
|
+
if (!r) return null;
|
|
2964
|
+
const t = [];
|
|
2965
|
+
let n, o = "", a = null;
|
|
2966
|
+
for (ut.lastIndex = 0; null !== (n = ut.exec(r[1]));) {
|
|
2967
|
+
const e = n[1], r = n[2] ?? n[3] ?? "";
|
|
2968
|
+
"style" === e ? o = Rt(r) : "alt" === e ? a = ft(r) || null : At.has(e) || t.push(n[0].replace(/\s+/g, " "));
|
|
2969
|
+
}
|
|
2970
|
+
return {
|
|
2971
|
+
attributes: t,
|
|
2972
|
+
style: o,
|
|
2973
|
+
alt: a,
|
|
2974
|
+
end: r[0].length
|
|
2975
|
+
};
|
|
2976
|
+
};
|
|
2977
|
+
function It(e) {
|
|
2978
|
+
const r = Ot(e);
|
|
2979
|
+
if (!r) return null;
|
|
2980
|
+
const t = r.attributes.slice();
|
|
2981
|
+
r.style && t.push(`style='${r.style}'`);
|
|
2982
|
+
const n = e.substring(r.end).replace(it, "").replace(at, "").replace(st, "").replace(Et, "").replace(/>\s+</g, "><").replace(/\s+/g, " ").trim();
|
|
2983
|
+
return `<v:shape${t.length > 0 ? " " + t.join(" ") : ""}>${n}`;
|
|
2928
2984
|
}
|
|
2929
|
-
|
|
2930
|
-
|
|
2931
|
-
|
|
2932
|
-
|
|
2985
|
+
var Nt = It("<v:shape type=\"#_x0000_t202\" fillcolor=\"infoBackground [80]\" strokecolor=\"none [81]\"\n o:insetmode=\"auto\">\n <v:fill color2=\"infoBackground [80]\"/>\n <v:shadow color=\"none [81]\" obscured=\"t\"/>\n <v:path o:connecttype=\"none\"/>\n <v:textbox style='mso-direction-alt:auto'>\n <div style='text-align:left'></div>\n </v:textbox>\n <x:ClientData ObjectType=\"Note\">\n <x:MoveWithCells/>\n <x:SizeWithCells/>\n <x:AutoFill>False</x:AutoFill>\n </x:ClientData>\n </v:shape>");
|
|
2986
|
+
function Lt(e) {
|
|
2987
|
+
let r = null;
|
|
2988
|
+
const t = it.exec(e);
|
|
2989
|
+
if (t) {
|
|
2990
|
+
const e = t[1].split(",").map((e) => parseInt(e.trim(), 10));
|
|
2991
|
+
8 !== e.length || e.some((e) => isNaN(e)) || (r = e);
|
|
2992
|
+
}
|
|
2993
|
+
const n = Et.exec(e), o = !!n && !/^\s*f/i.test(n[1] ?? ""), a = It(e);
|
|
2994
|
+
return {
|
|
2995
|
+
anchor: r,
|
|
2996
|
+
visible: o,
|
|
2997
|
+
alt: Ot(e)?.alt ?? null,
|
|
2998
|
+
xml: null === a || a === Nt ? null : a
|
|
2999
|
+
};
|
|
2933
3000
|
}
|
|
2934
|
-
|
|
2935
|
-
|
|
3001
|
+
var Ct = (e) => Math.round(.75 * e * 100) / 100 + "pt";
|
|
3002
|
+
function Dt(e, r) {
|
|
3003
|
+
const t = (e ? It(e) : null) ?? Nt, n = Ot(t), { bounds: o, anchor: a } = r;
|
|
3004
|
+
let s = `position:absolute;margin-left:${Ct(o.x)};margin-top:${Ct(o.y)};width:${Ct(o.width)};height:${Ct(o.height)};z-index:${r.zIndex};visibility:${r.visible ? "visible" : "hidden"}`;
|
|
3005
|
+
n.style && (s += `;${n.style}`);
|
|
3006
|
+
const i = n.attributes.slice(), E = i.findIndex((e) => e.startsWith("type="));
|
|
3007
|
+
var l;
|
|
3008
|
+
i.splice(E + 1, 0, `style='${s}'`), r.alt && i.splice(E + 1, 0, `alt="${l = r.alt, l.replace(/&/g, "&").replace(/</g, "<").replace(/>/g, ">").replace(/"/g, """)}"`);
|
|
3009
|
+
let c = t.substring(n.end);
|
|
3010
|
+
const u = `<x:Anchor>${a.join(", ")}</x:Anchor>`, p = `<x:Row>${r.row}</x:Row><x:Column>${r.col}</x:Column>${r.visible ? "<x:Visible/>" : ""}`;
|
|
3011
|
+
return c = c.includes("<x:AutoFill") ? c.replace("<x:AutoFill", `${u}<x:AutoFill`).replace("</x:ClientData>", `${p}</x:ClientData>`) : c.replace("</x:ClientData>", `${u}${p}</x:ClientData>`), `<v:shape id="_x0000_s${r.shapeId}" ${i.join(" ")}>${c}`;
|
|
2936
3012
|
}
|
|
2937
|
-
function
|
|
2938
|
-
const
|
|
2939
|
-
|
|
2940
|
-
|
|
2941
|
-
|
|
2942
|
-
if (!o) return null;
|
|
2943
|
-
const a = o[0];
|
|
2944
|
-
return n = n.slice(0, o.index), /<v:shapetype\b[^>]*\bid="_x0000_t202"/.test(n) || (n += "<v:shapetype id=\"_x0000_t202\" coordsize=\"21600,21600\" o:spt=\"202\"\n path=\"m,l,21600r21600,l21600,xe\">\n <v:stroke joinstyle=\"miter\"/>\n <v:path gradientshapeok=\"t\" o:connecttype=\"rect\"/>\n </v:shapetype>"), n + r.join("") + a;
|
|
3013
|
+
function mt(e) {
|
|
3014
|
+
const r = pt.exec(e), t = r ? parseInt(r[1], 10) : NaN;
|
|
3015
|
+
let n = 1024 * (isNaN(t) || t < 1 ? 1 : t);
|
|
3016
|
+
for (const r of e.matchAll(/\b(?:id|o:spid)="_x0000_s(\d+)"/g)) n = Math.max(n, parseInt(r[1], 10));
|
|
3017
|
+
return n;
|
|
2945
3018
|
}
|
|
2946
|
-
function
|
|
2947
|
-
const
|
|
2948
|
-
|
|
3019
|
+
function xt(e, r, t) {
|
|
3020
|
+
const n = e && e.trim() ? e : "<xml xmlns:v=\"urn:schemas-microsoft-com:vml\"\n xmlns:o=\"urn:schemas-microsoft-com:office:office\"\n xmlns:x=\"urn:schemas-microsoft-com:office:excel\">\n <o:shapelayout v:ext=\"edit\">\n <o:idmap v:ext=\"edit\" data=\"1\"/>\n </o:shapelayout></xml>";
|
|
3021
|
+
if (0 === r.length) return /<v:shape\b/.test(n) ? n : null;
|
|
3022
|
+
let o = void 0 !== t ? ((e, r) => {
|
|
3023
|
+
const t = pt.exec(e);
|
|
3024
|
+
if (!t) return e;
|
|
3025
|
+
const n = /* @__PURE__ */ new Set(), o = t[1].split(",");
|
|
3026
|
+
for (let e = 0; e < o.length; e++) {
|
|
3027
|
+
const r = parseInt(o[e].trim(), 10);
|
|
3028
|
+
isNaN(r) || n.add(r);
|
|
3029
|
+
}
|
|
3030
|
+
const a = n.size > 0 ? Math.min(...n) : 1, s = Math.floor(r / 1024);
|
|
3031
|
+
let i = !1;
|
|
3032
|
+
for (let e = a; e <= s; e++) n.has(e) || (n.add(e), i = !0);
|
|
3033
|
+
if (!i) return e;
|
|
3034
|
+
const E = Array.from(n).sort((e, r) => e - r).join(",");
|
|
3035
|
+
return e.replace(pt, (e) => e.replace(/\bdata="[^"]*"/, `data="${E}"`));
|
|
3036
|
+
})(n, t) : n;
|
|
3037
|
+
const a = lt.exec(o);
|
|
3038
|
+
if (!a) return null;
|
|
3039
|
+
const s = a[0];
|
|
3040
|
+
return o = o.slice(0, a.index), /<v:shapetype\b[^>]*\bid="_x0000_t202"/.test(o) || (o += "<v:shapetype id=\"_x0000_t202\" coordsize=\"21600,21600\" o:spt=\"202\"\n path=\"m,l,21600r21600,l21600,xe\">\n <v:stroke joinstyle=\"miter\"/>\n <v:path gradientshapeok=\"t\" o:connecttype=\"rect\"/>\n </v:shapetype>"), o + r.join("") + s;
|
|
2949
3041
|
}
|
|
2950
|
-
var
|
|
2951
|
-
function
|
|
2952
|
-
if (!e || "string" != typeof e) return
|
|
3042
|
+
var yt = "16.0000", Mt = 1048575, vt = 16383;
|
|
3043
|
+
function Pt(e) {
|
|
3044
|
+
if (!e || "string" != typeof e) return yt;
|
|
2953
3045
|
if ("local" === e || "dev" === e || "development" === e) return "00.0000";
|
|
2954
3046
|
const r = e.match(/^(\d+)(?:\.(\d+))?(?:\.(\d+))?/);
|
|
2955
|
-
if (!r) return
|
|
3047
|
+
if (!r) return yt;
|
|
2956
3048
|
const t = parseInt(r[1], 10), n = parseInt(r[2] || "0", 10);
|
|
2957
|
-
return t > 99 || n > 9999 ?
|
|
3049
|
+
return t > 99 || n > 9999 ? yt : `${t.toString()}.${n.toString().padStart(4, "0")}`;
|
|
2958
3050
|
}
|
|
2959
|
-
export {
|
|
3051
|
+
export { S as $, Ge as A, y as B, we as C, ge as D, he as E, ve as F, c as G, m as H, Re as I, T as J, u as K, Oe as L, xe as M, Me as N, Ve as O, Pe as P, f as Q, Ie as R, Ye as S, We as T, x as U, L as V, p as W, i as X, A as Y, E as Z, Lr as _, mt as a, _e as b, Dt as c, rt as d, O as et, et as f, Cr as g, Fr as h, xt as i, me as j, Be as k, jr as l, hr as m, Mt as n, Lt as o, Br as p, l as q, Pt as r, St as s, vt as t, R as tt, Zr as u, Ke as v, be as w, $e as x, Xe as y, M as z };
|