@silurus/ooxml 0.83.2 → 0.84.1
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/README.md +23 -6
- package/dist/assets/render-worker-BWPpayBu.js +10 -0
- package/dist/assets/render-worker-CiEWCh_T.js +11 -0
- package/dist/assets/render-worker-Cpmy3GDF.js +24 -0
- package/dist/{canvas-viewer-mechanics-DVGK-fLT.js → canvas-viewer-mechanics-CIfhCgYA.js} +1 -1
- package/dist/chart-ex.mjs +4 -4
- package/dist/{comment-ui-runtime-DD5a3x3k.js → comment-ui-runtime-C5qimVMD.js} +5 -5
- package/dist/{comment-ui-runtime-BelHJt73.js → comment-ui-runtime-CdMMApEN.js} +5 -5
- package/dist/comment-ui-runtime-aPzHfV_A.js +2 -0
- package/dist/{comments-AAaNnQTi.js → comments-BAlAyIhb.js} +1 -1
- package/dist/{document-pull-client-DSx36ZsB.js → document-pull-client-BXw6AAhY.js} +2409 -2390
- package/dist/{docx-DojUJSZd.js → docx-BA1vB0V-.js} +16 -14
- package/dist/docx.mjs +5 -5
- package/dist/docx_parser_bg.wasm +0 -0
- package/dist/{dom-interaction-boundary-CepOlXt6.js → dom-interaction-boundary-DS6BVyHA.js} +1 -1
- package/dist/index.mjs +3 -3
- package/dist/{line-distribute-D7A_wnJg.js → line-distribute-MqInuujx.js} +2 -2
- package/dist/{line-metrics-Bpn7OeZD.js → line-metrics-CXyjyYd5.js} +34 -32
- package/dist/math.mjs +2 -2
- package/dist/node.mjs +9 -9
- package/dist/{plot-area-frame-DHV02PJU.js → plot-area-frame-DuXZzovH.js} +623 -663
- package/dist/{pptx-Wh22eziy.js → pptx-C17oBD8Z.js} +17 -15
- package/dist/pptx.mjs +5 -5
- package/dist/pptx_parser_bg.wasm +0 -0
- package/dist/region-map.mjs +2 -2
- package/dist/{render-DtbFbO5c.js → render-CVeGktZG.js} +1 -1
- package/dist/{render-worker-host-CmPBviYJ.js → render-worker-host-BWdhjVH_.js} +1 -1
- package/dist/{render-worker-host-DCLyw6UR.js → render-worker-host-BbhwA24Y.js} +1 -1
- package/dist/{render-worker-host-D1jcACJV.js → render-worker-host-CbaQivE7.js} +1 -1
- package/dist/{renderer-CYr9YTXM.js → renderer-Bmky2yBc.js} +3 -3
- package/dist/{renderer-module-contract-DLbb7zY0.js → renderer-module-contract-C6sYZvTV.js} +4 -3
- package/dist/{resource-measurement-DuiFWzam.js → resource-measurement-esyGbzAF.js} +2 -2
- package/dist/{session-CxT-t0BX.js → session-Cl0RVnMs.js} +3 -3
- package/dist/{slide-pull-client-B9rcJdO4.js → slide-pull-client-BS0EeZo2.js} +113 -107
- package/dist/{three-d-7MaVzQuZ.js → three-d-B7LsKeOS.js} +128 -127
- package/dist/three-d.mjs +4 -4
- package/dist/tiff-contract-Xjn3qXqK.js +69 -0
- package/dist/tiff.mjs +124 -0
- package/dist/types/chart-ex.d.ts +2 -2
- package/dist/types/docx.d.ts +17 -10
- package/dist/types/index.d.ts +26 -16
- package/dist/types/math.d.ts +1 -1
- package/dist/types/node.d.ts +5 -5
- package/dist/types/pptx.d.ts +18 -10
- package/dist/types/region-map.d.ts +2 -2
- package/dist/types/three-d.d.ts +2 -2
- package/dist/types/tiff.d.ts +9 -0
- package/dist/types/xlsx.d.ts +17 -10
- package/dist/{worksheet-pull-client-DyFsDF4A.js → worksheet-pull-client-B0zfEVau.js} +3 -3
- package/dist/{xlsx-C3beLfwZ.js → xlsx-FyKAiNo-.js} +54 -49
- package/dist/xlsx.mjs +5 -5
- package/dist/xlsx_parser_bg.wasm +0 -0
- package/package.json +7 -1
- package/dist/assets/render-worker-4GSYWsM3.js +0 -11
- package/dist/assets/render-worker-DwFpY197.js +0 -10
- package/dist/assets/render-worker-Dw_wQRIh.js +0 -24
- package/dist/comment-ui-runtime-DTGN3Vyy.js +0 -2
- /package/dist/{comment-occurrence-X54si2ob.js → comment-occurrence-C34fWs_F.js} +0 -0
- /package/dist/{highlight-rect-Hes0z_Mj.js → highlight-rect-MaCt0om0.js} +0 -0
- /package/dist/{mathjax-DwIrafQ6.js → mathjax-DPEX346v.js} +0 -0
- /package/dist/{read-only-comment-decoration-DcFevX_Q.js → read-only-comment-decoration-BYCXoSdC.js} +0 -0
- /package/dist/{read-only-comment-margin-DrUX-YrP.js → read-only-comment-margin-C7b3l0ro.js} +0 -0
- /package/dist/{source-key-BklvnEyQ.js → source-key-DORuuFb-.js} +0 -0
- /package/dist/{transfer-R6NjgBKD.js → transfer-vNOFQuvv.js} +0 -0
- /package/dist/{units-BzZ0gAxs.js → units-EJdC96r6.js} +0 -0
- /package/dist/{visible-index-BFE3PWiY.js → visible-index-DwJzuGmJ.js} +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { F as e, Gt as t, I as n, Jt as r, K as i, Kt as a, N as o, P as s, Qt as c, U as l, Ut as u, Wt as d, Xt as f, Yt as p, qt as m } from "./line-metrics-
|
|
2
|
-
import { n as h, r as g, t as _ } from "./resource-measurement-
|
|
3
|
-
import { t as v } from "./transfer-
|
|
1
|
+
import { F as e, Gt as t, I as n, Jt as r, K as i, Kt as a, N as o, P as s, Qt as c, U as l, Ut as u, Wt as d, Xt as f, Yt as p, qt as m } from "./line-metrics-CXyjyYd5.js";
|
|
2
|
+
import { n as h, r as g, t as _ } from "./resource-measurement-esyGbzAF.js";
|
|
3
|
+
import { t as v } from "./transfer-vNOFQuvv.js";
|
|
4
4
|
//#region packages/xlsx/src/worksheet-resource-limits.ts
|
|
5
5
|
var y = f, b = m, x = r, S = p, C = a, w = u, T = d, E = t, D = Object.freeze({
|
|
6
6
|
archiveEntryCount: 0,
|
|
@@ -1,15 +1,16 @@
|
|
|
1
1
|
import { t as e } from "./chunk-DmhlhrBa.js";
|
|
2
|
-
import { $ as t, A as n, At as r, B as i, C as a, Ct as o, D as s, Dt as c, Et as l, Ht as u, M as d, Mt as f, Nt as p, O as m, Ot as h, Pt as g, Qt as _, R as v, S as y, T as b, V as x, Vt as S, W as C, Zt as w, _ as T, a as E, at as D, c as O, d as k, dt as A, et as j, f as M, ft as N, g as ee, h as P, it as F, j as te, jt as I, lt as L, m as R, n as z, nt as ne, p as B, rt as V, s as re, tt as H, u as ie, ut as U, w as ae, y as oe, z as se } from "./line-metrics-
|
|
3
|
-
import { C as ce, E as le, S as ue, T as de, _ as fe, a as pe, b as me, d as W, f as G, h as K, i as he, l as ge, m as _e, p as ve, t as ye, u as q, v as be, w as xe, x as Se, y as Ce } from "./canvas-viewer-mechanics-
|
|
2
|
+
import { $ as t, A as n, At as r, B as i, C as a, Ct as o, D as s, Dt as c, Et as l, Ht as u, M as d, Mt as f, Nt as p, O as m, Ot as h, Pt as g, Qt as _, R as v, S as y, T as b, V as x, Vt as S, W as C, Zt as w, _ as T, a as E, at as D, c as O, d as k, dt as A, et as j, f as M, ft as N, g as ee, h as P, it as F, j as te, jt as I, lt as L, m as R, n as z, nt as ne, p as B, rt as V, s as re, tt as H, u as ie, ut as U, w as ae, y as oe, z as se } from "./line-metrics-CXyjyYd5.js";
|
|
3
|
+
import { C as ce, E as le, S as ue, T as de, _ as fe, a as pe, b as me, d as W, f as G, h as K, i as he, l as ge, m as _e, p as ve, t as ye, u as q, v as be, w as xe, x as Se, y as Ce } from "./canvas-viewer-mechanics-CIfhCgYA.js";
|
|
4
4
|
import { a as we, i as Te, t as Ee } from "./bounded-raw-part-cache-C6ro6Ezf.js";
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import { n as
|
|
12
|
-
import {
|
|
5
|
+
import { c as De, o as Oe, s as ke } from "./tiff-contract-Xjn3qXqK.js";
|
|
6
|
+
import { C as Ae, _ as J, c as je, h as Me, in as Ne, k as Pe, l as Fe, nn as Ie, o as Le, s as Re, v as ze, w as Be } from "./plot-area-frame-DuXZzovH.js";
|
|
7
|
+
import { a as Ve, i as Y, r as He } from "./units-EJdC96r6.js";
|
|
8
|
+
import { L as Ue } from "./three-d-B7LsKeOS.js";
|
|
9
|
+
import { k as We } from "./renderer-Bmky2yBc.js";
|
|
10
|
+
import { i as Ge } from "./resource-measurement-esyGbzAF.js";
|
|
11
|
+
import { n as Ke } from "./renderer-module-contract-C6sYZvTV.js";
|
|
12
|
+
import { n as qe, r as Je, t as Ye } from "./visible-index-DwJzuGmJ.js";
|
|
13
|
+
import { a as Xe, c as Ze, d as Qe, i as $e, l as et, n as tt, o as nt, s as rt, t as it, u as at } from "./worksheet-pull-client-B0zfEVau.js";
|
|
13
14
|
//#region packages/core/src/sparkline/renderer.ts
|
|
14
15
|
function ot(e, t, n) {
|
|
15
16
|
let { values: r } = n;
|
|
@@ -646,16 +647,16 @@ function qt(e) {
|
|
|
646
647
|
}
|
|
647
648
|
function Jt() {
|
|
648
649
|
let e = /* @__PURE__ */ new Date();
|
|
649
|
-
return
|
|
650
|
+
return Fe(new Date(Date.UTC(e.getFullYear(), e.getMonth(), e.getDate())), !1);
|
|
650
651
|
}
|
|
651
652
|
function Yt() {
|
|
652
|
-
return
|
|
653
|
+
return Fe(new Date(Date.now()), !1);
|
|
653
654
|
}
|
|
654
655
|
function Xt(e, t, n) {
|
|
655
|
-
return Math.floor(
|
|
656
|
+
return Math.floor(Fe(new Date(Date.UTC(e, t - 1, n)), !1));
|
|
656
657
|
}
|
|
657
658
|
function Zt(e) {
|
|
658
|
-
return
|
|
659
|
+
return je(Math.floor(e), !1);
|
|
659
660
|
}
|
|
660
661
|
function Qt(e) {
|
|
661
662
|
let t = Zt(e);
|
|
@@ -825,7 +826,7 @@ function dn(e) {
|
|
|
825
826
|
};
|
|
826
827
|
}
|
|
827
828
|
function fn(e, t, n = !1) {
|
|
828
|
-
let r =
|
|
829
|
+
let r = je(e, n), i = r.getUTCFullYear(), a = r.getUTCMonth() + 1, o = r.getUTCDate(), s = r.getUTCDay(), c = r.getUTCHours(), l = r.getUTCMinutes(), u = r.getUTCSeconds(), d = t.split(";")[0], f = /am\/pm|a\/p/i.test(d), p = null, m = () => p ??= dn(r), h = "", g = 0, _ = !1;
|
|
829
830
|
for (; g < d.length;) {
|
|
830
831
|
let t = d[g];
|
|
831
832
|
if (t === "\"") {
|
|
@@ -912,7 +913,7 @@ function yn(e) {
|
|
|
912
913
|
return t ? `-${i}` : i;
|
|
913
914
|
}
|
|
914
915
|
function bn(e, t, n, r = !1) {
|
|
915
|
-
if (t === 14 && !n) return { text:
|
|
916
|
+
if (t === 14 && !n) return { text: Le(e, r) };
|
|
916
917
|
let i = an[t];
|
|
917
918
|
if (i) return { text: fn(e, i, r) };
|
|
918
919
|
if (n && n.trim().toLowerCase() === "general") return { text: yn(e) };
|
|
@@ -1145,11 +1146,11 @@ function jn(e, t, n) {
|
|
|
1145
1146
|
}
|
|
1146
1147
|
if (r.exp) {
|
|
1147
1148
|
let e = Math.max(r.intSpec.length, 1), t = r.fracSpec.length, n = 0, i = 0;
|
|
1148
|
-
o !== 0 && (i = Math.floor(Math.log10(o)), i = Math.floor(i / e) * e, n = o / 10 ** i, parseFloat(
|
|
1149
|
-
let [s, c = ""] =
|
|
1149
|
+
o !== 0 && (i = Math.floor(Math.log10(o)), i = Math.floor(i / e) * e, n = o / 10 ** i, parseFloat(Re(n, t)) >= 10 ** e && (i += e, n = o / 10 ** i));
|
|
1150
|
+
let [s, c = ""] = Re(n, t).split(".");
|
|
1150
1151
|
return a + Mn(r, On(s, r.intSpec, !1), kn(c, r.fracSpec), "E" + (i < 0 ? "-" : r.exp.plus ? "+" : "") + String(Math.abs(i)).padStart(r.exp.width, "0"));
|
|
1151
1152
|
}
|
|
1152
|
-
let s = r.fracSpec.length, [c, l = ""] =
|
|
1153
|
+
let s = r.fracSpec.length, [c, l = ""] = Re(o, s).split("."), u = c.replace(/^0+/, ""), d = /[0]/.test(r.intSpec) || r.intSpec === "" && !1;
|
|
1153
1154
|
return u === "" && d && (u = "0"), a + Mn(r, On(u, r.intSpec, r.grouping), kn(l, r.fracSpec), "");
|
|
1154
1155
|
}
|
|
1155
1156
|
function Mn(e, t, n, r) {
|
|
@@ -2049,7 +2050,7 @@ function Nr(e, t, n, r) {
|
|
|
2049
2050
|
if (jr.has(s)) return jr.get(s);
|
|
2050
2051
|
let c = Mr[t];
|
|
2051
2052
|
if (!c) return jr.set(s, null), null;
|
|
2052
|
-
let l = c.length, u =
|
|
2053
|
+
let l = c.length, u = De(l, l);
|
|
2053
2054
|
if (!u) return jr.set(s, null), null;
|
|
2054
2055
|
let d = u.getContext("2d");
|
|
2055
2056
|
if (!d) return jr.set(s, null), null;
|
|
@@ -3412,7 +3413,7 @@ function Ui(e, t, n, r, i, a, o, s, c, l, u, d, f, p, m, h, g = t.images) {
|
|
|
3412
3413
|
}
|
|
3413
3414
|
if (S <= 0 || C <= 0) continue;
|
|
3414
3415
|
let w = Tr(u + (b - _) - c, S, h, m), T = d + (x - v) - l;
|
|
3415
|
-
w + S < y || w > y + f || T + C < d || T > d + p || (t.alpha != null && t.alpha < 1 ? (e.save(), e.globalAlpha = t.alpha,
|
|
3416
|
+
w + S < y || w > y + f || T + C < d || T > d + p || (t.alpha != null && t.alpha < 1 ? (e.save(), e.globalAlpha = t.alpha, Ie(e, o, t.srcRect, w, T, S, C), e.restore()) : Ie(e, o, t.srcRect, w, T, S, C));
|
|
3416
3417
|
}
|
|
3417
3418
|
e.restore();
|
|
3418
3419
|
}
|
|
@@ -3488,7 +3489,7 @@ function Gi(e, t, n, r, i, a, s, c) {
|
|
|
3488
3489
|
let n = c?.get(hr(t.geom.imagePath, t.geom.duotone));
|
|
3489
3490
|
if (n) {
|
|
3490
3491
|
let r = t.geom.alpha;
|
|
3491
|
-
r != null && r < 1 ? (e.save(), e.globalAlpha = r,
|
|
3492
|
+
r != null && r < 1 ? (e.save(), e.globalAlpha = r, Ie(e, n, t.geom.srcRect, 0, 0, i, a), e.restore()) : Ie(e, n, t.geom.srcRect, 0, 0, i, a);
|
|
3492
3493
|
}
|
|
3493
3494
|
}
|
|
3494
3495
|
t.text && Zi(e, t.text, i, a, s), e.restore();
|
|
@@ -3701,7 +3702,7 @@ function $i(e) {
|
|
|
3701
3702
|
function ea(e, t, n, r) {
|
|
3702
3703
|
let i = $i(t);
|
|
3703
3704
|
if (i) {
|
|
3704
|
-
if (
|
|
3705
|
+
if (Me(e, i, 1 / Y), i.fill) {
|
|
3705
3706
|
let a = ze(i.fill, e, 0, 0, n, r, t.rot);
|
|
3706
3707
|
a && (e.strokeStyle = a);
|
|
3707
3708
|
}
|
|
@@ -3841,7 +3842,7 @@ function aa(e) {
|
|
|
3841
3842
|
}
|
|
3842
3843
|
}
|
|
3843
3844
|
function oa(e) {
|
|
3844
|
-
return
|
|
3845
|
+
return Ae(e);
|
|
3845
3846
|
}
|
|
3846
3847
|
function sa(e) {
|
|
3847
3848
|
switch (e) {
|
|
@@ -3969,26 +3970,27 @@ function Aa(e, t, n, r, i) {
|
|
|
3969
3970
|
};
|
|
3970
3971
|
return g(u, p, s.offsetOf(h.cols + 1), s.offsetOf(n.col), s.offsetOf(n.col + n.cols)) && g(d, m, c.offsetOf(h.rows + 1), c.offsetOf(n.row), c.offsetOf(n.row + n.rows));
|
|
3971
3972
|
}
|
|
3972
|
-
async function ja(e, t, n, r, i = 0, a = 0, o = null, s = null, c, l = !1) {
|
|
3973
|
-
let
|
|
3974
|
-
if (
|
|
3975
|
-
let
|
|
3976
|
-
if (!
|
|
3977
|
-
let
|
|
3978
|
-
widthPt:
|
|
3979
|
-
heightPt:
|
|
3973
|
+
async function ja(e, t, n, r, i = 0, a = 0, o = null, s = null, c, l = !1, u) {
|
|
3974
|
+
let d = t === "image/svg+xml";
|
|
3975
|
+
if (d && s) return null;
|
|
3976
|
+
let f = Ne(t, o, i, a);
|
|
3977
|
+
if (!f) return null;
|
|
3978
|
+
let p = () => Ge(e, t, s, r, {
|
|
3979
|
+
widthPt: f.widthPt,
|
|
3980
|
+
heightPt: f.heightPt,
|
|
3980
3981
|
offscreenFactory: c,
|
|
3981
|
-
failClosedOnDuotoneFailure: l
|
|
3982
|
-
|
|
3982
|
+
failClosedOnDuotoneFailure: l,
|
|
3983
|
+
tiff: u
|
|
3984
|
+
}), m = {
|
|
3983
3985
|
svgImagePath: n,
|
|
3984
3986
|
srcRect: o
|
|
3985
3987
|
};
|
|
3986
|
-
if (!s && D(
|
|
3987
|
-
return await U(
|
|
3988
|
+
if (!s && D(m)) try {
|
|
3989
|
+
return await U(m.svgImagePath, r);
|
|
3988
3990
|
} catch {
|
|
3989
|
-
return
|
|
3991
|
+
return d ? U(e, r) : p();
|
|
3990
3992
|
}
|
|
3991
|
-
return
|
|
3993
|
+
return d ? U(e, r) : p();
|
|
3992
3994
|
}
|
|
3993
3995
|
async function Ma(e, t, n, r) {
|
|
3994
3996
|
if (t.clear(), !n) return;
|
|
@@ -4020,7 +4022,7 @@ async function Ma(e, t, n, r) {
|
|
|
4020
4022
|
});
|
|
4021
4023
|
}
|
|
4022
4024
|
let c = (e.charts ?? []).filter((t) => Aa(t, e, r?.viewport, o, s)).map((e) => e.chart);
|
|
4023
|
-
for (let e of
|
|
4025
|
+
for (let e of Pe(c)) a.set(Be(e), {
|
|
4024
4026
|
imagePath: e.imagePath,
|
|
4025
4027
|
mimeType: e.mimeType,
|
|
4026
4028
|
svgImagePath: e.svgImagePath,
|
|
@@ -4032,10 +4034,10 @@ async function Ma(e, t, n, r) {
|
|
|
4032
4034
|
});
|
|
4033
4035
|
a.size !== 0 && await Promise.all([...a.entries()].map(async ([e, n]) => {
|
|
4034
4036
|
try {
|
|
4035
|
-
let a = await ja(n.imagePath, n.mimeType, n.svgImagePath, i, n.widthPt, n.heightPt, n.srcRect, n.duotone, r?.offscreenFactory, n.failClosedOnDuotoneFailure ?? !1);
|
|
4037
|
+
let a = await ja(n.imagePath, n.mimeType, n.svgImagePath, i, n.widthPt, n.heightPt, n.srcRect, n.duotone, r?.offscreenFactory, n.failClosedOnDuotoneFailure ?? !1, r?.tiff);
|
|
4036
4038
|
t.set(e, a);
|
|
4037
4039
|
} catch (n) {
|
|
4038
|
-
if (
|
|
4040
|
+
if (ke(n)) throw n;
|
|
4039
4041
|
t.delete(e);
|
|
4040
4042
|
}
|
|
4041
4043
|
}));
|
|
@@ -4071,7 +4073,8 @@ async function Ia(e, t, n, r = {}) {
|
|
|
4071
4073
|
height: u,
|
|
4072
4074
|
cellScale: r.cellScale,
|
|
4073
4075
|
freezeRows: r.freezeRows,
|
|
4074
|
-
freezeCols: r.freezeCols
|
|
4076
|
+
freezeCols: r.freezeCols,
|
|
4077
|
+
tiff: e.tiff
|
|
4075
4078
|
}), e.math && Yi(o) && await Xi(o, e.math), r[Oa]?.() === !1) return;
|
|
4076
4079
|
let f = r.dpr ?? j(), p = Ue(l * f, u * f), m = p.clamped ? f * p.scale : f, h = p.width, g = p.height;
|
|
4077
4080
|
if (t.width !== h && (t.width = h), t.height !== g && (t.height = g), H(t)) {
|
|
@@ -4258,6 +4261,7 @@ var Ya = Symbol("retain-xlsx-viewer-fonts"), Xa = Symbol("prepare-xlsx-viewer-ro
|
|
|
4258
4261
|
threeD;
|
|
4259
4262
|
regionMap;
|
|
4260
4263
|
chartEx;
|
|
4264
|
+
tiff;
|
|
4261
4265
|
googleFontNames = [];
|
|
4262
4266
|
retainedFontSets = /* @__PURE__ */ new Map();
|
|
4263
4267
|
fontsDestroyed = !1;
|
|
@@ -4307,7 +4311,7 @@ var Ya = Symbol("retain-xlsx-viewer-fonts"), Xa = Symbol("prepare-xlsx-viewer-ro
|
|
|
4307
4311
|
s = le(await de(s, n.password));
|
|
4308
4312
|
let c = s === i;
|
|
4309
4313
|
o.setSourceBytes(s.byteLength), o.checkpoint("container ready");
|
|
4310
|
-
let l = a === "worker" ? (await import("./render-worker-host-
|
|
4314
|
+
let l = a === "worker" ? (await import("./render-worker-host-BWdhjVH_.js")).createRenderWorker() : new pt(), u;
|
|
4311
4315
|
try {
|
|
4312
4316
|
return u = new e(l, a, n.wasmUrl), u.metrics = o, await u._load(s, n, r.policy, (e) => o.observeUsage(e), c), o.checkpoint("workbook index ready"), o.succeed({ sheets: u.sheetCount }), u;
|
|
4313
4317
|
} catch (e) {
|
|
@@ -4324,9 +4328,9 @@ var Ya = Symbol("retain-xlsx-viewer-fonts"), Xa = Symbol("prepare-xlsx-viewer-ro
|
|
|
4324
4328
|
cells: 0,
|
|
4325
4329
|
ownedUtf8Bytes: 0,
|
|
4326
4330
|
jsonBytes: 0
|
|
4327
|
-
}, this.sheetCache.clear(), await this.worksheetPullClient?.cancelAll("closed"), this.worksheetPullClient = null, this.generation = (this.generation ?? 0) + 1, this.resourcePolicy = n, this.workerTimeoutMs = t.workerTimeoutMs, this.math = this._mode === "worker" ? void 0 : t.math, this.threeD = this._mode === "worker" ? void 0 : t.threeD, this.regionMap = this._mode === "worker" ? void 0 : t.regionMap, this.chartEx = this._mode === "worker" ? void 0 : t.chartEx;
|
|
4331
|
+
}, this.sheetCache.clear(), await this.worksheetPullClient?.cancelAll("closed"), this.worksheetPullClient = null, this.generation = (this.generation ?? 0) + 1, this.resourcePolicy = n, this.workerTimeoutMs = t.workerTimeoutMs, this.math = this._mode === "worker" ? void 0 : t.math, this.threeD = this._mode === "worker" ? void 0 : t.threeD, this.regionMap = this._mode === "worker" ? void 0 : t.regionMap, this.chartEx = this._mode === "worker" ? void 0 : t.chartEx, this.tiff = this._mode === "worker" ? void 0 : t.tiff;
|
|
4328
4332
|
let a = this._mode === "worker" ? Ke(t) : void 0;
|
|
4329
|
-
t.math && this._mode === "worker" && !a?.math && console.warn("[ooxml] a custom math renderer cannot cross the worker boundary; equations will be skipped in mode: 'worker'. Use the math renderer from @silurus/ooxml/math."), t.threeD && this._mode === "worker" && !a?.threeD && console.warn("[ooxml] a custom 3-D chart renderer cannot cross the worker boundary; charts use their 2-D family fallback in mode: 'worker'. Use the renderer from @silurus/ooxml/three-d."), t.regionMap && this._mode === "worker" && !a?.regionMap && console.warn("[ooxml] a custom Region Map renderer cannot cross the worker boundary; geospatial charts use the unsupported-chart placeholder in mode: 'worker'. Use the renderer from @silurus/ooxml/region-map."), t.chartEx && this._mode === "worker" && !a?.chartEx && console.warn("[ooxml] a custom ChartEx renderer cannot cross the worker boundary; ChartEx charts use the unsupported-chart placeholder in mode: 'worker'. Use the renderer from @silurus/ooxml/chart-ex.");
|
|
4333
|
+
t.math && this._mode === "worker" && !a?.math && console.warn("[ooxml] a custom math renderer cannot cross the worker boundary; equations will be skipped in mode: 'worker'. Use the math renderer from @silurus/ooxml/math."), t.threeD && this._mode === "worker" && !a?.threeD && console.warn("[ooxml] a custom 3-D chart renderer cannot cross the worker boundary; charts use their 2-D family fallback in mode: 'worker'. Use the renderer from @silurus/ooxml/three-d."), t.regionMap && this._mode === "worker" && !a?.regionMap && console.warn("[ooxml] a custom Region Map renderer cannot cross the worker boundary; geospatial charts use the unsupported-chart placeholder in mode: 'worker'. Use the renderer from @silurus/ooxml/region-map."), t.chartEx && this._mode === "worker" && !a?.chartEx && console.warn("[ooxml] a custom ChartEx renderer cannot cross the worker boundary; ChartEx charts use the unsupported-chart placeholder in mode: 'worker'. Use the renderer from @silurus/ooxml/chart-ex."), t.tiff && this._mode === "worker" && !a?.tiff && console.warn("[ooxml] a custom TIFF codec cannot cross the worker boundary; TIFF images will be skipped in mode: 'worker'. Use the codec from @silurus/ooxml/tiff.");
|
|
4330
4334
|
let o = i ? e.slice(0) : e, s = await this.bridge.request((e) => this._mode === "worker" ? {
|
|
4331
4335
|
type: "parse",
|
|
4332
4336
|
id: e,
|
|
@@ -4555,7 +4559,8 @@ var Ya = Symbol("retain-xlsx-viewer-fonts"), Xa = Symbol("prepare-xlsx-viewer-ro
|
|
|
4555
4559
|
math: this.math,
|
|
4556
4560
|
threeD: this.threeD,
|
|
4557
4561
|
regionMap: this.regionMap,
|
|
4558
|
-
chartEx: this.chartEx
|
|
4562
|
+
chartEx: this.chartEx,
|
|
4563
|
+
tiff: this.tiff
|
|
4559
4564
|
}, e, n, {
|
|
4560
4565
|
...s,
|
|
4561
4566
|
fetchImage: this._fetchImage
|
|
@@ -5740,7 +5745,7 @@ function is(e) {
|
|
|
5740
5745
|
//#region packages/xlsx/src/viewer.ts
|
|
5741
5746
|
var as = Symbol("XlsxViewer.borrowedWorkbook"), os;
|
|
5742
5747
|
function ss() {
|
|
5743
|
-
return os ??= import("./comment-ui-runtime-
|
|
5748
|
+
return os ??= import("./comment-ui-runtime-aPzHfV_A.js");
|
|
5744
5749
|
}
|
|
5745
5750
|
var cs = 150, ls = 280, us = 200, ds = 240, fs = 200, ps = 30, ms = 50, hs = 1, gs = 1, _s = .45, vs = "data-xlsx-viewer-styles", ys = ".xlsx-tab-strip::-webkit-scrollbar{display:none}[data-xlsx-viewport-input]:focus{outline:none}[data-xlsx-viewport-input]:focus-visible{outline:2px solid var(--ooxml-xlsx-focus-ring,transparent);outline-offset:-2px}.xlsx-tab-nav{background:transparent;transition:background 0.1s;}.xlsx-tab-nav:hover{background:color-mix(in srgb,var(--ooxml-xlsx-chrome-text,#444) 8%,transparent);}.xlsx-zoom-slider{-webkit-appearance:none;appearance:none;background:transparent;height:15px;margin:0;}.xlsx-zoom-slider::-webkit-slider-runnable-track{height:4px;background:var(--ooxml-xlsx-chrome-border,#c4c4c4);border-radius:2px;}.xlsx-zoom-slider::-webkit-slider-thumb{-webkit-appearance:none;appearance:none;width:12px;height:12px;margin-top:-4px;border-radius:50%;background:var(--ooxml-xlsx-chrome-text-muted,#808080);cursor:pointer;}.xlsx-zoom-slider:hover::-webkit-slider-thumb{background:var(--ooxml-xlsx-chrome-text,#5f5f5f);}.xlsx-zoom-slider::-moz-range-track{height:4px;background:var(--ooxml-xlsx-chrome-border,#c4c4c4);border-radius:2px;}.xlsx-zoom-slider::-moz-range-thumb{width:12px;height:12px;border:none;border-radius:50%;background:var(--ooxml-xlsx-chrome-text-muted,#808080);cursor:pointer;}";
|
|
5746
5751
|
function bs(e) {
|
|
@@ -8071,14 +8076,14 @@ var Gs = class {
|
|
|
8071
8076
|
MAX_SELECTION_AREAS: () => 128,
|
|
8072
8077
|
MAX_SELECTION_CONTEXT_CELLS: () => wo,
|
|
8073
8078
|
MAX_SELECTION_CONTEXT_TEXT_CHARACTERS: () => To,
|
|
8074
|
-
OoxmlDecodedImageLimitError: () =>
|
|
8079
|
+
OoxmlDecodedImageLimitError: () => Oe,
|
|
8075
8080
|
OoxmlError: () => w,
|
|
8076
8081
|
OoxmlResourceLimitError: () => _,
|
|
8077
8082
|
XlsxSheetViewer: () => qs,
|
|
8078
8083
|
XlsxViewer: () => Ks,
|
|
8079
8084
|
XlsxWorkbook: () => Qa,
|
|
8080
8085
|
autoResize: () => xe,
|
|
8081
|
-
isOoxmlDecodedImageLimitError: () =>
|
|
8086
|
+
isOoxmlDecodedImageLimitError: () => ke,
|
|
8082
8087
|
openExternalHyperlink: () => E,
|
|
8083
8088
|
resolveSharedStrings: () => $e
|
|
8084
8089
|
});
|
package/dist/xlsx.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { Qt as e, Zt as t, a as n } from "./line-metrics-
|
|
2
|
-
import { w as r } from "./canvas-viewer-mechanics-
|
|
3
|
-
import {
|
|
4
|
-
import { a as o, i as s, n as c, o as l, r as u, s as d } from "./xlsx-
|
|
5
|
-
import { i as f } from "./worksheet-pull-client-
|
|
1
|
+
import { Qt as e, Zt as t, a as n } from "./line-metrics-CXyjyYd5.js";
|
|
2
|
+
import { w as r } from "./canvas-viewer-mechanics-CIfhCgYA.js";
|
|
3
|
+
import { o as i, s as a } from "./tiff-contract-Xjn3qXqK.js";
|
|
4
|
+
import { a as o, i as s, n as c, o as l, r as u, s as d } from "./xlsx-FyKAiNo-.js";
|
|
5
|
+
import { i as f } from "./worksheet-pull-client-B0zfEVau.js";
|
|
6
6
|
export { s as MAX_SELECTION_AREAS, o as MAX_SELECTION_CONTEXT_CELLS, l as MAX_SELECTION_CONTEXT_TEXT_CHARACTERS, i as OoxmlDecodedImageLimitError, t as OoxmlError, e as OoxmlResourceLimitError, c as XlsxSheetViewer, u as XlsxViewer, d as XlsxWorkbook, r as autoResize, a as isOoxmlDecodedImageLimitError, n as openExternalHyperlink, f as resolveSharedStrings };
|
package/dist/xlsx_parser_bg.wasm
CHANGED
|
Binary file
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@silurus/ooxml",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.84.1",
|
|
4
4
|
"description": "Browser-based OOXML viewer (docx/xlsx/pptx) — Rust/WASM parser + Canvas renderer",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "Yuki Yokotani <silurus.dev@gmail.com>",
|
|
@@ -78,6 +78,11 @@
|
|
|
78
78
|
"import": "./dist/chart-ex.mjs",
|
|
79
79
|
"default": "./dist/chart-ex.mjs"
|
|
80
80
|
},
|
|
81
|
+
"./tiff": {
|
|
82
|
+
"types": "./dist/types/tiff.d.ts",
|
|
83
|
+
"import": "./dist/tiff.mjs",
|
|
84
|
+
"default": "./dist/tiff.mjs"
|
|
85
|
+
},
|
|
81
86
|
"./node": {
|
|
82
87
|
"types": "./dist/types/node.d.ts",
|
|
83
88
|
"import": "./dist/node.mjs",
|
|
@@ -130,6 +135,7 @@
|
|
|
130
135
|
"check:optional-three-d": "node scripts/check-optional-three-d.mjs dist",
|
|
131
136
|
"check:optional-region-map": "node scripts/check-optional-region-map.mjs dist",
|
|
132
137
|
"check:optional-chart-ex": "node scripts/check-optional-chart-ex.mjs dist",
|
|
138
|
+
"check:optional-tiff": "node scripts/check-optional-tiff.mjs dist",
|
|
133
139
|
"lint": "ast-grep scan",
|
|
134
140
|
"lint:test": "ast-grep test --skip-snapshot-tests",
|
|
135
141
|
"test:docx-boundaries": "node --test scripts/check-docx-layout-boundaries.test.mjs",
|