@silurus/ooxml 0.89.7 → 0.89.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/README.md +9 -3
- package/dist/assets/render-worker-CSJJ7vFD.js +15 -0
- package/dist/assets/render-worker-Ck21oePL.js +16 -0
- package/dist/assets/render-worker-jGsxSIGb.js +35 -0
- package/dist/{bounded-raw-part-cache-B8t03tSP.js → bounded-raw-part-cache-B5a6cGKO.js} +1713 -1515
- package/dist/{canvas-viewer-mechanics-DI38gHNV.js → canvas-viewer-mechanics-BsqaoYgK.js} +2 -2
- package/dist/{cfb-guard-BIaHdonq.js → cfb-guard-DzYlucez.js} +1 -1
- package/dist/chart-ex.mjs +367 -367
- package/dist/{comment-overlay-controller-Crm5Syhx.js → comment-overlay-controller-b3tKmzMa.js} +29 -25
- package/dist/{comment-ui-runtime-DKlEfBPp.js → comment-ui-runtime-BlgDzQx_.js} +3 -3
- package/dist/{comment-ui-runtime-BfEPgl5r.js → comment-ui-runtime-Bp37ytDC.js} +3 -3
- package/dist/{document-model-source-xnkMoTZ_.js → document-model-source-BlMfm6po.js} +37 -37
- package/dist/{document-pull-client-CzhPbnY_.js → document-pull-client-_G-DIh2T.js} +17071 -13819
- package/dist/{document-pull-worker-Bkewz-So.js → document-pull-worker-hMKJ5RdB.js} +14 -14
- package/dist/{docx-BWyACb-n.js → docx-DE-Di6SH.js} +33 -33
- package/dist/{docx-BgCQiuuN.js → docx-Do90Z4L7.js} +593 -593
- package/dist/{docx-model-source-DCRFgO7-.js → docx-model-source-zYIufUjR.js} +6 -6
- package/dist/docx.mjs +4 -4
- package/dist/docx_parser_bg.wasm +0 -0
- package/dist/{drawingml-shape-BcXkRayC.js → drawingml-shape-B1_kg4BV.js} +55 -55
- package/dist/{duotone-BI7CoghW.js → duotone-GK4Hqn7f.js} +1 -1
- package/dist/{emf-DgUBx9BU.js → emf--QWY-UlT.js} +50 -50
- package/dist/{font-preload-demand-B6HPFxDp.js → font-preload-demand-NqcVKIpX.js} +2 -2
- package/dist/{grid-geometry-CqTDvpDr.js → grid-geometry-DpMAiSZb.js} +1 -1
- package/dist/{host-layout-measure-CXKOWA5J.js → host-layout-measure-IFLllYwV.js} +1 -1
- package/dist/index.mjs +3 -3
- package/dist/internal-companion.mjs +2 -2
- package/dist/{line-distribute-DR9Qwd3u.js → line-distribute-CwtditQo.js} +31 -25
- package/dist/{model-source-DcI3vC00.js → model-source-Cch44xsb.js} +2 -2
- package/dist/{model-source-session-BlQWNyj2.js → model-source-session-ClNCRDOg.js} +21 -21
- package/dist/{model-source-session-D0LF49Ve.js → model-source-session-DRcqFGfM.js} +2 -2
- package/dist/{model-source-session-BCteVilS.js → model-source-session-DSABX94B.js} +2 -2
- package/dist/node.mjs +5 -5
- package/dist/{plot-area-frame-D3JtHvov.js → plot-area-frame-DNYMd9Pf.js} +1914 -1890
- package/dist/{pptx-SmjDGyub.js → pptx-C1CiFW1D.js} +35 -33
- package/dist/{pptx-CfCiVlNB.js → pptx-DbjWegUB.js} +283 -266
- package/dist/{pptx-model-source-B2Irk68a.js → pptx-model-source-C9TuBisH.js} +18 -12
- package/dist/pptx-parsed-slides-BMGr4khe.js +8 -0
- package/dist/pptx.mjs +5 -5
- package/dist/pptx_parser_bg.wasm +0 -0
- package/dist/{presentation-model-source-DL6duh5l.js → presentation-model-source-DLNioq7T.js} +6 -6
- package/dist/region-map.mjs +39 -39
- package/dist/{render-CMUEAeHp.js → render-Bf_Gywxw.js} +32 -30
- package/dist/{render-worker-host-CZHIKTtZ.js → render-worker-host-CVr53kg0.js} +1 -1
- package/dist/{render-worker-host-CtlBbau5.js → render-worker-host-EgUrirnQ.js} +1 -1
- package/dist/{render-worker-host-G1fnymI8.js → render-worker-host-pKls3F_t.js} +1 -1
- package/dist/renderer-DpTePxGq.js +5887 -0
- package/dist/{renderer-B4KIpz-2.js → renderer-DuYC3xXi.js} +1336 -1224
- package/dist/{resource-measurement-D2bu0Qfx.js → resource-measurement-CfJtbwiR.js} +129 -129
- package/dist/{session-KIWcCCP2.js → session-DPXK_lpI.js} +64 -64
- package/dist/{slide-pull-client-BUuJQQVE.js → slide-pull-client-3g6TxaKa.js} +1421 -1421
- package/dist/{three-d-ByHGsYrX.js → three-d-BfMZVR0w.js} +98 -98
- package/dist/three-d.mjs +678 -678
- package/dist/types/chart-ex.d.ts +5 -2
- package/dist/types/docx.d.ts +30 -8
- package/dist/types/index.d.ts +37 -12
- package/dist/types/node.d.ts +28 -6
- package/dist/types/pptx.d.ts +13 -7
- package/dist/types/region-map.d.ts +5 -2
- package/dist/types/three-d.d.ts +5 -2
- package/dist/types/xlsx.d.ts +10 -7
- package/dist/{wasm-runtime-generation-BLweKv8r.js → wasm-runtime-generation-D97yoAXz.js} +17 -17
- package/dist/{workbook-model-source-J9ir5Kov.js → workbook-model-source-D1dmkDMP.js} +6 -6
- package/dist/{worksheet-pull-client-Du0MuIro.js → worksheet-pull-client-BudfclVl.js} +84 -84
- package/dist/{xlsx-BbQ7RcNc.js → xlsx-DA0uR1B1.js} +44 -44
- package/dist/{xlsx-ClQiNSrr.js → xlsx-DBhYlJKp.js} +728 -716
- package/dist/{xlsx-model-source-C-Riw89p.js → xlsx-model-source-zemVDAfl.js} +36 -36
- package/dist/xlsx.mjs +5 -5
- package/dist/xlsx_parser_bg.wasm +0 -0
- package/package.json +1 -1
- package/dist/assets/render-worker-B3hF7Akg.js +0 -35
- package/dist/assets/render-worker-B5HWxkbU.js +0 -16
- package/dist/assets/render-worker-DNGf06QT.js +0 -15
- package/dist/renderer-xdugdcMd.js +0 -5769
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import { t as e } from "./chunk-D5OxutzX.js";
|
|
2
|
-
import {
|
|
2
|
+
import { G as t, I as n, K as r, P as i, R as a, U as o } from "./bounded-raw-part-cache-B5a6cGKO.js";
|
|
3
3
|
import { n as s, t as c } from "./abort-JztSoyw2.js";
|
|
4
|
-
import { b as l, c as u, d, f, g as p, l as m, p as h, r as g, s as _, t as v, u as y, x as ee, y as b } from "./worksheet-pull-client-
|
|
4
|
+
import { b as l, c as u, d, f, g as p, l as m, p as h, r as g, s as _, t as v, u as y, x as ee, y as b } from "./worksheet-pull-client-BudfclVl.js";
|
|
5
5
|
import { n as x, r as S, t as te } from "./wasm-loader-KAOyLXzf.js";
|
|
6
|
-
import { t as ne } from "./wasm-runtime-generation-
|
|
6
|
+
import { t as ne } from "./wasm-runtime-generation-D97yoAXz.js";
|
|
7
7
|
import { t as re } from "./in-process-pull-transport-BPJ7M0uC.js";
|
|
8
|
-
function ie(e,
|
|
8
|
+
function ie(e, t) {
|
|
9
9
|
return {
|
|
10
10
|
workbook: e(),
|
|
11
|
-
usage: t(
|
|
11
|
+
usage: o(t())
|
|
12
12
|
};
|
|
13
13
|
}
|
|
14
14
|
var C = /* @__PURE__ */ e({
|
|
@@ -272,8 +272,8 @@ async function de(e) {
|
|
|
272
272
|
return V = void 0, O = null, j = null, W(e);
|
|
273
273
|
}
|
|
274
274
|
var G = "XLSX workbook session was aborted", fe = ne(C, "XLSX");
|
|
275
|
-
async function K(e, t,
|
|
276
|
-
let u = l(
|
|
275
|
+
async function K(e, t, o = {}) {
|
|
276
|
+
let u = l(o), d = n(o), f = new i({
|
|
277
277
|
enabled: d.debug || d.onResourceMetrics !== void 0,
|
|
278
278
|
format: "xlsx",
|
|
279
279
|
mode: "node",
|
|
@@ -286,13 +286,13 @@ async function K(e, t, r = {}) {
|
|
|
286
286
|
f.setSourceBytes(e.byteLength);
|
|
287
287
|
let p;
|
|
288
288
|
try {
|
|
289
|
-
s(
|
|
290
|
-
let [
|
|
291
|
-
p = await fe(t).open(() => new l(e,
|
|
292
|
-
signal:
|
|
289
|
+
s(o.signal, G);
|
|
290
|
+
let [n, r, i] = a(d.policy), l = w;
|
|
291
|
+
p = await fe(t).open(() => new l(e, n, r, i), {
|
|
292
|
+
signal: o.signal,
|
|
293
293
|
abortError: () => c(G),
|
|
294
294
|
disposeOnAbort: (e) => e.free()
|
|
295
|
-
}), s(
|
|
295
|
+
}), s(o.signal, G);
|
|
296
296
|
let m = p.proxy, [h, g, _, v] = ee(u);
|
|
297
297
|
m.set_worksheet_limits(h, g, _, v);
|
|
298
298
|
let { workbook: y, usage: b } = ie(() => JSON.parse(new TextDecoder().decode(m.parse())), () => m.resource_usage());
|
|
@@ -308,7 +308,7 @@ async function K(e, t, r = {}) {
|
|
|
308
308
|
try {
|
|
309
309
|
p?.close((e) => e.free());
|
|
310
310
|
} catch {}
|
|
311
|
-
let t =
|
|
311
|
+
let t = r(e) ?? e;
|
|
312
312
|
throw f.fail(t), t;
|
|
313
313
|
}
|
|
314
314
|
}
|
|
@@ -319,7 +319,7 @@ async function J(e, t = {}) {
|
|
|
319
319
|
...t,
|
|
320
320
|
xlsxWorksheetLimits: n.worksheet
|
|
321
321
|
}, t.legacyXls !== void 0) {
|
|
322
|
-
let { openXlsxSource: n } = await import("./xlsx-model-source-
|
|
322
|
+
let { openXlsxSource: n } = await import("./xlsx-model-source-zemVDAfl.js");
|
|
323
323
|
return n(e, t, q);
|
|
324
324
|
}
|
|
325
325
|
let r = await K(_e(e), q(), t);
|
|
@@ -370,42 +370,42 @@ var Z = class {
|
|
|
370
370
|
if (this.closed) throw Error("XLSX workbook session is closed");
|
|
371
371
|
if (this.active) throw Error("another XLSX worksheet row stream is already active");
|
|
372
372
|
if (!Number.isSafeInteger(e) || e < 0) throw RangeError("sheetIndex must be a non-negative safe integer");
|
|
373
|
-
let
|
|
374
|
-
this.active =
|
|
373
|
+
let n = this.requireSheetName(e), r = {};
|
|
374
|
+
this.active = r;
|
|
375
375
|
let i;
|
|
376
376
|
try {
|
|
377
|
-
for await (let
|
|
377
|
+
for await (let t of this.worksheetPullClient.stream(e, n, this.signal)) {
|
|
378
378
|
if (this.closed) throw Error("XLSX workbook session is closed");
|
|
379
|
-
if (
|
|
380
|
-
if (
|
|
381
|
-
this.rowBatches += 1, this.emittedRows +=
|
|
379
|
+
if (t.kind !== "preview") {
|
|
380
|
+
if (t.kind === "rows") {
|
|
381
|
+
this.rowBatches += 1, this.emittedRows += t.rows.length, yield {
|
|
382
382
|
kind: "rows",
|
|
383
|
-
rows:
|
|
384
|
-
sequence:
|
|
385
|
-
wireBytes:
|
|
386
|
-
usage:
|
|
383
|
+
rows: t.rows,
|
|
384
|
+
sequence: t.sequence,
|
|
385
|
+
wireBytes: t.wireBytes,
|
|
386
|
+
usage: t.usage
|
|
387
387
|
};
|
|
388
388
|
continue;
|
|
389
389
|
}
|
|
390
|
-
p(
|
|
390
|
+
p(t.worksheet, X(this)), yield {
|
|
391
391
|
kind: "finished",
|
|
392
|
-
worksheet:
|
|
393
|
-
sequence:
|
|
394
|
-
wireBytes:
|
|
395
|
-
usage:
|
|
392
|
+
worksheet: t.worksheet,
|
|
393
|
+
sequence: t.sequence,
|
|
394
|
+
wireBytes: t.wireBytes,
|
|
395
|
+
usage: t.usage
|
|
396
396
|
};
|
|
397
397
|
}
|
|
398
398
|
}
|
|
399
399
|
this.completedWorksheets += 1, this.metrics.checkpoint("worksheet stream complete", this.lastUsage);
|
|
400
400
|
} catch (e) {
|
|
401
|
-
throw i =
|
|
401
|
+
throw i = t(e) ?? e, this.metrics.fail(i), await this.close().catch(() => void 0), i;
|
|
402
402
|
} finally {
|
|
403
403
|
try {
|
|
404
|
-
await this.cleanupOperation(
|
|
404
|
+
await this.cleanupOperation(r, i === void 0 ? "closed" : "request-error");
|
|
405
405
|
} catch (e) {
|
|
406
406
|
if (i === void 0) {
|
|
407
|
-
let
|
|
408
|
-
throw this.metrics.fail(
|
|
407
|
+
let n = t(e) ?? e;
|
|
408
|
+
throw this.metrics.fail(n), await this.close().catch(() => void 0), n;
|
|
409
409
|
}
|
|
410
410
|
}
|
|
411
411
|
}
|
|
@@ -413,34 +413,34 @@ var Z = class {
|
|
|
413
413
|
close() {
|
|
414
414
|
return this.closePromise ? this.closePromise : (this.closed = !0, this.closePromise = this.release(), this.closePromise);
|
|
415
415
|
}
|
|
416
|
-
cleanupOperation(e,
|
|
416
|
+
cleanupOperation(e, n) {
|
|
417
417
|
return e.cleanupPromise ||= (async () => {
|
|
418
|
-
let
|
|
418
|
+
let r;
|
|
419
419
|
try {
|
|
420
|
-
await this.worksheetPullClient.cancelAll(
|
|
420
|
+
await this.worksheetPullClient.cancelAll(n);
|
|
421
421
|
} catch (e) {
|
|
422
|
-
|
|
422
|
+
r = t(e) ?? e;
|
|
423
423
|
}
|
|
424
424
|
try {
|
|
425
425
|
await this.pull.reset();
|
|
426
426
|
} catch (e) {
|
|
427
|
-
|
|
427
|
+
r ??= t(e) ?? e;
|
|
428
428
|
}
|
|
429
|
-
if (this.active === e && (this.active = void 0),
|
|
429
|
+
if (this.active === e && (this.active = void 0), r !== void 0) throw r;
|
|
430
430
|
})(), e.cleanupPromise;
|
|
431
431
|
}
|
|
432
432
|
async release() {
|
|
433
433
|
let e;
|
|
434
434
|
if (this.active) try {
|
|
435
435
|
await this.cleanupOperation(this.active, "closed");
|
|
436
|
-
} catch (
|
|
437
|
-
e =
|
|
436
|
+
} catch (n) {
|
|
437
|
+
e = t(n) ?? n;
|
|
438
438
|
}
|
|
439
439
|
this.transport.terminate();
|
|
440
440
|
try {
|
|
441
441
|
this.closeArchive();
|
|
442
|
-
} catch (
|
|
443
|
-
e ??=
|
|
442
|
+
} catch (n) {
|
|
443
|
+
e ??= t(n) ?? n;
|
|
444
444
|
}
|
|
445
445
|
if (e !== void 0) throw this.metrics.fail(e), e;
|
|
446
446
|
this.metrics.checkpoint("workbook session closed", this.lastUsage), this.metrics.succeed({
|
|
@@ -514,7 +514,7 @@ function $(e, t = /* @__PURE__ */ new WeakSet()) {
|
|
|
514
514
|
}
|
|
515
515
|
function ge(e) {
|
|
516
516
|
try {
|
|
517
|
-
return
|
|
517
|
+
return o(e);
|
|
518
518
|
} catch (e) {
|
|
519
519
|
if (String(e).includes("worksheet cursor usage is unavailable")) return;
|
|
520
520
|
throw e;
|