@sheetxl/io-xlsx 0.8.0-beta.7 → 0.8.0-beta.9
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/B0Ugu_crqQYpdfQz.cjs +1 -0
- package/browser/cjs/{CDs8etXnw0kbBKKv.cjs → BHM3_D9PsNURVAVy.cjs} +1 -1
- package/browser/cjs/BHWdwAQ322YA8JAZ.cjs +6 -0
- package/browser/cjs/CeuX8p1aBuKTuagi.cjs +2 -0
- package/browser/cjs/DSM4q1dhVVXvsgby.cjs +30 -0
- package/browser/cjs/DiAHwNv2I8RHE9GY.cjs +1 -0
- package/browser/cjs/index.cjs +1 -1
- package/browser/cjs/wrpXlaSBGEicQf6_.cjs +6 -0
- package/browser/esm/{BsNoW41d6hdpxTTS.mjs → Bu64BYvRAlVftMr1.mjs} +4 -4
- package/browser/esm/{CX3yVwe-BnhCk4FY.mjs → C-2KaUyV4gs-sDTZ.mjs} +2 -2
- package/browser/esm/{DUi-V-E_AJwTIqlO.mjs → CRrTMRdN_IcSA_pm.mjs} +2 -2
- package/browser/esm/{CjKioy-GzeSf08f8.mjs → CWt4fDYEbj2hvsl_.mjs} +820 -800
- package/browser/esm/{dsVZVtt5w_yLb967.mjs → Ccnxz-y2WBEgfvvh.mjs} +2606 -1408
- package/browser/esm/{B4eKxNwxJjHLN126.mjs → CxtFawTfwRTCC4Xr.mjs} +1 -1
- package/browser/esm/{CGXxwkCRWLc0gcRQ.mjs → D-epcZSoKLbsAIaC.mjs} +2 -2
- package/browser/esm/DsSIg46AR7IFBN5N.mjs +2298 -0
- package/browser/esm/{cJxidonaVNZHAXiZ.mjs → Dx64JMAGwNNDBkC1.mjs} +1555 -1159
- package/browser/esm/Sv4twwEJDb9dZ91h.mjs +149 -0
- package/browser/esm/index.mjs +2 -2
- package/node/esm/{CMq7eF1vxibUumqT.mjs → BCr4lCI6qQXXN0K1.mjs} +2 -2
- package/node/esm/BPn5XBizKkwaUqXB.mjs +4285 -0
- package/node/esm/{BRQYaMYO4UfhjJHw.mjs → BVV11IlqF6Lmlv8D.mjs} +53 -69
- package/node/esm/{s_yVG0m9KB14YKeN.mjs → BiJEEgltJzx94zIR.mjs} +930 -909
- package/node/esm/{C51yFT2l-6il_xXO.mjs → BsTMtvwpQoPNv95M.mjs} +1 -1
- package/node/esm/{DLBm8l0jyL2fVlxg.mjs → CBtj0-a4l2qux2hA.mjs} +2 -2
- package/node/esm/CkmZuMvRTpva7eQu.mjs +5074 -0
- package/node/esm/index.mjs +4 -4
- package/node/esm/j0RE2usgdljRw_gr.mjs +2345 -0
- package/package.json +3 -3
- package/types/src/AutoFilterRules.d.ts +83 -10
- package/types/src/OOXMLExtensions.d.ts +6 -0
- package/types/src/reader/dom/CustGeomUtils.d.ts +7 -0
- package/types/src/reader/domVisitors/AutoFilterVisitor.d.ts +13 -0
- package/types/src/reader/domVisitors/ColorContainerVisitor.d.ts +7 -1
- package/types/src/reader/domVisitors/DrawingCxnSpVisitor.d.ts +1 -0
- package/types/src/reader/domVisitors/DrawingElementVisitor.d.ts +23 -1
- package/types/src/reader/domVisitors/DrawingGrpSpVisitor.d.ts +9 -0
- package/types/src/reader/domVisitors/DrawingPicVisitor.d.ts +20 -1
- package/types/src/reader/domVisitors/DrawingSpVisitor.d.ts +20 -1
- package/types/src/reader/domVisitors/DrawingVisitor.d.ts +8 -0
- package/types/src/reader/domVisitors/FormControlPrVisitor.d.ts +9 -0
- package/types/src/reader/domVisitors/ShapeTextVisitor.d.ts +44 -0
- package/types/src/reader/domVisitors/TextPropertiesVisitor.d.ts +13 -1
- package/types/src/reader/domVisitors/index.d.ts +4 -2
- package/types/src/reader/saxVisitors/WorksheetVisitor.d.ts +1 -1
- package/types/src/utils/DrawingMLText.d.ts +39 -0
- package/types/src/utils/FormControls.d.ts +97 -0
- package/types/src/writer/builder/Emitter.d.ts +5 -0
- package/types/src/writer/builder/PackageBuilder.d.ts +2 -0
- package/types/src/writer/builder/Types.d.ts +10 -0
- package/types/src/writer/utils/CustGeomUtils.d.ts +5 -0
- package/types/src/writer/utils/DrawMLUtils.d.ts +39 -2
- package/types/src/writer/utils/PrstGeomUtils.d.ts +6 -0
- package/types/src/writer/utils/TextUtils.d.ts +21 -2
- package/browser/cjs/17tMBnuyu4YIxixh.cjs +0 -1
- package/browser/cjs/B7_pDFYCVzt-3hUs.cjs +0 -1
- package/browser/cjs/BxU-OlZIQViQl7gX.cjs +0 -1
- package/browser/cjs/CIpMN7SDVREKQUQE.cjs +0 -6
- package/browser/cjs/CycnxkfuKrDdwoJN.cjs +0 -5
- package/browser/cjs/DHKWtqZ0vQfXrbq1.cjs +0 -2
- package/browser/cjs/MqKQ_B5qRARrRbO4.cjs +0 -24
- package/browser/esm/9n64lXAgZUe3aThr.mjs +0 -159
- package/browser/esm/BvAptAMpZVyBCx6-.mjs +0 -2402
- package/browser/esm/DwcLXqv8-6Tl1zLO.mjs +0 -24
- package/node/esm/BlbtH3EvAf3K4foF.mjs +0 -2450
- package/node/esm/DhSPOg9wN0kD87Tb.mjs +0 -3051
- package/node/esm/KeV-N47eTyh5YE70.mjs +0 -4642
- package/types/src/reader/domVisitors/HyperlinkVisitor.d.ts +0 -6
|
@@ -1,159 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license @sheetxl/io-xlsx - SheetXL - Import/Export from/to Excel - v0.8.0-beta.7
|
|
3
|
-
*
|
|
4
|
-
* (C) 2026-present SheetXL Inc. & Michael T. Ford
|
|
5
|
-
* License: The license can be found at https://www.sheetxl.com/license.
|
|
6
|
-
*/
|
|
7
|
-
import { n as e } from "./DwcLXqv8-6Tl1zLO.mjs";
|
|
8
|
-
import { t } from "./dsVZVtt5w_yLb967.mjs";
|
|
9
|
-
import { CommonUtils as n } from "@sheetxl/utils";
|
|
10
|
-
import { AddressUtils as r, IColor as i, IStyle as a } from "@sheetxl/sdk";
|
|
11
|
-
var o = (e, t, n) => {
|
|
12
|
-
let r = `Unable to read '${e}': ${t?.message ?? t}`;
|
|
13
|
-
n?.onWarning ? n.onWarning(r, e) : console.warn(r);
|
|
14
|
-
}, s = (e, t, n, r = null) => {
|
|
15
|
-
if (!e) return null;
|
|
16
|
-
let i = e;
|
|
17
|
-
i.startsWith("/") && (i = i.substring(1));
|
|
18
|
-
let a = r?.parsedRefs?.get(e);
|
|
19
|
-
if (a !== void 0) return a;
|
|
20
|
-
let s = t(i);
|
|
21
|
-
if (!s) return null;
|
|
22
|
-
let c = s.content;
|
|
23
|
-
try {
|
|
24
|
-
n && (c = n(c, e));
|
|
25
|
-
} catch (t) {
|
|
26
|
-
o(e, t, r);
|
|
27
|
-
}
|
|
28
|
-
return r?.parsedRefs?.set(e, c), c;
|
|
29
|
-
}, c = (e, t, r, i, a = null) => {
|
|
30
|
-
if (!e) return null;
|
|
31
|
-
let s = e;
|
|
32
|
-
s.startsWith("/") && (s = s.substring(1));
|
|
33
|
-
let c = a?.parsedRefs?.get(e);
|
|
34
|
-
if (c !== void 0) return c;
|
|
35
|
-
let l = t(s);
|
|
36
|
-
if (!l) return null;
|
|
37
|
-
let u = l.content;
|
|
38
|
-
try {
|
|
39
|
-
let t = new TextDecoder().decode(u), o = r.parseFromString(t, "text/xml"), s = i.transform(o, e, a ?? n.EmptyObject);
|
|
40
|
-
return a?.parsedRefs?.set(e, s), s;
|
|
41
|
-
} catch (t) {
|
|
42
|
-
o(e, t, a);
|
|
43
|
-
}
|
|
44
|
-
return null;
|
|
45
|
-
}, l = (e, t, n, r, i = null) => {
|
|
46
|
-
if (!e) return null;
|
|
47
|
-
let a = c(e, t, n, r, i);
|
|
48
|
-
if (!a) return null;
|
|
49
|
-
let o = /* @__PURE__ */ new Map(), s = Object.keys(a), l = s.length;
|
|
50
|
-
for (let e = 0; e < l; e++) {
|
|
51
|
-
let t = s[e], n = a[t];
|
|
52
|
-
o.set(t, n);
|
|
53
|
-
}
|
|
54
|
-
return o;
|
|
55
|
-
}, u = (e, t, n, r, i, a = null) => {
|
|
56
|
-
let o = /* @__PURE__ */ new Map(), s = t[e], l = s ? s.length : 0;
|
|
57
|
-
for (let e = 0; e < l; e++) {
|
|
58
|
-
let t = s[e];
|
|
59
|
-
if (!t) continue;
|
|
60
|
-
let l = t;
|
|
61
|
-
l.startsWith("/") && (l = l.substring(1));
|
|
62
|
-
let u = c(l, n, r, i, a);
|
|
63
|
-
o.set(l, u);
|
|
64
|
-
}
|
|
65
|
-
return o;
|
|
66
|
-
}, d = (e) => {
|
|
67
|
-
let t = e.split(/\/+/);
|
|
68
|
-
return t.reduce((e, t, n) => (t === "." ? e.splice(n, 1) : t === ".." && e.splice(n - 1, 2), e), t).join("/");
|
|
69
|
-
}, f = Object.freeze([
|
|
70
|
-
"lt1",
|
|
71
|
-
"dk1",
|
|
72
|
-
"lt2",
|
|
73
|
-
"dk2",
|
|
74
|
-
"accent1",
|
|
75
|
-
"accent2",
|
|
76
|
-
"accent3",
|
|
77
|
-
"accent4",
|
|
78
|
-
"accent5",
|
|
79
|
-
"accent6",
|
|
80
|
-
"hlink",
|
|
81
|
-
"folHlink"
|
|
82
|
-
]), p = (e, t = "auto") => {
|
|
83
|
-
let n, r = e("auto");
|
|
84
|
-
r === void 0 || r !== "1" && r !== "true" || (n = t);
|
|
85
|
-
let a = e("indexed");
|
|
86
|
-
a && (n = a === "64" ? "auto" : `index${a}`);
|
|
87
|
-
let o = e("rgb");
|
|
88
|
-
o && (n = o.toLowerCase(), o.length !== 8 || o.startsWith("FF") || (n = "FF" + o.substring(2, o.length)));
|
|
89
|
-
let s = e("theme");
|
|
90
|
-
s && (n = f[Number(s)]);
|
|
91
|
-
let c = e("tint");
|
|
92
|
-
if (c && (n += ` ${i.AdjustmentType.ETint} ${parseFloat(c)}`), n) return n;
|
|
93
|
-
}, m = (e) => e && e.replace(/^\{([\s\S]+)\}$/, "$1"), h = e({
|
|
94
|
-
EMU_PER_PIXEL: () => _,
|
|
95
|
-
EMU_PER_POINT: () => g,
|
|
96
|
-
fixedPointToDouble: () => b,
|
|
97
|
-
parseAngle: () => S,
|
|
98
|
-
parseAsBoolean: () => C,
|
|
99
|
-
parsePercentage: () => x,
|
|
100
|
-
toPixels: () => y,
|
|
101
|
-
toPoints: () => v
|
|
102
|
-
}), g = 12700, _ = 9525, v = (e) => e ? n.roundAccurately(parseFloat(e) / g, 4) : null, y = (e) => e ? n.roundAccurately(parseFloat(e) / _, 1) : null, b = (e) => (e >> 16) + (65535 & e) / 65536, x = (e) => parseFloat(e) / 1e3, S = (e) => parseFloat(e) / 6e4, C = (e) => e === "true" || e === "1", w = "hiddenXfs", T = (e) => (Array.isArray(e) ? e[1] : e?.v)?.s, E = (e) => {
|
|
103
|
-
if (!e || e.length === 0) return !1;
|
|
104
|
-
let n = r.refsToRuns(e, !0), i = 0;
|
|
105
|
-
for (let e of n) {
|
|
106
|
-
if (e.min > i || e.value?.s === void 0) return !1;
|
|
107
|
-
i = Math.max(i, e.max + 1);
|
|
108
|
-
}
|
|
109
|
-
return i > t;
|
|
110
|
-
}, D = (e, t) => {
|
|
111
|
-
e.protection = {
|
|
112
|
-
...e.protection,
|
|
113
|
-
showFormulas: t
|
|
114
|
-
};
|
|
115
|
-
}, O = (e, t) => {
|
|
116
|
-
if (!t || t.size === 0) return;
|
|
117
|
-
let n = e.styles;
|
|
118
|
-
if (!n) return;
|
|
119
|
-
let r = /* @__PURE__ */ new Set(), i = /* @__PURE__ */ new Set();
|
|
120
|
-
for (let n of e.sheets ?? []) {
|
|
121
|
-
let e = n?.sheet;
|
|
122
|
-
if (!e) continue;
|
|
123
|
-
let a = /* @__PURE__ */ new Set();
|
|
124
|
-
E(e.cols) || a.add(0);
|
|
125
|
-
for (let t of e.directStyles ?? []) a.add(Array.isArray(t) ? t[1] : t.v);
|
|
126
|
-
for (let t of e.rows ?? []) {
|
|
127
|
-
let e = T(t);
|
|
128
|
-
e !== void 0 && a.add(e);
|
|
129
|
-
}
|
|
130
|
-
for (let t of e.cols ?? []) {
|
|
131
|
-
let e = T(t);
|
|
132
|
-
e !== void 0 && a.add(e);
|
|
133
|
-
}
|
|
134
|
-
let o = !1;
|
|
135
|
-
for (let e of a) if (t.has(e)) {
|
|
136
|
-
o = !0;
|
|
137
|
-
break;
|
|
138
|
-
}
|
|
139
|
-
if (o) {
|
|
140
|
-
e.protection = {
|
|
141
|
-
...e.protection ?? { sheet: !0 },
|
|
142
|
-
showFormulas: !1
|
|
143
|
-
};
|
|
144
|
-
for (let e of a) (t.has(e) ? i : r).add(e);
|
|
145
|
-
}
|
|
146
|
-
}
|
|
147
|
-
if (r.size === 0) return;
|
|
148
|
-
let o = n.direct ??= [];
|
|
149
|
-
for (let e of r) e !== 0 && D(o[e] ?? (o[e] = {}), !0);
|
|
150
|
-
for (let e of i) e !== 0 && D(o[e] ?? (o[e] = {}), !1);
|
|
151
|
-
if (r.has(0)) {
|
|
152
|
-
let e = n.named ??= [], t = a.BuiltInName.Normal.toLowerCase(), r = e.find((e) => e.name?.toLowerCase() === t);
|
|
153
|
-
r || (r = {
|
|
154
|
-
name: a.BuiltInName.Normal,
|
|
155
|
-
style: {}
|
|
156
|
-
}, e.push(r)), D(r.style, !0);
|
|
157
|
-
}
|
|
158
|
-
};
|
|
159
|
-
export { C as a, v as c, c as d, u as f, d as h, S as i, l, m, O as n, x as o, p, h as r, y as s, w as t, s as u };
|