@vue-pdf-viewer/annotation 1.3.0-alpha.0 → 1.3.0-alpha.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +433 -408
- package/dist/index.umd.cjs +5 -5
- package/package.json +4 -4
package/dist/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
(function(){"use strict";try{if(typeof document<"u"){var e=document.createElement("style");e.appendChild(document.createTextNode('.vp-text-xl[data-v-
|
|
2
|
-
import { defineComponent as Ue, inject as In, computed as fe, openBlock as ee, createBlock as ae, resolveDynamicComponent as Se, normalizeProps as xt, mergeProps as ve, createSlots as dn, withCtx as Q, renderSlot as pe, renderList as Oc, createElementBlock as xn, defineAsyncComponent as Fc, unref as Be, ref as di, createTextVNode as On, toDisplayString as Fn, createVNode as Ae, normalizeClass as zc,
|
|
1
|
+
(function(){"use strict";try{if(typeof document<"u"){var e=document.createElement("style");e.appendChild(document.createTextNode('.vp-text-xl[data-v-9d5f0033]{font-size:1.25rem;line-height:1.75rem}.vpv-toolbar-btn.vpv-toolbar-btn-active[data-v-df5778ee],.vpv-toolbar-btn[data-v-df5778ee]:hover{background-color:var(--vpv-primary-color);color:#fff}.vpv-annotation-editor-layer{position:absolute;top:0;left:0;width:100%;height:100%;pointer-events:none}.vpv-annotation-editor-layer *{pointer-events:auto}.vpv-annotation-editor-layer .vpv-annotation-editor{z-index:calc(var(--vpv-base-z-index) * 4)}.vpv-annotation-editor-layer.highlight-mode,.vpv-annotation-editor-layer.underline-mode,.vpv-annotation-editor-layer.strikeout-mode{cursor:text}.vpv-annotation-editor-layer.highlight-mode .vpv-annotation-editor,.vpv-annotation-editor-layer.underline-mode .vpv-annotation-editor,.vpv-annotation-editor-layer.strikeout-mode .vpv-annotation-editor{pointer-events:none}.vpv-annotation-editor-layer.highlight-mode .vpv-annotation-editor .vpv-annotation-editor__clip-path,.vpv-annotation-editor-layer.underline-mode .vpv-annotation-editor .vpv-annotation-editor__clip-path,.vpv-annotation-editor-layer.strikeout-mode .vpv-annotation-editor .vpv-annotation-editor__clip-path{cursor:pointer;position:absolute;inset:0;pointer-events:auto;z-index:calc(var(--vpv-base-z-index) * 5)}.vpv-annotation-editor-layer:not(.highlight-mode,.underline-mode,.strikeout-mode) .vpv-annotation-editor.vpv-annotation-editor__highlight{pointer-events:none}.vpv-annotation-editor-layer:not(.highlight-mode,.underline-mode,.strikeout-mode) .vpv-annotation-editor.vpv-annotation-editor__highlight .vpv-annotation-editor__clip-path{pointer-events:none}.vpv-annotation-editor-layer.freetext-mode>:not(.vpv-annotation-editor__free-text){user-select:none;pointer-events:none}.vpv-annotation-editor-layer:not(.freetext-mode) .vpv-annotation-editor__free-text{pointer-events:none}.vpv-annotation-highlight__color-picker-wrapper{padding-left:4px;padding-right:4px;padding-bottom:4px;text-align:left}.vpv-annotation-highlight__color-picker-wrapper>p{margin-bottom:.75rem}.vpv-canvas-layer>.vpv-highlight:is(svg),.vpv-canvas-layer>.vpv-underline:is(svg),.vpv-canvas-layer>.vpv-underline-interaction:is(svg),.vpv-canvas-layer>.vpv-strikeout:is(svg),.vpv-canvas-layer>.vpv-strikeout-interaction:is(svg){position:absolute;mix-blend-mode:multiply}.vpv-canvas-layer>.vpv-highlight:is(svg)>use,.vpv-canvas-layer>.vpv-underline:is(svg)>use,.vpv-canvas-layer>.vpv-underline-interaction:is(svg)>use,.vpv-canvas-layer>.vpv-strikeout:is(svg)>use,.vpv-canvas-layer>.vpv-strikeout-interaction:is(svg)>use{fill:inherit}.vpv-canvas-layer>.vpv-highlight:is(svg):not(.free),.vpv-canvas-layer>.vpv-underline:is(svg):not(.free),.vpv-canvas-layer>.vpv-underline-interaction:is(svg):not(.free),.vpv-canvas-layer>.vpv-strikeout:is(svg):not(.free),.vpv-canvas-layer>.vpv-strikeout-interaction:is(svg):not(.free){fill-rule:evenodd}.vpv-canvas-layer>.vpv-highlight:is(svg):not(.free) path,.vpv-canvas-layer>.vpv-highlight:is(svg):not(.free) use,.vpv-canvas-layer>.vpv-underline:is(svg):not(.free) path,.vpv-canvas-layer>.vpv-underline:is(svg):not(.free) use,.vpv-canvas-layer>.vpv-underline-interaction:is(svg):not(.free) path,.vpv-canvas-layer>.vpv-underline-interaction:is(svg):not(.free) use,.vpv-canvas-layer>.vpv-strikeout:is(svg):not(.free) path,.vpv-canvas-layer>.vpv-strikeout:is(svg):not(.free) use,.vpv-canvas-layer>.vpv-strikeout-interaction:is(svg):not(.free) path,.vpv-canvas-layer>.vpv-strikeout-interaction:is(svg):not(.free) use{fill-rule:evenodd}.vpv-canvas-layer>.vpv-highlight-outline:is(svg),.vpv-canvas-layer>.vpv-underline-outline:is(svg),.vpv-canvas-layer>.vpv-strikeout-outline:is(svg){position:absolute;mix-blend-mode:normal;fill-rule:evenodd;fill:none}.vpv-canvas-layer>.vpv-highlight-outline:is(svg) path,.vpv-canvas-layer>.vpv-highlight-outline:is(svg) use,.vpv-canvas-layer>.vpv-underline-outline:is(svg) path,.vpv-canvas-layer>.vpv-underline-outline:is(svg) use,.vpv-canvas-layer>.vpv-strikeout-outline:is(svg) path,.vpv-canvas-layer>.vpv-strikeout-outline:is(svg) use{fill-rule:evenodd}.vpv-canvas-layer>.vpv-highlight-outline:is(svg).hovered,.vpv-canvas-layer>.vpv-highlight-outline:is(svg).selected,.vpv-canvas-layer>.vpv-underline-outline:is(svg).hovered,.vpv-canvas-layer>.vpv-underline-outline:is(svg).selected,.vpv-canvas-layer>.vpv-strikeout-outline:is(svg).hovered,.vpv-canvas-layer>.vpv-strikeout-outline:is(svg).selected{stroke-width:var(--vpv-annotation-highlight__outline-width)}.vpv-canvas-layer>.vpv-highlight-outline:is(svg).hovered,.vpv-canvas-layer>.vpv-underline-outline:is(svg).hovered,.vpv-canvas-layer>.vpv-strikeout-outline:is(svg).hovered{stroke:var(--vpv-annotation-highlight__outline-hover-color)}.vpv-canvas-layer>.vpv-highlight-outline:is(svg).selected,.vpv-canvas-layer>.vpv-underline-outline:is(svg).selected,.vpv-canvas-layer>.vpv-strikeout-outline:is(svg).selected{stroke:var(--vpv-annotation-highlight__outline-selected-color)}.vpv-annotation-editor-layer .vpv-annotation-editor__free-text{position:absolute;user-select:none;padding:calc(var(--vpv-annotation-free-text__padding, 2px) * var(--scale-factor));cursor:auto}.vpv-annotation-editor-layer .vpv-annotation-editor__free-text.draggable{cursor:move}.vpv-annotation-editor-layer .vpv-annotation-editor__free-text--selected,.vpv-annotation-editor-layer .vpv-annotation-editor__free-text:hover{outline:1px solid #0082ff}.vpv-annotation-editor-layer .vpv-annotation-editor__free-text [role=textbox]{outline:none!important;text-align:start;font:10px sans-serif;line-height:var(--vpv-annotation-free-text__line-height);width:auto;height:auto;white-space:pre-wrap;word-wrap:break-word}.vpv-annotation-editor-layer .vpv-annotation-editor__free-text--temp{min-width:100px;min-height:calc(20px * var(--scale-factor));border:1px dashed #007bff;background-color:#ffffffe6;color:#000;cursor:text}.vpv-annotation-editor-layer .vpv-annotation-editor__free-text--temp>[role=textbox]{outline:none;font-size:calc(16px * var(--scale-factor));font-family:sans-serif;min-height:calc(16px * var(--scale-factor));white-space:nowrap}.vpv-resizers{position:absolute;inset:0;pointer-events:none}.vpv-resizers .vpv-resizer{position:absolute;width:var(--vpv-annotation-outline-resizer-size);height:var(--vpv-annotation-outline-resizer-size);background:white;border:1px solid var(--vpv-annotation-outline-resizer-border-color);border-radius:50%;pointer-events:auto;cursor:pointer;z-index:calc(var(--vpv-base-z-index) * 9999);transition:opacity .2s ease,visibility .2s ease}.vpv-resizers .vpv-resizer:hover,.vpv-resizers .vpv-resizer:focus{transform:scale(1.5)}.vpv-resizers .vpv-resizer--top-left{top:calc(var(--vpv-annotation-outline-resizer-size) * -1.25);left:calc(var(--vpv-annotation-outline-resizer-size) * -1.25);cursor:nwse-resize}.vpv-resizers .vpv-resizer--top-right{top:calc(var(--vpv-annotation-outline-resizer-size) * -1.25);right:calc(var(--vpv-annotation-outline-resizer-size) * -1.25);cursor:nesw-resize}.vpv-resizers .vpv-resizer--bottom-left{bottom:calc(var(--vpv-annotation-outline-resizer-size) * -1.25);left:calc(var(--vpv-annotation-outline-resizer-size) * -1.25);cursor:nesw-resize}.vpv-resizers .vpv-resizer--bottom-right{bottom:calc(var(--vpv-annotation-outline-resizer-size) * -1.25);right:calc(var(--vpv-annotation-outline-resizer-size) * -1.25);cursor:nwse-resize}.vpv-page[data-main-rotation="90"] .vpv-resizer--top-left,.vpv-page[data-main-rotation="270"] .vpv-resizer--top-left{cursor:nesw-resize}.vpv-page[data-main-rotation="90"] .vpv-resizer--top-right,.vpv-page[data-main-rotation="270"] .vpv-resizer--top-right,.vpv-page[data-main-rotation="90"] .vpv-resizer--bottom-left,.vpv-page[data-main-rotation="270"] .vpv-resizer--bottom-left{cursor:nwse-resize}.vpv-page[data-main-rotation="90"] .vpv-resizer--bottom-right,.vpv-page[data-main-rotation="270"] .vpv-resizer--bottom-right{cursor:nesw-resize}.vpv-resizer--dark{background:#80ebff;border-color:#2b2a33}.vpv-resizer--dark:focus{outline-color:#80ebff}.vpv-annotation-editor__image{position:absolute;cursor:pointer;touch-action:none;user-select:none;will-change:transform}.vpv-annotation-editor__image.hovered,.vpv-annotation-editor__image:hover{outline-width:var(--vpv-annotation-outline-width);outline-style:solid;outline-color:var(--vpv-annotation-outline-hovered-color)}.vpv-annotation-editor__image.selected{outline-width:var(--vpv-annotation-outline-width);outline-style:solid;outline-offset:var(--vpv-annotation-outline-selected-offset);outline-color:var(--vpv-annotation-outline-selected-color);cursor:move}.vpv-annotation-editor__image canvas{position:absolute;width:100%;height:100%;margin:0;top:0;left:0}.vpv-annotation-editor__image.dragging canvas{user-drag:none;-webkit-user-drag:none;pointer-events:none;touch-action:none}.vpv-page:not([data-main-rotation="0"]) .vpv-annotation-editor__image:hover{outline:none}.vpv-annotation-tools-container[data-v-8583d7e5]{padding-top:.5rem;padding-bottom:.5rem;border-top:1px solid #c6ccd2;max-width:min-content;margin:.5rem auto}.vpv-annotation-tools-container[data-v-8583d7e5] .vpv-toolbar-btn{margin-bottom:.25rem}.slide-enter-active[data-v-8583d7e5],.slide-leave-active[data-v-8583d7e5]{transition:all .3s ease-out}.slide-enter-from[data-v-8583d7e5],.slide-leave-to[data-v-8583d7e5]{opacity:0}.slide-enter-from[data-v-8583d7e5],.slide-leave-to[data-v-8583d7e5]{transform:translateY(-20px)}')),document.head.appendChild(e)}}catch(t){console.error("vite-plugin-css-injected-by-js",t)}})();
|
|
2
|
+
import { defineComponent as Ue, inject as In, computed as fe, openBlock as ee, createBlock as ae, resolveDynamicComponent as Se, normalizeProps as xt, mergeProps as ve, createSlots as dn, withCtx as Q, renderSlot as pe, renderList as Oc, createElementBlock as xn, defineAsyncComponent as Fc, unref as Be, ref as di, createTextVNode as On, toDisplayString as Fn, createVNode as Ae, normalizeClass as zc, mergeModels as xr, useModel as Sr, createCommentVNode as _e, reactive as Nc, onMounted as Lc, watch as Xn, onUnmounted as jc, Transition as Mc, markRaw as Bt, h as oi } from "vue";
|
|
3
3
|
var Uc = Object.defineProperty, $c = (e, t, n) => t in e ? Uc(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n, b = (e, t, n) => ($c(e, typeof t != "symbol" ? t + "" : t, n), n);
|
|
4
4
|
const Nt = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/", un = new Uint8Array(256);
|
|
5
5
|
for (let e = 0; e < Nt.length; e++)
|
|
@@ -64,7 +64,7 @@ const Hc = (e) => {
|
|
|
64
64
|
r = s, i += ((n = s.index) != null ? n : 0) + s[0].length;
|
|
65
65
|
}
|
|
66
66
|
return { match: r, pos: i };
|
|
67
|
-
}, ui = (e) => e[e.length - 1],
|
|
67
|
+
}, ui = (e) => e[e.length - 1], sr = (e) => {
|
|
68
68
|
if (e instanceof Uint8Array)
|
|
69
69
|
return e;
|
|
70
70
|
const t = e.length, n = new Uint8Array(t);
|
|
@@ -75,7 +75,7 @@ const Hc = (e) => {
|
|
|
75
75
|
const t = e.length, n = [];
|
|
76
76
|
for (let o = 0; o < t; o++) {
|
|
77
77
|
const c = e[o];
|
|
78
|
-
n[o] = c instanceof Uint8Array ? c :
|
|
78
|
+
n[o] = c instanceof Uint8Array ? c : sr(c);
|
|
79
79
|
}
|
|
80
80
|
let i = 0;
|
|
81
81
|
for (let o = 0; o < t; o++)
|
|
@@ -138,7 +138,7 @@ const Hc = (e) => {
|
|
|
138
138
|
};
|
|
139
139
|
let Mt = Ko;
|
|
140
140
|
b(Mt, "populatedBy", (e) => new Ko(e));
|
|
141
|
-
const
|
|
141
|
+
const vi = (e) => {
|
|
142
142
|
throw new Error(e);
|
|
143
143
|
}, Qc = (e) => {
|
|
144
144
|
let t = String(e);
|
|
@@ -275,23 +275,23 @@ const Zo = (e) => {
|
|
|
275
275
|
}
|
|
276
276
|
const r = i.join(" or ");
|
|
277
277
|
return `${de(t)} must be of type ${r}, but was actually of type ${de(al(e))}`;
|
|
278
|
-
},
|
|
278
|
+
}, D = (e, t, n) => {
|
|
279
279
|
for (let i = 0, r = n.length; i < r; i++)
|
|
280
280
|
if (cl(e, n[i]))
|
|
281
281
|
return;
|
|
282
282
|
throw new TypeError(ll(e, t, n));
|
|
283
283
|
}, j = (e, t, n) => {
|
|
284
|
-
|
|
284
|
+
D(e, t, n.concat("undefined"));
|
|
285
285
|
}, Qo = (e, t, n) => {
|
|
286
286
|
for (let i = 0, r = e.length; i < r; i++)
|
|
287
|
-
|
|
287
|
+
D(e[i], t, n);
|
|
288
288
|
}, ht = (e, t, n, i) => {
|
|
289
|
-
if (
|
|
289
|
+
if (D(e, t, ["number"]), D(n, "min", ["number"]), D(i, "max", ["number"]), i = Math.max(n, i), e < n || e > i)
|
|
290
290
|
throw new Error(`${de(t)} must be at least ${n} and at most ${i}, but was actually ${e}`);
|
|
291
291
|
}, Qe = (e, t, n, i) => {
|
|
292
|
-
|
|
292
|
+
D(e, t, ["number", "undefined"]), typeof e == "number" && ht(e, t, n, i);
|
|
293
293
|
}, hl = (e, t, n) => {
|
|
294
|
-
if (
|
|
294
|
+
if (D(e, t, ["number"]), e % n !== 0)
|
|
295
295
|
throw new Error(`${de(t)} must be a multiple of ${n}, but was actually ${e}`);
|
|
296
296
|
}, dl = (e, t) => {
|
|
297
297
|
if (!Number.isInteger(e))
|
|
@@ -311,7 +311,7 @@ class kr extends Error {
|
|
|
311
311
|
super(n);
|
|
312
312
|
}
|
|
313
313
|
}
|
|
314
|
-
class
|
|
314
|
+
class or extends Error {
|
|
315
315
|
constructor(t, n) {
|
|
316
316
|
const i = (o) => {
|
|
317
317
|
var c, l;
|
|
@@ -473,7 +473,7 @@ class we {
|
|
|
473
473
|
throw new qe(this.constructor.name, "copyBytesInto");
|
|
474
474
|
}
|
|
475
475
|
}
|
|
476
|
-
const
|
|
476
|
+
const Dr = class extends we {
|
|
477
477
|
constructor(e) {
|
|
478
478
|
super(), b(this, "numberValue"), b(this, "stringValue"), this.numberValue = e, this.stringValue = Qc(e);
|
|
479
479
|
}
|
|
@@ -484,7 +484,7 @@ const Tr = class extends we {
|
|
|
484
484
|
return this.numberValue;
|
|
485
485
|
}
|
|
486
486
|
clone() {
|
|
487
|
-
return
|
|
487
|
+
return Dr.of(this.numberValue);
|
|
488
488
|
}
|
|
489
489
|
toString() {
|
|
490
490
|
return this.stringValue;
|
|
@@ -496,10 +496,10 @@ const Tr = class extends we {
|
|
|
496
496
|
return t += be(this.stringValue, e, t), this.stringValue.length;
|
|
497
497
|
}
|
|
498
498
|
};
|
|
499
|
-
let M =
|
|
500
|
-
b(M, "of", (e) => new
|
|
499
|
+
let M = Dr;
|
|
500
|
+
b(M, "of", (e) => new Dr(e));
|
|
501
501
|
var g = /* @__PURE__ */ ((e) => (e[e.Null = 0] = "Null", e[e.Backspace = 8] = "Backspace", e[e.Tab = 9] = "Tab", e[e.Newline = 10] = "Newline", e[e.FormFeed = 12] = "FormFeed", e[e.CarriageReturn = 13] = "CarriageReturn", e[e.Space = 32] = "Space", e[e.ExclamationPoint = 33] = "ExclamationPoint", e[e.Hash = 35] = "Hash", e[e.Percent = 37] = "Percent", e[e.LeftParen = 40] = "LeftParen", e[e.RightParen = 41] = "RightParen", e[e.Plus = 43] = "Plus", e[e.Minus = 45] = "Minus", e[e.Dash = 45] = "Dash", e[e.Period = 46] = "Period", e[e.ForwardSlash = 47] = "ForwardSlash", e[e.Zero = 48] = "Zero", e[e.One = 49] = "One", e[e.Two = 50] = "Two", e[e.Three = 51] = "Three", e[e.Four = 52] = "Four", e[e.Five = 53] = "Five", e[e.Six = 54] = "Six", e[e.Seven = 55] = "Seven", e[e.Eight = 56] = "Eight", e[e.Nine = 57] = "Nine", e[e.LessThan = 60] = "LessThan", e[e.GreaterThan = 62] = "GreaterThan", e[e.A = 65] = "A", e[e.D = 68] = "D", e[e.E = 69] = "E", e[e.F = 70] = "F", e[e.O = 79] = "O", e[e.P = 80] = "P", e[e.R = 82] = "R", e[e.LeftSquareBracket = 91] = "LeftSquareBracket", e[e.BackSlash = 92] = "BackSlash", e[e.RightSquareBracket = 93] = "RightSquareBracket", e[e.a = 97] = "a", e[e.b = 98] = "b", e[e.d = 100] = "d", e[e.e = 101] = "e", e[e.f = 102] = "f", e[e.i = 105] = "i", e[e.j = 106] = "j", e[e.l = 108] = "l", e[e.m = 109] = "m", e[e.n = 110] = "n", e[e.o = 111] = "o", e[e.r = 114] = "r", e[e.s = 115] = "s", e[e.t = 116] = "t", e[e.u = 117] = "u", e[e.x = 120] = "x", e[e.LeftCurly = 123] = "LeftCurly", e[e.RightCurly = 125] = "RightCurly", e[e.Tilde = 126] = "Tilde", e))(g || {});
|
|
502
|
-
const
|
|
502
|
+
const Tr = class extends we {
|
|
503
503
|
constructor(e) {
|
|
504
504
|
super(), b(this, "array"), b(this, "context"), this.array = [], this.context = e;
|
|
505
505
|
}
|
|
@@ -547,7 +547,7 @@ const Dr = class extends we {
|
|
|
547
547
|
return this.array.slice();
|
|
548
548
|
}
|
|
549
549
|
clone(e) {
|
|
550
|
-
const t =
|
|
550
|
+
const t = Tr.withContext(e || this.context);
|
|
551
551
|
for (let n = 0, i = this.size(); n < i; n++)
|
|
552
552
|
t.push(this.array[n]);
|
|
553
553
|
return t;
|
|
@@ -581,8 +581,8 @@ const Dr = class extends we {
|
|
|
581
581
|
}
|
|
582
582
|
}
|
|
583
583
|
};
|
|
584
|
-
let Y =
|
|
585
|
-
b(Y, "withContext", (e) => new
|
|
584
|
+
let Y = Tr;
|
|
585
|
+
b(Y, "withContext", (e) => new Tr(e));
|
|
586
586
|
const Le = new Uint8Array(256);
|
|
587
587
|
Le[g.LeftParen] = 1;
|
|
588
588
|
Le[g.RightParen] = 1;
|
|
@@ -605,7 +605,7 @@ const Er = new Uint8Array(256);
|
|
|
605
605
|
for (let e = 0, t = 256; e < t; e++)
|
|
606
606
|
Er[e] = ot[e] || Le[e] ? 1 : 0;
|
|
607
607
|
Er[g.Hash] = 1;
|
|
608
|
-
const
|
|
608
|
+
const Dl = (e) => e.replace(/#([\dABCDEF]{2})/g, (t, n) => Kc(n)), Tl = (e) => e >= g.ExclamationPoint && e <= g.Tilde && !Er[e], ta = {}, js = /* @__PURE__ */ new Map(), ne = class extends we {
|
|
609
609
|
constructor(e, t) {
|
|
610
610
|
if (e !== ta)
|
|
611
611
|
throw new kr("PDFName");
|
|
@@ -613,7 +613,7 @@ const Tl = (e) => e.replace(/#([\dABCDEF]{2})/g, (t, n) => Kc(n)), Dl = (e) => e
|
|
|
613
613
|
let n = "/";
|
|
614
614
|
for (let i = 0, r = t.length; i < r; i++) {
|
|
615
615
|
const s = t[i], o = U(s);
|
|
616
|
-
n +=
|
|
616
|
+
n += Tl(o) ? s : `#${Ho(o)}`;
|
|
617
617
|
}
|
|
618
618
|
this.encodedName = n;
|
|
619
619
|
}
|
|
@@ -654,7 +654,7 @@ const Tl = (e) => e.replace(/#([\dABCDEF]{2})/g, (t, n) => Kc(n)), Dl = (e) => e
|
|
|
654
654
|
};
|
|
655
655
|
let p = ne;
|
|
656
656
|
b(p, "of", (e) => {
|
|
657
|
-
const t =
|
|
657
|
+
const t = Dl(e);
|
|
658
658
|
let n = js.get(t);
|
|
659
659
|
return n || (n = new ne(ta, t), js.set(t, n)), n;
|
|
660
660
|
});
|
|
@@ -683,7 +683,7 @@ b(p, "Keywords", ne.of("Keywords"));
|
|
|
683
683
|
b(p, "Producer", ne.of("Producer"));
|
|
684
684
|
b(p, "CreationDate", ne.of("CreationDate"));
|
|
685
685
|
b(p, "ModDate", ne.of("ModDate"));
|
|
686
|
-
const
|
|
686
|
+
const xi = class extends we {
|
|
687
687
|
constructor(e) {
|
|
688
688
|
super(), b(this, "value"), this.value = e;
|
|
689
689
|
}
|
|
@@ -710,7 +710,7 @@ const Si = class extends we {
|
|
|
710
710
|
return this.value;
|
|
711
711
|
}
|
|
712
712
|
clone() {
|
|
713
|
-
return
|
|
713
|
+
return xi.of(this.value);
|
|
714
714
|
}
|
|
715
715
|
toString() {
|
|
716
716
|
return `<${this.value}>`;
|
|
@@ -722,14 +722,14 @@ const Si = class extends we {
|
|
|
722
722
|
return e[t++] = g.LessThan, t += be(this.value, e, t), e[t++] = g.GreaterThan, this.value.length + 2;
|
|
723
723
|
}
|
|
724
724
|
};
|
|
725
|
-
let X =
|
|
726
|
-
b(X, "of", (e) => new
|
|
725
|
+
let X = xi;
|
|
726
|
+
b(X, "of", (e) => new xi(e));
|
|
727
727
|
b(X, "fromText", (e) => {
|
|
728
728
|
const t = el(e);
|
|
729
729
|
let n = "";
|
|
730
730
|
for (let i = 0, r = t.length; i < r; i++)
|
|
731
731
|
n += $o(t[i], 4);
|
|
732
|
-
return new
|
|
732
|
+
return new xi(n);
|
|
733
733
|
});
|
|
734
734
|
/*! pako 2.1.0 https://github.com/nodeca/pako @license (MIT AND Zlib) */
|
|
735
735
|
const El = 4, Ms = 0, Us = 1, Bl = 2;
|
|
@@ -738,7 +738,7 @@ function Xt(e) {
|
|
|
738
738
|
for (; --t >= 0; )
|
|
739
739
|
e[t] = 0;
|
|
740
740
|
}
|
|
741
|
-
const Pl = 0, na = 1, Rl = 2, Il = 3, Ol = 258, Br = 29, zn = 256, Sn = zn + 1 + Br, Ut = 30, Pr = 19, ia = 2 * Sn + 1, yt = 15,
|
|
741
|
+
const Pl = 0, na = 1, Rl = 2, Il = 3, Ol = 258, Br = 29, zn = 256, Sn = zn + 1 + Br, Ut = 30, Pr = 19, ia = 2 * Sn + 1, yt = 15, Wi = 16, Fl = 7, Rr = 256, ra = 16, sa = 17, oa = 18, ar = new Uint8Array([0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 2, 2, 2, 2, 3, 3, 3, 3, 4, 4, 4, 4, 5, 5, 5, 5, 0]), ci = new Uint8Array([0, 0, 0, 0, 1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 6, 6, 7, 7, 8, 8, 9, 9, 10, 10, 11, 11, 12, 12, 13, 13]), zl = new Uint8Array([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 3, 7]), aa = new Uint8Array([16, 17, 18, 0, 8, 7, 9, 6, 10, 5, 11, 4, 12, 3, 13, 2, 14, 1, 15]), Nl = 512, tt = new Array((Sn + 2) * 2);
|
|
742
742
|
Xt(tt);
|
|
743
743
|
const yn = new Array(Ut * 2);
|
|
744
744
|
Xt(yn);
|
|
@@ -750,17 +750,17 @@ const Ir = new Array(Br);
|
|
|
750
750
|
Xt(Ir);
|
|
751
751
|
const gi = new Array(Ut);
|
|
752
752
|
Xt(gi);
|
|
753
|
-
function
|
|
753
|
+
function Ki(e, t, n, i, r) {
|
|
754
754
|
this.static_tree = e, this.extra_bits = t, this.extra_base = n, this.elems = i, this.max_length = r, this.has_stree = e && e.length;
|
|
755
755
|
}
|
|
756
756
|
let ca, la, ha;
|
|
757
|
-
function
|
|
757
|
+
function Zi(e, t) {
|
|
758
758
|
this.dyn_tree = e, this.max_code = 0, this.stat_desc = t;
|
|
759
759
|
}
|
|
760
760
|
const da = (e) => e < 256 ? kn[e] : kn[256 + (e >>> 7)], Cn = (e, t) => {
|
|
761
761
|
e.pending_buf[e.pending++] = t & 255, e.pending_buf[e.pending++] = t >>> 8 & 255;
|
|
762
762
|
}, Ce = (e, t, n) => {
|
|
763
|
-
e.bi_valid >
|
|
763
|
+
e.bi_valid > Wi - n ? (e.bi_buf |= t << e.bi_valid & 65535, Cn(e, e.bi_buf), e.bi_buf = t >> Wi - e.bi_valid, e.bi_valid += n - Wi) : (e.bi_buf |= t << e.bi_valid & 65535, e.bi_valid += n);
|
|
764
764
|
}, Ve = (e, t, n) => {
|
|
765
765
|
Ce(e, n[t * 2], n[t * 2 + 1]);
|
|
766
766
|
}, ua = (e, t) => {
|
|
@@ -801,7 +801,7 @@ const da = (e) => e < 256 ? kn[e] : kn[256 + (e >>> 7)], Cn = (e, t) => {
|
|
|
801
801
|
let e, t, n, i, r;
|
|
802
802
|
const s = new Array(yt + 1);
|
|
803
803
|
for (n = 0, i = 0; i < Br - 1; i++)
|
|
804
|
-
for (Ir[i] = n, e = 0; e < 1 <<
|
|
804
|
+
for (Ir[i] = n, e = 0; e < 1 << ar[i]; e++)
|
|
805
805
|
An[n++] = i;
|
|
806
806
|
for (An[n - 1] = i, r = 0, i = 0; i < 16; i++)
|
|
807
807
|
for (gi[i] = r, e = 0; e < 1 << ci[i]; e++)
|
|
@@ -821,7 +821,7 @@ const da = (e) => e < 256 ? kn[e] : kn[256 + (e >>> 7)], Cn = (e, t) => {
|
|
|
821
821
|
tt[e * 2 + 1] = 8, e++, s[8]++;
|
|
822
822
|
for (fa(tt, Sn + 1, s), e = 0; e < Ut; e++)
|
|
823
823
|
yn[e * 2 + 1] = 5, yn[e * 2] = ua(e, 5);
|
|
824
|
-
ca = new
|
|
824
|
+
ca = new Ki(tt, ar, zn + 1, Sn, yt), la = new Ki(yn, ci, 0, Ut, yt), ha = new Ki(new Array(0), zl, 0, Pr, Fl);
|
|
825
825
|
}, ga = (e) => {
|
|
826
826
|
let t;
|
|
827
827
|
for (t = 0; t < Sn; t++)
|
|
@@ -836,7 +836,7 @@ const da = (e) => e < 256 ? kn[e] : kn[256 + (e >>> 7)], Cn = (e, t) => {
|
|
|
836
836
|
}, $s = (e, t, n, i) => {
|
|
837
837
|
const r = t * 2, s = n * 2;
|
|
838
838
|
return e[r] < e[s] || e[r] === e[s] && i[t] <= i[n];
|
|
839
|
-
},
|
|
839
|
+
}, Vi = (e, t, n) => {
|
|
840
840
|
const i = e.heap[n];
|
|
841
841
|
let r = n << 1;
|
|
842
842
|
for (; r <= e.heap_len && (r < e.heap_len && $s(t, e.heap[r + 1], e.heap[r], e.depth) && r++, !$s(t, i, e.heap[r], e.depth)); )
|
|
@@ -846,10 +846,10 @@ const da = (e) => e < 256 ? kn[e] : kn[256 + (e >>> 7)], Cn = (e, t) => {
|
|
|
846
846
|
let i, r, s = 0, o, c;
|
|
847
847
|
if (e.sym_next !== 0)
|
|
848
848
|
do
|
|
849
|
-
i = e.pending_buf[e.sym_buf + s++] & 255, i += (e.pending_buf[e.sym_buf + s++] & 255) << 8, r = e.pending_buf[e.sym_buf + s++], i === 0 ? Ve(e, r, t) : (o = An[r], Ve(e, o + zn + 1, t), c =
|
|
849
|
+
i = e.pending_buf[e.sym_buf + s++] & 255, i += (e.pending_buf[e.sym_buf + s++] & 255) << 8, r = e.pending_buf[e.sym_buf + s++], i === 0 ? Ve(e, r, t) : (o = An[r], Ve(e, o + zn + 1, t), c = ar[o], c !== 0 && (r -= Ir[o], Ce(e, r, c)), i--, o = da(i), Ve(e, o, n), c = ci[o], c !== 0 && (i -= gi[o], Ce(e, i, c)));
|
|
850
850
|
while (s < e.sym_next);
|
|
851
851
|
Ve(e, Rr, t);
|
|
852
|
-
},
|
|
852
|
+
}, cr = (e, t) => {
|
|
853
853
|
const n = t.dyn_tree, i = t.stat_desc.static_tree, r = t.stat_desc.has_stree, s = t.stat_desc.elems;
|
|
854
854
|
let o, c, l = -1, a;
|
|
855
855
|
for (e.heap_len = 0, e.heap_max = ia, o = 0; o < s; o++)
|
|
@@ -857,10 +857,10 @@ const da = (e) => e < 256 ? kn[e] : kn[256 + (e >>> 7)], Cn = (e, t) => {
|
|
|
857
857
|
for (; e.heap_len < 2; )
|
|
858
858
|
a = e.heap[++e.heap_len] = l < 2 ? ++l : 0, n[a * 2] = 1, e.depth[a] = 0, e.opt_len--, r && (e.static_len -= i[a * 2 + 1]);
|
|
859
859
|
for (t.max_code = l, o = e.heap_len >> 1; o >= 1; o--)
|
|
860
|
-
|
|
860
|
+
Vi(e, n, o);
|
|
861
861
|
a = s;
|
|
862
862
|
do
|
|
863
|
-
o = e.heap[1], e.heap[1] = e.heap[e.heap_len--],
|
|
863
|
+
o = e.heap[1], e.heap[1] = e.heap[e.heap_len--], Vi(e, n, 1), c = e.heap[1], e.heap[--e.heap_max] = o, e.heap[--e.heap_max] = c, n[a * 2] = n[o * 2] + n[c * 2], e.depth[a] = (e.depth[o] >= e.depth[c] ? e.depth[o] : e.depth[c]) + 1, n[o * 2 + 1] = n[c * 2 + 1] = a, e.heap[1] = a++, Vi(e, n, 1);
|
|
864
864
|
while (e.heap_len >= 2);
|
|
865
865
|
e.heap[--e.heap_max] = e.heap[1], jl(e, t), fa(n, l, e.bl_count);
|
|
866
866
|
}, Gs = (e, t, n) => {
|
|
@@ -881,7 +881,7 @@ const da = (e) => e < 256 ? kn[e] : kn[256 + (e >>> 7)], Cn = (e, t) => {
|
|
|
881
881
|
}
|
|
882
882
|
}, Ul = (e) => {
|
|
883
883
|
let t;
|
|
884
|
-
for (Gs(e, e.dyn_ltree, e.l_desc.max_code), Gs(e, e.dyn_dtree, e.d_desc.max_code),
|
|
884
|
+
for (Gs(e, e.dyn_ltree, e.l_desc.max_code), Gs(e, e.dyn_dtree, e.d_desc.max_code), cr(e, e.bl_desc), t = Pr - 1; t >= 3 && e.bl_tree[aa[t] * 2 + 1] === 0; t--)
|
|
885
885
|
;
|
|
886
886
|
return e.opt_len += 3 * (t + 1) + 5 + 5 + 4, t;
|
|
887
887
|
}, $l = (e, t, n, i) => {
|
|
@@ -903,14 +903,14 @@ const da = (e) => e < 256 ? kn[e] : kn[256 + (e >>> 7)], Cn = (e, t) => {
|
|
|
903
903
|
};
|
|
904
904
|
let Ks = !1;
|
|
905
905
|
const Gl = (e) => {
|
|
906
|
-
Ks || (Ml(), Ks = !0), e.l_desc = new
|
|
906
|
+
Ks || (Ml(), Ks = !0), e.l_desc = new Zi(e.dyn_ltree, ca), e.d_desc = new Zi(e.dyn_dtree, la), e.bl_desc = new Zi(e.bl_tree, ha), e.bi_buf = 0, e.bi_valid = 0, ga(e);
|
|
907
907
|
}, pa = (e, t, n, i) => {
|
|
908
908
|
Ce(e, (Pl << 1) + (i ? 1 : 0), 3), ba(e), Cn(e, n), Cn(e, ~n), n && e.pending_buf.set(e.window.subarray(t, t + n), e.pending), e.pending += n;
|
|
909
909
|
}, Wl = (e) => {
|
|
910
910
|
Ce(e, na << 1, 3), Ve(e, Rr, tt), Ll(e);
|
|
911
911
|
}, Kl = (e, t, n, i) => {
|
|
912
912
|
let r, s, o = 0;
|
|
913
|
-
e.level > 0 ? (e.strm.data_type === Bl && (e.strm.data_type = Hl(e)),
|
|
913
|
+
e.level > 0 ? (e.strm.data_type === Bl && (e.strm.data_type = Hl(e)), cr(e, e.l_desc), cr(e, e.d_desc), o = Ul(e), r = e.opt_len + 3 + 7 >>> 3, s = e.static_len + 3 + 7 >>> 3, s <= r && (r = s)) : r = s = n + 5, n + 4 <= r && t !== -1 ? pa(e, t, n, i) : e.strategy === El || s === r ? (Ce(e, (na << 1) + (i ? 1 : 0), 3), Hs(e, tt, yn)) : (Ce(e, (Rl << 1) + (i ? 1 : 0), 3), $l(e, e.l_desc.max_code + 1, e.d_desc.max_code + 1, o + 1), Hs(e, e.dyn_ltree, e.dyn_dtree)), ga(e), i && ba(e);
|
|
914
914
|
}, Zl = (e, t, n) => (e.pending_buf[e.sym_buf + e.sym_next++] = t, e.pending_buf[e.sym_buf + e.sym_next++] = t >> 8, e.pending_buf[e.sym_buf + e.sym_next++] = n, t === 0 ? e.dyn_ltree[n * 2]++ : (e.matches++, t--, e.dyn_ltree[(An[n] + zn + 1) * 2]++, e.dyn_dtree[da(t) * 2]++), e.sym_next === e.sym_end);
|
|
915
915
|
var Vl = Gl, ql = pa, Xl = Kl, Yl = Zl, Jl = Wl, Ql = {
|
|
916
916
|
_tr_init: Vl,
|
|
@@ -930,7 +930,7 @@ const eh = (e, t, n, i) => {
|
|
|
930
930
|
}
|
|
931
931
|
return r | s << 16 | 0;
|
|
932
932
|
};
|
|
933
|
-
var
|
|
933
|
+
var Dn = eh;
|
|
934
934
|
const th = () => {
|
|
935
935
|
let e, t = [];
|
|
936
936
|
for (var n = 0; n < 256; n++) {
|
|
@@ -957,7 +957,7 @@ var ue = ih, St = {
|
|
|
957
957
|
"-4": "insufficient memory",
|
|
958
958
|
"-5": "buffer error",
|
|
959
959
|
"-6": "incompatible version"
|
|
960
|
-
},
|
|
960
|
+
}, Tt = {
|
|
961
961
|
Z_NO_FLUSH: 0,
|
|
962
962
|
Z_PARTIAL_FLUSH: 1,
|
|
963
963
|
Z_SYNC_FLUSH: 2,
|
|
@@ -987,7 +987,7 @@ var ue = ih, St = {
|
|
|
987
987
|
Z_UNKNOWN: 2,
|
|
988
988
|
Z_DEFLATED: 8
|
|
989
989
|
};
|
|
990
|
-
const { _tr_init: rh, _tr_stored_block:
|
|
990
|
+
const { _tr_init: rh, _tr_stored_block: lr, _tr_flush_block: sh, _tr_tally: dt, _tr_align: oh } = Ql, {
|
|
991
991
|
Z_NO_FLUSH: ut,
|
|
992
992
|
Z_PARTIAL_FLUSH: ah,
|
|
993
993
|
Z_FULL_FLUSH: ch,
|
|
@@ -997,7 +997,7 @@ const { _tr_init: rh, _tr_stored_block: hr, _tr_flush_block: sh, _tr_tally: dt,
|
|
|
997
997
|
Z_STREAM_END: Vs,
|
|
998
998
|
Z_STREAM_ERROR: Xe,
|
|
999
999
|
Z_DATA_ERROR: lh,
|
|
1000
|
-
Z_BUF_ERROR:
|
|
1000
|
+
Z_BUF_ERROR: qi,
|
|
1001
1001
|
Z_DEFAULT_COMPRESSION: hh,
|
|
1002
1002
|
Z_FILTERED: dh,
|
|
1003
1003
|
Z_HUFFMAN_ONLY: Jn,
|
|
@@ -1005,12 +1005,12 @@ const { _tr_init: rh, _tr_stored_block: hr, _tr_flush_block: sh, _tr_tally: dt,
|
|
|
1005
1005
|
Z_FIXED: fh,
|
|
1006
1006
|
Z_DEFAULT_STRATEGY: gh,
|
|
1007
1007
|
Z_UNKNOWN: bh,
|
|
1008
|
-
Z_DEFLATED:
|
|
1009
|
-
} =
|
|
1008
|
+
Z_DEFLATED: Si
|
|
1009
|
+
} = Tt, ph = 9, mh = 15, _h = 8, yh = 29, wh = 256, hr = wh + 1 + yh, vh = 30, xh = 19, Sh = 2 * hr + 1, kh = 15, V = 3, lt = 258, Ye = lt + V + 1, Ah = 32, Kt = 42, Or = 57, dr = 69, ur = 73, fr = 91, gr = 103, wt = 113, gn = 666, ye = 1, Yt = 2, kt = 3, Jt = 4, Ch = 3, vt = (e, t) => (e.msg = St[t], t), qs = (e) => e * 2 - (e > 4 ? 9 : 0), ct = (e) => {
|
|
1010
1010
|
let t = e.length;
|
|
1011
1011
|
for (; --t >= 0; )
|
|
1012
1012
|
e[t] = 0;
|
|
1013
|
-
},
|
|
1013
|
+
}, Dh = (e) => {
|
|
1014
1014
|
let t, n, i, r = e.w_size;
|
|
1015
1015
|
t = e.hash_size, i = t;
|
|
1016
1016
|
do
|
|
@@ -1021,7 +1021,7 @@ const { _tr_init: rh, _tr_stored_block: hr, _tr_flush_block: sh, _tr_tally: dt,
|
|
|
1021
1021
|
n = e.prev[--i], e.prev[i] = n >= r ? n - r : 0;
|
|
1022
1022
|
while (--t);
|
|
1023
1023
|
};
|
|
1024
|
-
let
|
|
1024
|
+
let Th = (e, t, n) => (t << e.hash_shift ^ n) & e.hash_mask, ft = Th;
|
|
1025
1025
|
const Ee = (e) => {
|
|
1026
1026
|
const t = e.state;
|
|
1027
1027
|
let n = t.pending;
|
|
@@ -1032,9 +1032,9 @@ const Ee = (e) => {
|
|
|
1032
1032
|
e.pending_buf[e.pending++] = t;
|
|
1033
1033
|
}, sn = (e, t) => {
|
|
1034
1034
|
e.pending_buf[e.pending++] = t >>> 8 & 255, e.pending_buf[e.pending++] = t & 255;
|
|
1035
|
-
},
|
|
1035
|
+
}, br = (e, t, n, i) => {
|
|
1036
1036
|
let r = e.avail_in;
|
|
1037
|
-
return r > i && (r = i), r === 0 ? 0 : (e.avail_in -= r, t.set(e.input.subarray(e.next_in, e.next_in + r), n), e.state.wrap === 1 ? e.adler =
|
|
1037
|
+
return r > i && (r = i), r === 0 ? 0 : (e.avail_in -= r, t.set(e.input.subarray(e.next_in, e.next_in + r), n), e.state.wrap === 1 ? e.adler = Dn(e.adler, t, r, n) : e.state.wrap === 2 && (e.adler = ue(e.adler, t, r, n)), e.next_in += r, e.total_in += r, r);
|
|
1038
1038
|
}, ma = (e, t) => {
|
|
1039
1039
|
let n = e.max_chain_length, i = e.strstart, r, s, o = e.prev_length, c = e.nice_match;
|
|
1040
1040
|
const l = e.strstart > e.w_size - Ye ? e.strstart - (e.w_size - Ye) : 0, a = e.window, h = e.w_mask, f = e.prev, u = e.strstart + lt;
|
|
@@ -1058,9 +1058,9 @@ const Ee = (e) => {
|
|
|
1058
1058
|
const t = e.w_size;
|
|
1059
1059
|
let n, i, r;
|
|
1060
1060
|
do {
|
|
1061
|
-
if (i = e.window_size - e.lookahead - e.strstart, e.strstart >= t + (t - Ye) && (e.window.set(e.window.subarray(t, t + t - i), 0), e.match_start -= t, e.strstart -= t, e.block_start -= t, e.insert > e.strstart && (e.insert = e.strstart),
|
|
1061
|
+
if (i = e.window_size - e.lookahead - e.strstart, e.strstart >= t + (t - Ye) && (e.window.set(e.window.subarray(t, t + t - i), 0), e.match_start -= t, e.strstart -= t, e.block_start -= t, e.insert > e.strstart && (e.insert = e.strstart), Dh(e), i += t), e.strm.avail_in === 0)
|
|
1062
1062
|
break;
|
|
1063
|
-
if (n =
|
|
1063
|
+
if (n = br(e.strm, e.window, e.strstart + e.lookahead, i), e.lookahead += n, e.lookahead + e.insert >= V)
|
|
1064
1064
|
for (r = e.strstart - e.insert, e.ins_h = e.window[r], e.ins_h = ft(e, e.ins_h, e.window[r + 1]); e.insert && (e.ins_h = ft(e, e.ins_h, e.window[r + V - 1]), e.prev[r & e.w_mask] = e.head[e.ins_h], e.head[e.ins_h] = r, r++, e.insert--, !(e.lookahead + e.insert < V)); )
|
|
1065
1065
|
;
|
|
1066
1066
|
} while (e.lookahead < Ye && e.strm.avail_in !== 0);
|
|
@@ -1069,10 +1069,10 @@ const Ee = (e) => {
|
|
|
1069
1069
|
do {
|
|
1070
1070
|
if (i = 65535, s = e.bi_valid + 42 >> 3, e.strm.avail_out < s || (s = e.strm.avail_out - s, r = e.strstart - e.block_start, i > r + e.strm.avail_in && (i = r + e.strm.avail_in), i > s && (i = s), i < n && (i === 0 && t !== ze || t === ut || i !== r + e.strm.avail_in)))
|
|
1071
1071
|
break;
|
|
1072
|
-
o = t === ze && i === r + e.strm.avail_in ? 1 : 0,
|
|
1072
|
+
o = t === ze && i === r + e.strm.avail_in ? 1 : 0, lr(e, 0, 0, o), e.pending_buf[e.pending - 4] = i, e.pending_buf[e.pending - 3] = i >> 8, e.pending_buf[e.pending - 2] = ~i, e.pending_buf[e.pending - 1] = ~i >> 8, Ee(e.strm), r && (r > i && (r = i), e.strm.output.set(e.window.subarray(e.block_start, e.block_start + r), e.strm.next_out), e.strm.next_out += r, e.strm.avail_out -= r, e.strm.total_out += r, e.block_start += r, i -= r), i && (br(e.strm, e.strm.output, e.strm.next_out, i), e.strm.next_out += i, e.strm.avail_out -= i, e.strm.total_out += i);
|
|
1073
1073
|
} while (o === 0);
|
|
1074
|
-
return c -= e.strm.avail_in, c && (c >= e.w_size ? (e.matches = 2, e.window.set(e.strm.input.subarray(e.strm.next_in - e.w_size, e.strm.next_in), 0), e.strstart = e.w_size, e.insert = e.strstart) : (e.window_size - e.strstart <= c && (e.strstart -= e.w_size, e.window.set(e.window.subarray(e.w_size, e.w_size + e.strstart), 0), e.matches < 2 && e.matches++, e.insert > e.strstart && (e.insert = e.strstart)), e.window.set(e.strm.input.subarray(e.strm.next_in - c, e.strm.next_in), e.strstart), e.strstart += c, e.insert += c > e.w_size - e.insert ? e.w_size - e.insert : c), e.block_start = e.strstart), e.high_water < e.strstart && (e.high_water = e.strstart), o ? Jt : t !== ut && t !== ze && e.strm.avail_in === 0 && e.strstart === e.block_start ? Yt : (s = e.window_size - e.strstart, e.strm.avail_in > s && e.block_start >= e.w_size && (e.block_start -= e.w_size, e.strstart -= e.w_size, e.window.set(e.window.subarray(e.w_size, e.w_size + e.strstart), 0), e.matches < 2 && e.matches++, s += e.w_size, e.insert > e.strstart && (e.insert = e.strstart)), s > e.strm.avail_in && (s = e.strm.avail_in), s && (
|
|
1075
|
-
},
|
|
1074
|
+
return c -= e.strm.avail_in, c && (c >= e.w_size ? (e.matches = 2, e.window.set(e.strm.input.subarray(e.strm.next_in - e.w_size, e.strm.next_in), 0), e.strstart = e.w_size, e.insert = e.strstart) : (e.window_size - e.strstart <= c && (e.strstart -= e.w_size, e.window.set(e.window.subarray(e.w_size, e.w_size + e.strstart), 0), e.matches < 2 && e.matches++, e.insert > e.strstart && (e.insert = e.strstart)), e.window.set(e.strm.input.subarray(e.strm.next_in - c, e.strm.next_in), e.strstart), e.strstart += c, e.insert += c > e.w_size - e.insert ? e.w_size - e.insert : c), e.block_start = e.strstart), e.high_water < e.strstart && (e.high_water = e.strstart), o ? Jt : t !== ut && t !== ze && e.strm.avail_in === 0 && e.strstart === e.block_start ? Yt : (s = e.window_size - e.strstart, e.strm.avail_in > s && e.block_start >= e.w_size && (e.block_start -= e.w_size, e.strstart -= e.w_size, e.window.set(e.window.subarray(e.w_size, e.w_size + e.strstart), 0), e.matches < 2 && e.matches++, s += e.w_size, e.insert > e.strstart && (e.insert = e.strstart)), s > e.strm.avail_in && (s = e.strm.avail_in), s && (br(e.strm, e.window, e.strstart, s), e.strstart += s, e.insert += s > e.w_size - e.insert ? e.w_size - e.insert : s), e.high_water < e.strstart && (e.high_water = e.strstart), s = e.bi_valid + 42 >> 3, s = e.pending_buf_size - s > 65535 ? 65535 : e.pending_buf_size - s, n = s > e.w_size ? e.w_size : s, r = e.strstart - e.block_start, (r >= n || (r || t === ze) && t !== ut && e.strm.avail_in === 0 && r <= s) && (i = r > s ? s : r, o = t === ze && e.strm.avail_in === 0 && i === r ? 1 : 0, lr(e, e.block_start, i, o), e.block_start += i, Ee(e.strm)), o ? kt : ye);
|
|
1075
|
+
}, Xi = (e, t) => {
|
|
1076
1076
|
let n, i;
|
|
1077
1077
|
for (; ; ) {
|
|
1078
1078
|
if (e.lookahead < Ye) {
|
|
@@ -1158,9 +1158,9 @@ function Ke(e, t, n, i, r) {
|
|
|
1158
1158
|
}
|
|
1159
1159
|
const bn = [
|
|
1160
1160
|
new Ke(0, 0, 0, 0, _a),
|
|
1161
|
-
new Ke(4, 4, 8, 4,
|
|
1162
|
-
new Ke(4, 5, 16, 8,
|
|
1163
|
-
new Ke(4, 6, 32, 32,
|
|
1161
|
+
new Ke(4, 4, 8, 4, Xi),
|
|
1162
|
+
new Ke(4, 5, 16, 8, Xi),
|
|
1163
|
+
new Ke(4, 6, 32, 32, Xi),
|
|
1164
1164
|
new Ke(4, 4, 16, 16, It),
|
|
1165
1165
|
new Ke(8, 16, 32, 32, It),
|
|
1166
1166
|
new Ke(8, 16, 128, 128, It),
|
|
@@ -1171,13 +1171,13 @@ const bn = [
|
|
|
1171
1171
|
e.window_size = 2 * e.w_size, ct(e.head), e.max_lazy_match = bn[e.level].max_lazy, e.good_match = bn[e.level].good_length, e.nice_match = bn[e.level].nice_length, e.max_chain_length = bn[e.level].max_chain, e.strstart = 0, e.block_start = 0, e.lookahead = 0, e.insert = 0, e.match_length = e.prev_length = V - 1, e.match_available = 0, e.ins_h = 0;
|
|
1172
1172
|
};
|
|
1173
1173
|
function Rh() {
|
|
1174
|
-
this.strm = null, this.status = 0, this.pending_buf = null, this.pending_buf_size = 0, this.pending_out = 0, this.pending = 0, this.wrap = 0, this.gzhead = null, this.gzindex = 0, this.method =
|
|
1174
|
+
this.strm = null, this.status = 0, this.pending_buf = null, this.pending_buf_size = 0, this.pending_out = 0, this.pending = 0, this.wrap = 0, this.gzhead = null, this.gzindex = 0, this.method = Si, this.last_flush = -1, this.w_size = 0, this.w_bits = 0, this.w_mask = 0, this.window = null, this.window_size = 0, this.prev = null, this.head = null, this.ins_h = 0, this.hash_size = 0, this.hash_bits = 0, this.hash_mask = 0, this.hash_shift = 0, this.block_start = 0, this.match_length = 0, this.prev_match = 0, this.match_available = 0, this.strstart = 0, this.match_start = 0, this.lookahead = 0, this.prev_length = 0, this.max_chain_length = 0, this.max_lazy_match = 0, this.level = 0, this.strategy = 0, this.good_match = 0, this.nice_match = 0, this.dyn_ltree = new Uint16Array(Sh * 2), this.dyn_dtree = new Uint16Array((2 * vh + 1) * 2), this.bl_tree = new Uint16Array((2 * xh + 1) * 2), ct(this.dyn_ltree), ct(this.dyn_dtree), ct(this.bl_tree), this.l_desc = null, this.d_desc = null, this.bl_desc = null, this.bl_count = new Uint16Array(kh + 1), this.heap = new Uint16Array(2 * hr + 1), ct(this.heap), this.heap_len = 0, this.heap_max = 0, this.depth = new Uint16Array(2 * hr + 1), ct(this.depth), this.sym_buf = 0, this.lit_bufsize = 0, this.sym_next = 0, this.sym_end = 0, this.opt_len = 0, this.static_len = 0, this.matches = 0, this.insert = 0, this.bi_buf = 0, this.bi_valid = 0;
|
|
1175
1175
|
}
|
|
1176
1176
|
const Nn = (e) => {
|
|
1177
1177
|
if (!e)
|
|
1178
1178
|
return 1;
|
|
1179
1179
|
const t = e.state;
|
|
1180
|
-
return !t || t.strm !== e || t.status !== Kt && t.status !== Or && t.status !==
|
|
1180
|
+
return !t || t.strm !== e || t.status !== Kt && t.status !== Or && t.status !== dr && t.status !== ur && t.status !== fr && t.status !== gr && t.status !== wt && t.status !== gn ? 1 : 0;
|
|
1181
1181
|
}, ya = (e) => {
|
|
1182
1182
|
if (Nn(e))
|
|
1183
1183
|
return vt(e, Xe);
|
|
@@ -1191,27 +1191,27 @@ const Nn = (e) => {
|
|
|
1191
1191
|
if (!e)
|
|
1192
1192
|
return Xe;
|
|
1193
1193
|
let o = 1;
|
|
1194
|
-
if (t === hh && (t = 6), i < 0 ? (o = 0, i = -i) : i > 15 && (o = 2, i -= 16), r < 1 || r > ph || n !==
|
|
1194
|
+
if (t === hh && (t = 6), i < 0 ? (o = 0, i = -i) : i > 15 && (o = 2, i -= 16), r < 1 || r > ph || n !== Si || i < 8 || i > 15 || t < 0 || t > 9 || s < 0 || s > fh || i === 8 && o !== 1)
|
|
1195
1195
|
return vt(e, Xe);
|
|
1196
1196
|
i === 8 && (i = 9);
|
|
1197
1197
|
const c = new Rh();
|
|
1198
1198
|
return e.state = c, c.strm = e, c.status = Kt, c.wrap = o, c.gzhead = null, c.w_bits = i, c.w_size = 1 << c.w_bits, c.w_mask = c.w_size - 1, c.hash_bits = r + 7, c.hash_size = 1 << c.hash_bits, c.hash_mask = c.hash_size - 1, c.hash_shift = ~~((c.hash_bits + V - 1) / V), c.window = new Uint8Array(c.w_size * 2), c.head = new Uint16Array(c.hash_size), c.prev = new Uint16Array(c.w_size), c.lit_bufsize = 1 << r + 6, c.pending_buf_size = c.lit_bufsize * 4, c.pending_buf = new Uint8Array(c.pending_buf_size), c.sym_buf = c.lit_bufsize, c.sym_end = (c.lit_bufsize - 1) * 3, c.level = t, c.strategy = s, c.method = n, wa(e);
|
|
1199
|
-
}, Oh = (e, t) => va(e, t,
|
|
1199
|
+
}, Oh = (e, t) => va(e, t, Si, mh, _h, gh), Fh = (e, t) => {
|
|
1200
1200
|
if (Nn(e) || t > Zs || t < 0)
|
|
1201
1201
|
return e ? vt(e, Xe) : Xe;
|
|
1202
1202
|
const n = e.state;
|
|
1203
1203
|
if (!e.output || e.avail_in !== 0 && !e.input || n.status === gn && t !== ze)
|
|
1204
|
-
return vt(e, e.avail_out === 0 ?
|
|
1204
|
+
return vt(e, e.avail_out === 0 ? qi : Xe);
|
|
1205
1205
|
const i = n.last_flush;
|
|
1206
1206
|
if (n.last_flush = t, n.pending !== 0) {
|
|
1207
1207
|
if (Ee(e), e.avail_out === 0)
|
|
1208
1208
|
return n.last_flush = -1, ge;
|
|
1209
1209
|
} else if (e.avail_in === 0 && qs(t) <= qs(i) && t !== ze)
|
|
1210
|
-
return vt(e,
|
|
1210
|
+
return vt(e, qi);
|
|
1211
1211
|
if (n.status === gn && e.avail_in !== 0)
|
|
1212
|
-
return vt(e,
|
|
1212
|
+
return vt(e, qi);
|
|
1213
1213
|
if (n.status === Kt && n.wrap === 0 && (n.status = wt), n.status === Kt) {
|
|
1214
|
-
let r =
|
|
1214
|
+
let r = Si + (n.w_bits - 8 << 4) << 8, s = -1;
|
|
1215
1215
|
if (n.strategy >= Jn || n.level < 2 ? s = 0 : n.level < 6 ? s = 1 : n.level === 6 ? s = 2 : s = 3, r |= s << 6, n.strstart !== 0 && (r |= Ah), r += 31 - r % 31, sn(n, r), n.strstart !== 0 && (sn(n, e.adler >>> 16), sn(n, e.adler & 65535)), e.adler = 1, n.status = wt, Ee(e), n.pending !== 0)
|
|
1216
1216
|
return n.last_flush = -1, ge;
|
|
1217
1217
|
}
|
|
@@ -1220,11 +1220,11 @@ const Nn = (e) => {
|
|
|
1220
1220
|
J(
|
|
1221
1221
|
n,
|
|
1222
1222
|
(n.gzhead.text ? 1 : 0) + (n.gzhead.hcrc ? 2 : 0) + (n.gzhead.extra ? 4 : 0) + (n.gzhead.name ? 8 : 0) + (n.gzhead.comment ? 16 : 0)
|
|
1223
|
-
), J(n, n.gzhead.time & 255), J(n, n.gzhead.time >> 8 & 255), J(n, n.gzhead.time >> 16 & 255), J(n, n.gzhead.time >> 24 & 255), J(n, n.level === 9 ? 2 : n.strategy >= Jn || n.level < 2 ? 4 : 0), J(n, n.gzhead.os & 255), n.gzhead.extra && n.gzhead.extra.length && (J(n, n.gzhead.extra.length & 255), J(n, n.gzhead.extra.length >> 8 & 255)), n.gzhead.hcrc && (e.adler = ue(e.adler, n.pending_buf, n.pending, 0)), n.gzindex = 0, n.status =
|
|
1223
|
+
), J(n, n.gzhead.time & 255), J(n, n.gzhead.time >> 8 & 255), J(n, n.gzhead.time >> 16 & 255), J(n, n.gzhead.time >> 24 & 255), J(n, n.level === 9 ? 2 : n.strategy >= Jn || n.level < 2 ? 4 : 0), J(n, n.gzhead.os & 255), n.gzhead.extra && n.gzhead.extra.length && (J(n, n.gzhead.extra.length & 255), J(n, n.gzhead.extra.length >> 8 & 255)), n.gzhead.hcrc && (e.adler = ue(e.adler, n.pending_buf, n.pending, 0)), n.gzindex = 0, n.status = dr;
|
|
1224
1224
|
else if (J(n, 0), J(n, 0), J(n, 0), J(n, 0), J(n, 0), J(n, n.level === 9 ? 2 : n.strategy >= Jn || n.level < 2 ? 4 : 0), J(n, Ch), n.status = wt, Ee(e), n.pending !== 0)
|
|
1225
1225
|
return n.last_flush = -1, ge;
|
|
1226
1226
|
}
|
|
1227
|
-
if (n.status ===
|
|
1227
|
+
if (n.status === dr) {
|
|
1228
1228
|
if (n.gzhead.extra) {
|
|
1229
1229
|
let r = n.pending, s = (n.gzhead.extra.length & 65535) - n.gzindex;
|
|
1230
1230
|
for (; n.pending + s > n.pending_buf_size; ) {
|
|
@@ -1236,9 +1236,9 @@ const Nn = (e) => {
|
|
|
1236
1236
|
let o = new Uint8Array(n.gzhead.extra);
|
|
1237
1237
|
n.pending_buf.set(o.subarray(n.gzindex, n.gzindex + s), n.pending), n.pending += s, n.gzhead.hcrc && n.pending > r && (e.adler = ue(e.adler, n.pending_buf, n.pending - r, r)), n.gzindex = 0;
|
|
1238
1238
|
}
|
|
1239
|
-
n.status =
|
|
1239
|
+
n.status = ur;
|
|
1240
1240
|
}
|
|
1241
|
-
if (n.status ===
|
|
1241
|
+
if (n.status === ur) {
|
|
1242
1242
|
if (n.gzhead.name) {
|
|
1243
1243
|
let r = n.pending, s;
|
|
1244
1244
|
do {
|
|
@@ -1251,9 +1251,9 @@ const Nn = (e) => {
|
|
|
1251
1251
|
} while (s !== 0);
|
|
1252
1252
|
n.gzhead.hcrc && n.pending > r && (e.adler = ue(e.adler, n.pending_buf, n.pending - r, r)), n.gzindex = 0;
|
|
1253
1253
|
}
|
|
1254
|
-
n.status =
|
|
1254
|
+
n.status = fr;
|
|
1255
1255
|
}
|
|
1256
|
-
if (n.status ===
|
|
1256
|
+
if (n.status === fr) {
|
|
1257
1257
|
if (n.gzhead.comment) {
|
|
1258
1258
|
let r = n.pending, s;
|
|
1259
1259
|
do {
|
|
@@ -1266,9 +1266,9 @@ const Nn = (e) => {
|
|
|
1266
1266
|
} while (s !== 0);
|
|
1267
1267
|
n.gzhead.hcrc && n.pending > r && (e.adler = ue(e.adler, n.pending_buf, n.pending - r, r));
|
|
1268
1268
|
}
|
|
1269
|
-
n.status =
|
|
1269
|
+
n.status = gr;
|
|
1270
1270
|
}
|
|
1271
|
-
if (n.status ===
|
|
1271
|
+
if (n.status === gr) {
|
|
1272
1272
|
if (n.gzhead.hcrc) {
|
|
1273
1273
|
if (n.pending + 2 > n.pending_buf_size && (Ee(e), n.pending !== 0))
|
|
1274
1274
|
return n.last_flush = -1, ge;
|
|
@@ -1281,7 +1281,7 @@ const Nn = (e) => {
|
|
|
1281
1281
|
let r = n.level === 0 ? _a(n, t) : n.strategy === Jn ? Bh(n, t) : n.strategy === uh ? Eh(n, t) : bn[n.level].func(n, t);
|
|
1282
1282
|
if ((r === kt || r === Jt) && (n.status = gn), r === ye || r === kt)
|
|
1283
1283
|
return e.avail_out === 0 && (n.last_flush = -1), ge;
|
|
1284
|
-
if (r === Yt && (t === ah ? oh(n) : t !== Zs && (
|
|
1284
|
+
if (r === Yt && (t === ah ? oh(n) : t !== Zs && (lr(n, 0, 0, !1), t === ch && (ct(n.head), n.lookahead === 0 && (n.strstart = 0, n.block_start = 0, n.insert = 0))), Ee(e), e.avail_out === 0))
|
|
1285
1285
|
return n.last_flush = -1, ge;
|
|
1286
1286
|
}
|
|
1287
1287
|
return t !== ze ? ge : n.wrap <= 0 ? Vs : (n.wrap === 2 ? (J(n, e.adler & 255), J(n, e.adler >> 8 & 255), J(n, e.adler >> 16 & 255), J(n, e.adler >> 24 & 255), J(n, e.total_in & 255), J(n, e.total_in >> 8 & 255), J(n, e.total_in >> 16 & 255), J(n, e.total_in >> 24 & 255)) : (sn(n, e.adler >>> 16), sn(n, e.adler & 65535)), Ee(e), n.wrap > 0 && (n.wrap = -n.wrap), n.pending !== 0 ? ge : Vs);
|
|
@@ -1297,7 +1297,7 @@ const Nn = (e) => {
|
|
|
1297
1297
|
const i = e.state, r = i.wrap;
|
|
1298
1298
|
if (r === 2 || r === 1 && i.status !== Kt || i.lookahead)
|
|
1299
1299
|
return Xe;
|
|
1300
|
-
if (r === 1 && (e.adler =
|
|
1300
|
+
if (r === 1 && (e.adler = Dn(e.adler, t, n, 0)), i.wrap = 0, n >= i.w_size) {
|
|
1301
1301
|
r === 0 && (ct(i.head), i.strstart = 0, i.block_start = 0, i.insert = 0);
|
|
1302
1302
|
let l = new Uint8Array(i.w_size);
|
|
1303
1303
|
l.set(t.subarray(n - i.w_size, n), 0), t = l, n = i.w_size;
|
|
@@ -1346,7 +1346,7 @@ var Vh = function(e) {
|
|
|
1346
1346
|
n.set(o, r), r += o.length;
|
|
1347
1347
|
}
|
|
1348
1348
|
return n;
|
|
1349
|
-
},
|
|
1349
|
+
}, ki = {
|
|
1350
1350
|
assign: Vh,
|
|
1351
1351
|
flattenChunks: qh
|
|
1352
1352
|
};
|
|
@@ -1356,10 +1356,10 @@ try {
|
|
|
1356
1356
|
} catch {
|
|
1357
1357
|
xa = !1;
|
|
1358
1358
|
}
|
|
1359
|
-
const
|
|
1359
|
+
const Tn = new Uint8Array(256);
|
|
1360
1360
|
for (let e = 0; e < 256; e++)
|
|
1361
|
-
|
|
1362
|
-
|
|
1361
|
+
Tn[e] = e >= 252 ? 6 : e >= 248 ? 5 : e >= 240 ? 4 : e >= 224 ? 3 : e >= 192 ? 2 : 1;
|
|
1362
|
+
Tn[254] = Tn[254] = 1;
|
|
1363
1363
|
var Xh = (e) => {
|
|
1364
1364
|
if (typeof TextEncoder == "function" && TextEncoder.prototype.encode)
|
|
1365
1365
|
return new TextEncoder().encode(e);
|
|
@@ -1390,7 +1390,7 @@ var Jh = (e, t) => {
|
|
|
1390
1390
|
s[r++] = o;
|
|
1391
1391
|
continue;
|
|
1392
1392
|
}
|
|
1393
|
-
let c =
|
|
1393
|
+
let c = Tn[o];
|
|
1394
1394
|
if (c > 4) {
|
|
1395
1395
|
s[r++] = 65533, i += c - 1;
|
|
1396
1396
|
continue;
|
|
@@ -1409,7 +1409,7 @@ var Jh = (e, t) => {
|
|
|
1409
1409
|
let n = t - 1;
|
|
1410
1410
|
for (; n >= 0 && (e[n] & 192) === 128; )
|
|
1411
1411
|
n--;
|
|
1412
|
-
return n < 0 || n === 0 ? t : n +
|
|
1412
|
+
return n < 0 || n === 0 ? t : n + Tn[e[n]] > t ? n : t;
|
|
1413
1413
|
}, En = {
|
|
1414
1414
|
string2buf: Xh,
|
|
1415
1415
|
buf2string: Jh,
|
|
@@ -1429,9 +1429,9 @@ const ka = Object.prototype.toString, {
|
|
|
1429
1429
|
Z_DEFAULT_COMPRESSION: od,
|
|
1430
1430
|
Z_DEFAULT_STRATEGY: ad,
|
|
1431
1431
|
Z_DEFLATED: cd
|
|
1432
|
-
} =
|
|
1432
|
+
} = Tt;
|
|
1433
1433
|
function Ln(e) {
|
|
1434
|
-
this.options =
|
|
1434
|
+
this.options = ki.assign({
|
|
1435
1435
|
level: od,
|
|
1436
1436
|
method: cd,
|
|
1437
1437
|
chunkSize: 16384,
|
|
@@ -1487,7 +1487,7 @@ Ln.prototype.onData = function(e) {
|
|
|
1487
1487
|
this.chunks.push(e);
|
|
1488
1488
|
};
|
|
1489
1489
|
Ln.prototype.onEnd = function(e) {
|
|
1490
|
-
e === bi && (this.result =
|
|
1490
|
+
e === bi && (this.result = ki.flattenChunks(this.chunks)), this.chunks = [], this.err = e, this.msg = this.strm.msg;
|
|
1491
1491
|
};
|
|
1492
1492
|
function Fr(e, t) {
|
|
1493
1493
|
const n = new Ln(t);
|
|
@@ -1501,7 +1501,7 @@ function ld(e, t) {
|
|
|
1501
1501
|
function hd(e, t) {
|
|
1502
1502
|
return t = t || {}, t.gzip = !0, Fr(e, t);
|
|
1503
1503
|
}
|
|
1504
|
-
var dd = Ln, ud = Fr, fd = ld, gd = hd, bd =
|
|
1504
|
+
var dd = Ln, ud = Fr, fd = ld, gd = hd, bd = Tt, pd = {
|
|
1505
1505
|
Deflate: dd,
|
|
1506
1506
|
deflate: ud,
|
|
1507
1507
|
deflateRaw: fd,
|
|
@@ -1510,16 +1510,16 @@ var dd = Ln, ud = Fr, fd = ld, gd = hd, bd = Dt, pd = {
|
|
|
1510
1510
|
};
|
|
1511
1511
|
const Qn = 16209, md = 16191;
|
|
1512
1512
|
var _d = function(t, n) {
|
|
1513
|
-
let i, r, s, o, c, l, a, h, f, u, d, m, y, w, _, E, x, v, R, C, k, I, P,
|
|
1513
|
+
let i, r, s, o, c, l, a, h, f, u, d, m, y, w, _, E, x, v, R, C, k, I, P, T;
|
|
1514
1514
|
const S = t.state;
|
|
1515
|
-
i = t.next_in, P = t.input, r = i + (t.avail_in - 5), s = t.next_out,
|
|
1515
|
+
i = t.next_in, P = t.input, r = i + (t.avail_in - 5), s = t.next_out, T = t.output, o = s - (n - t.avail_out), c = s + (t.avail_out - 257), l = S.dmax, a = S.wsize, h = S.whave, f = S.wnext, u = S.window, d = S.hold, m = S.bits, y = S.lencode, w = S.distcode, _ = (1 << S.lenbits) - 1, E = (1 << S.distbits) - 1;
|
|
1516
1516
|
e:
|
|
1517
1517
|
do {
|
|
1518
1518
|
m < 15 && (d += P[i++] << m, m += 8, d += P[i++] << m, m += 8), x = y[d & _];
|
|
1519
1519
|
t:
|
|
1520
1520
|
for (; ; ) {
|
|
1521
1521
|
if (v = x >>> 24, d >>>= v, m -= v, v = x >>> 16 & 255, v === 0)
|
|
1522
|
-
|
|
1522
|
+
T[s++] = x & 65535;
|
|
1523
1523
|
else if (v & 16) {
|
|
1524
1524
|
R = x & 65535, v &= 15, v && (m < v && (d += P[i++] << m, m += 8), R += d & (1 << v) - 1, d >>>= v, m -= v), m < 15 && (d += P[i++] << m, m += 8, d += P[i++] << m, m += 8), x = w[d & E];
|
|
1525
1525
|
n:
|
|
@@ -1538,40 +1538,40 @@ var _d = function(t, n) {
|
|
|
1538
1538
|
if (k += a - v, v < R) {
|
|
1539
1539
|
R -= v;
|
|
1540
1540
|
do
|
|
1541
|
-
|
|
1541
|
+
T[s++] = u[k++];
|
|
1542
1542
|
while (--v);
|
|
1543
|
-
k = s - C, I =
|
|
1543
|
+
k = s - C, I = T;
|
|
1544
1544
|
}
|
|
1545
1545
|
} else if (f < v) {
|
|
1546
1546
|
if (k += a + f - v, v -= f, v < R) {
|
|
1547
1547
|
R -= v;
|
|
1548
1548
|
do
|
|
1549
|
-
|
|
1549
|
+
T[s++] = u[k++];
|
|
1550
1550
|
while (--v);
|
|
1551
1551
|
if (k = 0, f < R) {
|
|
1552
1552
|
v = f, R -= v;
|
|
1553
1553
|
do
|
|
1554
|
-
|
|
1554
|
+
T[s++] = u[k++];
|
|
1555
1555
|
while (--v);
|
|
1556
|
-
k = s - C, I =
|
|
1556
|
+
k = s - C, I = T;
|
|
1557
1557
|
}
|
|
1558
1558
|
}
|
|
1559
1559
|
} else if (k += f - v, v < R) {
|
|
1560
1560
|
R -= v;
|
|
1561
1561
|
do
|
|
1562
|
-
|
|
1562
|
+
T[s++] = u[k++];
|
|
1563
1563
|
while (--v);
|
|
1564
|
-
k = s - C, I =
|
|
1564
|
+
k = s - C, I = T;
|
|
1565
1565
|
}
|
|
1566
1566
|
for (; R > 2; )
|
|
1567
|
-
|
|
1568
|
-
R && (
|
|
1567
|
+
T[s++] = I[k++], T[s++] = I[k++], T[s++] = I[k++], R -= 3;
|
|
1568
|
+
R && (T[s++] = I[k++], R > 1 && (T[s++] = I[k++]));
|
|
1569
1569
|
} else {
|
|
1570
1570
|
k = s - C;
|
|
1571
1571
|
do
|
|
1572
|
-
|
|
1572
|
+
T[s++] = T[k++], T[s++] = T[k++], T[s++] = T[k++], R -= 3;
|
|
1573
1573
|
while (R > 2);
|
|
1574
|
-
R && (
|
|
1574
|
+
R && (T[s++] = T[k++], R > 1 && (T[s++] = T[k++]));
|
|
1575
1575
|
}
|
|
1576
1576
|
} else if ((v & 64) === 0) {
|
|
1577
1577
|
x = w[(x & 65535) + (d & (1 << v) - 1)];
|
|
@@ -1597,7 +1597,7 @@ var _d = function(t, n) {
|
|
|
1597
1597
|
} while (i < r && s < c);
|
|
1598
1598
|
R = m >> 3, i -= R, m -= R << 3, d &= (1 << m) - 1, t.next_in = i, t.next_out = s, t.avail_in = i < r ? 5 + (r - i) : 5 - (i - r), t.avail_out = s < c ? 257 + (c - s) : 257 - (s - c), S.hold = d, S.bits = m;
|
|
1599
1599
|
};
|
|
1600
|
-
const Ot = 15, Xs = 852, Ys = 592, Js = 0,
|
|
1600
|
+
const Ot = 15, Xs = 852, Ys = 592, Js = 0, Yi = 1, Qs = 2, yd = new Uint16Array([
|
|
1601
1601
|
3,
|
|
1602
1602
|
4,
|
|
1603
1603
|
5,
|
|
@@ -1730,28 +1730,28 @@ const Ot = 15, Xs = 852, Ys = 592, Js = 0, Ji = 1, Qs = 2, yd = new Uint16Array(
|
|
|
1730
1730
|
]), Sd = (e, t, n, i, r, s, o, c) => {
|
|
1731
1731
|
const l = c.bits;
|
|
1732
1732
|
let a = 0, h = 0, f = 0, u = 0, d = 0, m = 0, y = 0, w = 0, _ = 0, E = 0, x, v, R, C, k, I = null, P;
|
|
1733
|
-
const
|
|
1733
|
+
const T = new Uint16Array(Ot + 1), S = new Uint16Array(Ot + 1);
|
|
1734
1734
|
let F = null, B, $, L;
|
|
1735
1735
|
for (a = 0; a <= Ot; a++)
|
|
1736
|
-
|
|
1736
|
+
T[a] = 0;
|
|
1737
1737
|
for (h = 0; h < i; h++)
|
|
1738
|
-
|
|
1739
|
-
for (d = l, u = Ot; u >= 1 &&
|
|
1738
|
+
T[t[n + h]]++;
|
|
1739
|
+
for (d = l, u = Ot; u >= 1 && T[u] === 0; u--)
|
|
1740
1740
|
;
|
|
1741
1741
|
if (d > u && (d = u), u === 0)
|
|
1742
1742
|
return r[s++] = 1 << 24 | 64 << 16 | 0, r[s++] = 1 << 24 | 64 << 16 | 0, c.bits = 1, 0;
|
|
1743
|
-
for (f = 1; f < u &&
|
|
1743
|
+
for (f = 1; f < u && T[f] === 0; f++)
|
|
1744
1744
|
;
|
|
1745
1745
|
for (d < f && (d = f), w = 1, a = 1; a <= Ot; a++)
|
|
1746
|
-
if (w <<= 1, w -=
|
|
1746
|
+
if (w <<= 1, w -= T[a], w < 0)
|
|
1747
1747
|
return -1;
|
|
1748
1748
|
if (w > 0 && (e === Js || u !== 1))
|
|
1749
1749
|
return -1;
|
|
1750
1750
|
for (S[1] = 0, a = 1; a < Ot; a++)
|
|
1751
|
-
S[a + 1] = S[a] +
|
|
1751
|
+
S[a + 1] = S[a] + T[a];
|
|
1752
1752
|
for (h = 0; h < i; h++)
|
|
1753
1753
|
t[n + h] !== 0 && (o[S[t[n + h]]++] = h);
|
|
1754
|
-
if (e === Js ? (I = F = o, P = 20) : e ===
|
|
1754
|
+
if (e === Js ? (I = F = o, P = 20) : e === Yi ? (I = yd, F = wd, P = 257) : (I = vd, F = xd, P = 0), E = 0, h = 0, a = f, k = s, m = d, y = 0, R = -1, _ = 1 << d, C = _ - 1, e === Yi && _ > Xs || e === Qs && _ > Ys)
|
|
1755
1755
|
return 1;
|
|
1756
1756
|
for (; ; ) {
|
|
1757
1757
|
B = a - y, o[h] + 1 < P ? ($ = 0, L = o[h]) : o[h] >= P ? ($ = F[o[h] - P], L = I[o[h] - P]) : ($ = 32 + 64, L = 0), x = 1 << a - y, v = 1 << m, f = v;
|
|
@@ -1760,15 +1760,15 @@ const Ot = 15, Xs = 852, Ys = 592, Js = 0, Ji = 1, Qs = 2, yd = new Uint16Array(
|
|
|
1760
1760
|
while (v !== 0);
|
|
1761
1761
|
for (x = 1 << a - 1; E & x; )
|
|
1762
1762
|
x >>= 1;
|
|
1763
|
-
if (x !== 0 ? (E &= x - 1, E += x) : E = 0, h++, --
|
|
1763
|
+
if (x !== 0 ? (E &= x - 1, E += x) : E = 0, h++, --T[a] === 0) {
|
|
1764
1764
|
if (a === u)
|
|
1765
1765
|
break;
|
|
1766
1766
|
a = t[n + o[h]];
|
|
1767
1767
|
}
|
|
1768
1768
|
if (a > d && (E & C) !== R) {
|
|
1769
|
-
for (y === 0 && (y = d), k += f, m = a - y, w = 1 << m; m + y < u && (w -=
|
|
1769
|
+
for (y === 0 && (y = d), k += f, m = a - y, w = 1 << m; m + y < u && (w -= T[m + y], !(w <= 0)); )
|
|
1770
1770
|
m++, w <<= 1;
|
|
1771
|
-
if (_ += 1 << m, e ===
|
|
1771
|
+
if (_ += 1 << m, e === Yi && _ > Xs || e === Qs && _ > Ys)
|
|
1772
1772
|
return 1;
|
|
1773
1773
|
R = E & C, r[R] = d << 24 | m << 16 | k - s | 0;
|
|
1774
1774
|
}
|
|
@@ -1782,13 +1782,13 @@ const kd = 0, Aa = 1, Ca = 2, {
|
|
|
1782
1782
|
Z_TREES: ei,
|
|
1783
1783
|
Z_OK: At,
|
|
1784
1784
|
Z_STREAM_END: Cd,
|
|
1785
|
-
Z_NEED_DICT:
|
|
1785
|
+
Z_NEED_DICT: Dd,
|
|
1786
1786
|
Z_STREAM_ERROR: Ne,
|
|
1787
|
-
Z_DATA_ERROR:
|
|
1788
|
-
Z_MEM_ERROR:
|
|
1789
|
-
Z_BUF_ERROR:
|
|
1787
|
+
Z_DATA_ERROR: Da,
|
|
1788
|
+
Z_MEM_ERROR: Ta,
|
|
1789
|
+
Z_BUF_ERROR: Td,
|
|
1790
1790
|
Z_DEFLATED: to
|
|
1791
|
-
} =
|
|
1791
|
+
} = Tt, Ai = 16180, no = 16181, io = 16182, ro = 16183, so = 16184, oo = 16185, ao = 16186, co = 16187, lo = 16188, ho = 16189, pi = 16190, et = 16191, Ji = 16192, uo = 16193, Qi = 16194, fo = 16195, go = 16196, bo = 16197, po = 16198, ti = 16199, ni = 16200, mo = 16201, _o = 16202, yo = 16203, wo = 16204, vo = 16205, er = 16206, xo = 16207, So = 16208, se = 16209, Ea = 16210, Ba = 16211, Ed = 852, Bd = 592, Pd = 15, Rd = Pd, ko = (e) => (e >>> 24 & 255) + (e >>> 8 & 65280) + ((e & 65280) << 8) + ((e & 255) << 24);
|
|
1792
1792
|
function Id() {
|
|
1793
1793
|
this.strm = null, this.mode = 0, this.last = !1, this.wrap = 0, this.havedict = !1, this.flags = 0, this.dmax = 0, this.check = 0, this.total = 0, this.head = null, this.wbits = 0, this.wsize = 0, this.whave = 0, this.wnext = 0, this.window = null, this.hold = 0, this.bits = 0, this.length = 0, this.offset = 0, this.extra = 0, this.lencode = null, this.distcode = null, this.lenbits = 0, this.distbits = 0, this.ncode = 0, this.nlen = 0, this.ndist = 0, this.have = 0, this.next = null, this.lens = new Uint16Array(320), this.work = new Uint16Array(288), this.lendyn = null, this.distdyn = null, this.sane = 0, this.back = 0, this.was = 0;
|
|
1794
1794
|
}
|
|
@@ -1796,12 +1796,12 @@ const Et = (e) => {
|
|
|
1796
1796
|
if (!e)
|
|
1797
1797
|
return 1;
|
|
1798
1798
|
const t = e.state;
|
|
1799
|
-
return !t || t.strm !== e || t.mode <
|
|
1799
|
+
return !t || t.strm !== e || t.mode < Ai || t.mode > Ba ? 1 : 0;
|
|
1800
1800
|
}, Pa = (e) => {
|
|
1801
1801
|
if (Et(e))
|
|
1802
1802
|
return Ne;
|
|
1803
1803
|
const t = e.state;
|
|
1804
|
-
return e.total_in = e.total_out = t.total = 0, e.msg = "", t.wrap && (e.adler = t.wrap & 1), t.mode =
|
|
1804
|
+
return e.total_in = e.total_out = t.total = 0, e.msg = "", t.wrap && (e.adler = t.wrap & 1), t.mode = Ai, t.last = 0, t.havedict = 0, t.flags = -1, t.dmax = 32768, t.head = null, t.hold = 0, t.bits = 0, t.lencode = t.lendyn = new Int32Array(Ed), t.distcode = t.distdyn = new Int32Array(Bd), t.sane = 1, t.back = -1, At;
|
|
1805
1805
|
}, Ra = (e) => {
|
|
1806
1806
|
if (Et(e))
|
|
1807
1807
|
return Ne;
|
|
@@ -1817,14 +1817,14 @@ const Et = (e) => {
|
|
|
1817
1817
|
if (!e)
|
|
1818
1818
|
return Ne;
|
|
1819
1819
|
const n = new Id();
|
|
1820
|
-
e.state = n, n.strm = e, n.window = null, n.mode =
|
|
1820
|
+
e.state = n, n.strm = e, n.window = null, n.mode = Ai;
|
|
1821
1821
|
const i = Ia(e, t);
|
|
1822
1822
|
return i !== At && (e.state = null), i;
|
|
1823
1823
|
}, Od = (e) => Oa(e, Rd);
|
|
1824
|
-
let Ao = !0,
|
|
1824
|
+
let Ao = !0, tr, nr;
|
|
1825
1825
|
const Fd = (e) => {
|
|
1826
1826
|
if (Ao) {
|
|
1827
|
-
|
|
1827
|
+
tr = new Int32Array(512), nr = new Int32Array(32);
|
|
1828
1828
|
let t = 0;
|
|
1829
1829
|
for (; t < 144; )
|
|
1830
1830
|
e.lens[t++] = 8;
|
|
@@ -1834,11 +1834,11 @@ const Fd = (e) => {
|
|
|
1834
1834
|
e.lens[t++] = 7;
|
|
1835
1835
|
for (; t < 288; )
|
|
1836
1836
|
e.lens[t++] = 8;
|
|
1837
|
-
for (vn(Aa, e.lens, 0, 288,
|
|
1837
|
+
for (vn(Aa, e.lens, 0, 288, tr, 0, e.work, { bits: 9 }), t = 0; t < 32; )
|
|
1838
1838
|
e.lens[t++] = 5;
|
|
1839
|
-
vn(Ca, e.lens, 0, 32,
|
|
1839
|
+
vn(Ca, e.lens, 0, 32, nr, 0, e.work, { bits: 5 }), Ao = !1;
|
|
1840
1840
|
}
|
|
1841
|
-
e.lencode =
|
|
1841
|
+
e.lencode = tr, e.lenbits = 9, e.distcode = nr, e.distbits = 5;
|
|
1842
1842
|
}, Fa = (e, t, n, i) => {
|
|
1843
1843
|
let r;
|
|
1844
1844
|
const s = e.state;
|
|
@@ -1846,17 +1846,17 @@ const Fd = (e) => {
|
|
|
1846
1846
|
}, zd = (e, t) => {
|
|
1847
1847
|
let n, i, r, s, o, c, l, a, h, f, u, d, m, y, w = 0, _, E, x, v, R, C, k, I;
|
|
1848
1848
|
const P = new Uint8Array(4);
|
|
1849
|
-
let
|
|
1849
|
+
let T, S;
|
|
1850
1850
|
const F = new Uint8Array([16, 17, 18, 0, 8, 7, 9, 6, 10, 5, 11, 4, 12, 3, 13, 2, 14, 1, 15]);
|
|
1851
1851
|
if (Et(e) || !e.output || !e.input && e.avail_in !== 0)
|
|
1852
1852
|
return Ne;
|
|
1853
|
-
n = e.state, n.mode === et && (n.mode =
|
|
1853
|
+
n = e.state, n.mode === et && (n.mode = Ji), o = e.next_out, r = e.output, l = e.avail_out, s = e.next_in, i = e.input, c = e.avail_in, a = n.hold, h = n.bits, f = c, u = l, I = At;
|
|
1854
1854
|
e:
|
|
1855
1855
|
for (; ; )
|
|
1856
1856
|
switch (n.mode) {
|
|
1857
|
-
case
|
|
1857
|
+
case Ai:
|
|
1858
1858
|
if (n.wrap === 0) {
|
|
1859
|
-
n.mode =
|
|
1859
|
+
n.mode = Ji;
|
|
1860
1860
|
break;
|
|
1861
1861
|
}
|
|
1862
1862
|
for (; h < 16; ) {
|
|
@@ -1982,14 +1982,14 @@ const Fd = (e) => {
|
|
|
1982
1982
|
e.adler = n.check = ko(a), a = 0, h = 0, n.mode = pi;
|
|
1983
1983
|
case pi:
|
|
1984
1984
|
if (n.havedict === 0)
|
|
1985
|
-
return e.next_out = o, e.avail_out = l, e.next_in = s, e.avail_in = c, n.hold = a, n.bits = h,
|
|
1985
|
+
return e.next_out = o, e.avail_out = l, e.next_in = s, e.avail_in = c, n.hold = a, n.bits = h, Dd;
|
|
1986
1986
|
e.adler = n.check = 1, n.mode = et;
|
|
1987
1987
|
case et:
|
|
1988
1988
|
if (t === Ad || t === ei)
|
|
1989
1989
|
break e;
|
|
1990
|
-
case
|
|
1990
|
+
case Ji:
|
|
1991
1991
|
if (n.last) {
|
|
1992
|
-
a >>>= h & 7, h -= h & 7, n.mode =
|
|
1992
|
+
a >>>= h & 7, h -= h & 7, n.mode = er;
|
|
1993
1993
|
break;
|
|
1994
1994
|
}
|
|
1995
1995
|
for (; h < 3; ) {
|
|
@@ -2025,9 +2025,9 @@ const Fd = (e) => {
|
|
|
2025
2025
|
e.msg = "invalid stored block lengths", n.mode = se;
|
|
2026
2026
|
break;
|
|
2027
2027
|
}
|
|
2028
|
-
if (n.length = a & 65535, a = 0, h = 0, n.mode =
|
|
2028
|
+
if (n.length = a & 65535, a = 0, h = 0, n.mode = Qi, t === ei)
|
|
2029
2029
|
break e;
|
|
2030
|
-
case
|
|
2030
|
+
case Qi:
|
|
2031
2031
|
n.mode = fo;
|
|
2032
2032
|
case fo:
|
|
2033
2033
|
if (d = n.length, d) {
|
|
@@ -2060,7 +2060,7 @@ const Fd = (e) => {
|
|
|
2060
2060
|
}
|
|
2061
2061
|
for (; n.have < 19; )
|
|
2062
2062
|
n.lens[F[n.have++]] = 0;
|
|
2063
|
-
if (n.lencode = n.lendyn, n.lenbits = 7,
|
|
2063
|
+
if (n.lencode = n.lendyn, n.lenbits = 7, T = { bits: n.lenbits }, I = vn(kd, n.lens, 0, 19, n.lencode, 0, n.work, T), n.lenbits = T.bits, I) {
|
|
2064
2064
|
e.msg = "invalid code lengths set", n.mode = se;
|
|
2065
2065
|
break;
|
|
2066
2066
|
}
|
|
@@ -2115,11 +2115,11 @@ const Fd = (e) => {
|
|
|
2115
2115
|
e.msg = "invalid code -- missing end-of-block", n.mode = se;
|
|
2116
2116
|
break;
|
|
2117
2117
|
}
|
|
2118
|
-
if (n.lenbits = 9,
|
|
2118
|
+
if (n.lenbits = 9, T = { bits: n.lenbits }, I = vn(Aa, n.lens, 0, n.nlen, n.lencode, 0, n.work, T), n.lenbits = T.bits, I) {
|
|
2119
2119
|
e.msg = "invalid literal/lengths set", n.mode = se;
|
|
2120
2120
|
break;
|
|
2121
2121
|
}
|
|
2122
|
-
if (n.distbits = 6, n.distcode = n.distdyn,
|
|
2122
|
+
if (n.distbits = 6, n.distcode = n.distdyn, T = { bits: n.distbits }, I = vn(Ca, n.lens, n.nlen, n.ndist, n.distcode, 0, n.work, T), n.distbits = T.bits, I) {
|
|
2123
2123
|
e.msg = "invalid distances set", n.mode = se;
|
|
2124
2124
|
break;
|
|
2125
2125
|
}
|
|
@@ -2223,14 +2223,14 @@ const Fd = (e) => {
|
|
|
2223
2223
|
break e;
|
|
2224
2224
|
r[o++] = n.length, l--, n.mode = ni;
|
|
2225
2225
|
break;
|
|
2226
|
-
case
|
|
2226
|
+
case er:
|
|
2227
2227
|
if (n.wrap) {
|
|
2228
2228
|
for (; h < 32; ) {
|
|
2229
2229
|
if (c === 0)
|
|
2230
2230
|
break e;
|
|
2231
2231
|
c--, a |= i[s++] << h, h += 8;
|
|
2232
2232
|
}
|
|
2233
|
-
if (u -= l, e.total_out += u, n.total += u, n.wrap & 4 && u && (e.adler = n.check = n.flags ? ue(n.check, r, u, o - u) :
|
|
2233
|
+
if (u -= l, e.total_out += u, n.total += u, n.wrap & 4 && u && (e.adler = n.check = n.flags ? ue(n.check, r, u, o - u) : Dn(n.check, r, u, o - u)), u = l, n.wrap & 4 && (n.flags ? a : ko(a)) !== n.check) {
|
|
2234
2234
|
e.msg = "incorrect data check", n.mode = se;
|
|
2235
2235
|
break;
|
|
2236
2236
|
}
|
|
@@ -2255,15 +2255,15 @@ const Fd = (e) => {
|
|
|
2255
2255
|
I = Cd;
|
|
2256
2256
|
break e;
|
|
2257
2257
|
case se:
|
|
2258
|
-
I =
|
|
2258
|
+
I = Da;
|
|
2259
2259
|
break e;
|
|
2260
2260
|
case Ea:
|
|
2261
|
-
return
|
|
2261
|
+
return Ta;
|
|
2262
2262
|
case Ba:
|
|
2263
2263
|
default:
|
|
2264
2264
|
return Ne;
|
|
2265
2265
|
}
|
|
2266
|
-
return e.next_out = o, e.avail_out = l, e.next_in = s, e.avail_in = c, n.hold = a, n.bits = h, (n.wsize || u !== e.avail_out && n.mode < se && (n.mode <
|
|
2266
|
+
return e.next_out = o, e.avail_out = l, e.next_in = s, e.avail_in = c, n.hold = a, n.bits = h, (n.wsize || u !== e.avail_out && n.mode < se && (n.mode < er || t !== eo)) && Fa(e, e.output, e.next_out, u - e.avail_out), f -= e.avail_in, u -= e.avail_out, e.total_in += f, e.total_out += u, n.total += u, n.wrap & 4 && u && (e.adler = n.check = n.flags ? ue(n.check, r, u, e.next_out - u) : Dn(n.check, r, u, e.next_out - u)), e.data_type = n.bits + (n.last ? 64 : 0) + (n.mode === et ? 128 : 0) + (n.mode === ti || n.mode === Qi ? 256 : 0), (f === 0 && u === 0 || t === eo) && I === At && (I = Td), I;
|
|
2267
2267
|
}, Nd = (e) => {
|
|
2268
2268
|
if (Et(e))
|
|
2269
2269
|
return Ne;
|
|
@@ -2277,7 +2277,7 @@ const Fd = (e) => {
|
|
|
2277
2277
|
}, jd = (e, t) => {
|
|
2278
2278
|
const n = t.length;
|
|
2279
2279
|
let i, r, s;
|
|
2280
|
-
return Et(e) || (i = e.state, i.wrap !== 0 && i.mode !== pi) ? Ne : i.mode === pi && (r = 1, r =
|
|
2280
|
+
return Et(e) || (i = e.state, i.wrap !== 0 && i.mode !== pi) ? Ne : i.mode === pi && (r = 1, r = Dn(r, t, n, 0), r !== i.check) ? Da : (s = Fa(e, t, n, n), s ? (i.mode = Ea, Ta) : (i.havedict = 1, At));
|
|
2281
2281
|
};
|
|
2282
2282
|
var Md = Ra, Ud = Ia, $d = Pa, Hd = Od, Gd = Oa, Wd = zd, Kd = Nd, Zd = Ld, Vd = jd, qd = "pako inflate (from Nodeca project)", nt = {
|
|
2283
2283
|
inflateReset: Md,
|
|
@@ -2299,14 +2299,14 @@ const za = Object.prototype.toString, {
|
|
|
2299
2299
|
Z_NO_FLUSH: Jd,
|
|
2300
2300
|
Z_FINISH: Qd,
|
|
2301
2301
|
Z_OK: Bn,
|
|
2302
|
-
Z_STREAM_END:
|
|
2303
|
-
Z_NEED_DICT:
|
|
2302
|
+
Z_STREAM_END: ir,
|
|
2303
|
+
Z_NEED_DICT: rr,
|
|
2304
2304
|
Z_STREAM_ERROR: eu,
|
|
2305
2305
|
Z_DATA_ERROR: Co,
|
|
2306
2306
|
Z_MEM_ERROR: tu
|
|
2307
|
-
} =
|
|
2307
|
+
} = Tt;
|
|
2308
2308
|
function jn(e) {
|
|
2309
|
-
this.options =
|
|
2309
|
+
this.options = ki.assign({
|
|
2310
2310
|
chunkSize: 1024 * 64,
|
|
2311
2311
|
windowBits: 15,
|
|
2312
2312
|
to: ""
|
|
@@ -2328,23 +2328,23 @@ jn.prototype.push = function(e, t) {
|
|
|
2328
2328
|
if (this.ended)
|
|
2329
2329
|
return !1;
|
|
2330
2330
|
for (t === ~~t ? o = t : o = t === !0 ? Qd : Jd, za.call(e) === "[object ArrayBuffer]" ? n.input = new Uint8Array(e) : n.input = e, n.next_in = 0, n.avail_in = n.input.length; ; ) {
|
|
2331
|
-
for (n.avail_out === 0 && (n.output = new Uint8Array(i), n.next_out = 0, n.avail_out = i), s = nt.inflate(n, o), s ===
|
|
2331
|
+
for (n.avail_out === 0 && (n.output = new Uint8Array(i), n.next_out = 0, n.avail_out = i), s = nt.inflate(n, o), s === rr && r && (s = nt.inflateSetDictionary(n, r), s === Bn ? s = nt.inflate(n, o) : s === Co && (s = rr)); n.avail_in > 0 && s === ir && n.state.wrap > 0 && e[n.next_in] !== 0; )
|
|
2332
2332
|
nt.inflateReset(n), s = nt.inflate(n, o);
|
|
2333
2333
|
switch (s) {
|
|
2334
2334
|
case eu:
|
|
2335
2335
|
case Co:
|
|
2336
|
-
case
|
|
2336
|
+
case rr:
|
|
2337
2337
|
case tu:
|
|
2338
2338
|
return this.onEnd(s), this.ended = !0, !1;
|
|
2339
2339
|
}
|
|
2340
|
-
if (c = n.avail_out, n.next_out && (n.avail_out === 0 || s ===
|
|
2340
|
+
if (c = n.avail_out, n.next_out && (n.avail_out === 0 || s === ir))
|
|
2341
2341
|
if (this.options.to === "string") {
|
|
2342
2342
|
let l = En.utf8border(n.output, n.next_out), a = n.next_out - l, h = En.buf2string(n.output, l);
|
|
2343
2343
|
n.next_out = a, n.avail_out = i - a, a && n.output.set(n.output.subarray(l, l + a), 0), this.onData(h);
|
|
2344
2344
|
} else
|
|
2345
2345
|
this.onData(n.output.length === n.next_out ? n.output : n.output.subarray(0, n.next_out));
|
|
2346
2346
|
if (!(s === Bn && c === 0)) {
|
|
2347
|
-
if (s ===
|
|
2347
|
+
if (s === ir)
|
|
2348
2348
|
return s = nt.inflateEnd(this.strm), this.onEnd(s), this.ended = !0, !0;
|
|
2349
2349
|
if (n.avail_in === 0)
|
|
2350
2350
|
break;
|
|
@@ -2356,7 +2356,7 @@ jn.prototype.onData = function(e) {
|
|
|
2356
2356
|
this.chunks.push(e);
|
|
2357
2357
|
};
|
|
2358
2358
|
jn.prototype.onEnd = function(e) {
|
|
2359
|
-
e === Bn && (this.options.to === "string" ? this.result = this.chunks.join("") : this.result =
|
|
2359
|
+
e === Bn && (this.options.to === "string" ? this.result = this.chunks.join("") : this.result = ki.flattenChunks(this.chunks)), this.chunks = [], this.err = e, this.msg = this.strm.msg;
|
|
2360
2360
|
};
|
|
2361
2361
|
function zr(e, t) {
|
|
2362
2362
|
const n = new jn(t);
|
|
@@ -2367,7 +2367,7 @@ function zr(e, t) {
|
|
|
2367
2367
|
function nu(e, t) {
|
|
2368
2368
|
return t = t || {}, t.raw = !0, zr(e, t);
|
|
2369
2369
|
}
|
|
2370
|
-
var iu = jn, ru = zr, su = nu, ou = zr, au =
|
|
2370
|
+
var iu = jn, ru = zr, su = nu, ou = zr, au = Tt, cu = {
|
|
2371
2371
|
Inflate: iu,
|
|
2372
2372
|
inflate: ru,
|
|
2373
2373
|
inflateRaw: su,
|
|
@@ -2375,7 +2375,7 @@ var iu = jn, ru = zr, su = nu, ou = zr, au = Dt, cu = {
|
|
|
2375
2375
|
constants: au
|
|
2376
2376
|
};
|
|
2377
2377
|
const { Deflate: lu, deflate: hu, deflateRaw: du, gzip: uu } = pd, { Inflate: fu, inflate: gu, inflateRaw: bu, ungzip: pu } = cu;
|
|
2378
|
-
var mu = lu, _u = hu, yu = du, wu = uu, vu = fu, xu = gu, Su = bu, ku = pu, Au =
|
|
2378
|
+
var mu = lu, _u = hu, yu = du, wu = uu, vu = fu, xu = gu, Su = bu, ku = pu, Au = Tt, Nr = {
|
|
2379
2379
|
Deflate: mu,
|
|
2380
2380
|
deflate: _u,
|
|
2381
2381
|
deflateRaw: yu,
|
|
@@ -2447,7 +2447,7 @@ class Cu extends we {
|
|
|
2447
2447
|
return t[n++] = g.n, t[n++] = g.u, t[n++] = g.l, t[n++] = g.l, 4;
|
|
2448
2448
|
}
|
|
2449
2449
|
}
|
|
2450
|
-
const ke = new Cu(),
|
|
2450
|
+
const ke = new Cu(), Ci = class extends we {
|
|
2451
2451
|
constructor(e, t) {
|
|
2452
2452
|
super(), b(this, "context"), b(this, "dict"), this.dict = e, this.context = t;
|
|
2453
2453
|
}
|
|
@@ -2502,7 +2502,7 @@ const ke = new Cu(), Ti = class extends we {
|
|
|
2502
2502
|
return n;
|
|
2503
2503
|
}
|
|
2504
2504
|
clone(e) {
|
|
2505
|
-
const t =
|
|
2505
|
+
const t = Ci.withContext(e || this.context), n = this.entries();
|
|
2506
2506
|
for (let i = 0, r = n.length; i < r; i++) {
|
|
2507
2507
|
const [s, o] = n[i];
|
|
2508
2508
|
t.set(s, o);
|
|
@@ -2540,9 +2540,9 @@ const ke = new Cu(), Ti = class extends we {
|
|
|
2540
2540
|
return e[t++] = g.GreaterThan, e[t++] = g.GreaterThan, t - n;
|
|
2541
2541
|
}
|
|
2542
2542
|
};
|
|
2543
|
-
let W =
|
|
2544
|
-
b(W, "withContext", (e) => new
|
|
2545
|
-
b(W, "fromMapWithContext", (e, t) => new
|
|
2543
|
+
let W = Ci;
|
|
2544
|
+
b(W, "withContext", (e) => new Ci(/* @__PURE__ */ new Map(), e));
|
|
2545
|
+
b(W, "fromMapWithContext", (e, t) => new Ci(e, t));
|
|
2546
2546
|
class gt extends we {
|
|
2547
2547
|
constructor(t) {
|
|
2548
2548
|
super(), b(this, "dict"), this.dict = t;
|
|
@@ -2612,7 +2612,7 @@ const Mr = class extends gt {
|
|
|
2612
2612
|
};
|
|
2613
2613
|
let Vt = Mr;
|
|
2614
2614
|
b(Vt, "of", (e, t) => new Mr(e, t));
|
|
2615
|
-
const La = {},
|
|
2615
|
+
const La = {}, Do = /* @__PURE__ */ new Map(), ja = class extends we {
|
|
2616
2616
|
constructor(e, t, n) {
|
|
2617
2617
|
if (e !== La)
|
|
2618
2618
|
throw new kr("PDFRef");
|
|
@@ -2634,8 +2634,8 @@ const La = {}, To = /* @__PURE__ */ new Map(), ja = class extends we {
|
|
|
2634
2634
|
let oe = ja;
|
|
2635
2635
|
b(oe, "of", (e, t = 0) => {
|
|
2636
2636
|
const n = `${e} ${t} R`;
|
|
2637
|
-
let i =
|
|
2638
|
-
return i || (i = new ja(La, e, t),
|
|
2637
|
+
let i = Do.get(n);
|
|
2638
|
+
return i || (i = new ja(La, e, t), Do.set(n, i)), i;
|
|
2639
2639
|
});
|
|
2640
2640
|
const Ur = class {
|
|
2641
2641
|
constructor(e, t) {
|
|
@@ -2743,7 +2743,7 @@ const Ma = class {
|
|
|
2743
2743
|
};
|
|
2744
2744
|
let Ua = Ma;
|
|
2745
2745
|
b(Ua, "withSeed", (e) => new Ma(e));
|
|
2746
|
-
const
|
|
2746
|
+
const Du = ([e], [t]) => e.objectNumber - t.objectNumber, $a = class {
|
|
2747
2747
|
constructor() {
|
|
2748
2748
|
b(this, "largestObjectNumber"), b(this, "header"), b(this, "trailerInfo"), b(this, "rng"), b(this, "indirectObjects"), b(this, "pushGraphicsStateContentStreamRef"), b(this, "popGraphicsStateContentStreamRef"), this.largestObjectNumber = 0, this.header = Mn.forVersion(1, 7), this.trailerInfo = {}, this.indirectObjects = /* @__PURE__ */ new Map(), this.rng = Ua.withSeed(1);
|
|
2749
2749
|
}
|
|
@@ -2771,7 +2771,7 @@ const Tu = ([e], [t]) => e.objectNumber - t.objectNumber, $a = class {
|
|
|
2771
2771
|
} else if (i instanceof o)
|
|
2772
2772
|
return i;
|
|
2773
2773
|
}
|
|
2774
|
-
throw new
|
|
2774
|
+
throw new or(t, i);
|
|
2775
2775
|
}
|
|
2776
2776
|
}
|
|
2777
2777
|
lookup(e, ...t) {
|
|
@@ -2786,7 +2786,7 @@ const Tu = ([e], [t]) => e.objectNumber - t.objectNumber, $a = class {
|
|
|
2786
2786
|
} else if (n instanceof s)
|
|
2787
2787
|
return n;
|
|
2788
2788
|
}
|
|
2789
|
-
throw new
|
|
2789
|
+
throw new or(t, n);
|
|
2790
2790
|
}
|
|
2791
2791
|
getObjectRef(e) {
|
|
2792
2792
|
const t = Array.from(this.indirectObjects.entries());
|
|
@@ -2798,7 +2798,7 @@ const Tu = ([e], [t]) => e.objectNumber - t.objectNumber, $a = class {
|
|
|
2798
2798
|
}
|
|
2799
2799
|
enumerateIndirectObjects() {
|
|
2800
2800
|
return Array.from(this.indirectObjects.entries()).sort(
|
|
2801
|
-
|
|
2801
|
+
Du
|
|
2802
2802
|
);
|
|
2803
2803
|
}
|
|
2804
2804
|
obj(e) {
|
|
@@ -2827,10 +2827,10 @@ const Tu = ([e], [t]) => e.objectNumber - t.objectNumber, $a = class {
|
|
|
2827
2827
|
}
|
|
2828
2828
|
}
|
|
2829
2829
|
stream(e, t = {}) {
|
|
2830
|
-
return Vt.of(this.obj(t),
|
|
2830
|
+
return Vt.of(this.obj(t), sr(e));
|
|
2831
2831
|
}
|
|
2832
2832
|
flateStream(e, t = {}) {
|
|
2833
|
-
return this.stream(Nr.deflate(
|
|
2833
|
+
return this.stream(Nr.deflate(sr(e)), {
|
|
2834
2834
|
...t,
|
|
2835
2835
|
Filter: "FlateDecode"
|
|
2836
2836
|
});
|
|
@@ -2955,8 +2955,8 @@ ${this.lastXRefOffset}
|
|
|
2955
2955
|
return e[t++] = g.s, e[t++] = g.t, e[t++] = g.a, e[t++] = g.r, e[t++] = g.t, e[t++] = g.x, e[t++] = g.r, e[t++] = g.e, e[t++] = g.f, e[t++] = g.Newline, t += be(this.lastXRefOffset, e, t), e[t++] = g.Newline, e[t++] = g.Percent, e[t++] = g.Percent, e[t++] = g.E, e[t++] = g.O, e[t++] = g.F, t - n;
|
|
2956
2956
|
}
|
|
2957
2957
|
};
|
|
2958
|
-
let
|
|
2959
|
-
b(
|
|
2958
|
+
let Ti = Ha;
|
|
2959
|
+
b(Ti, "forLastCrossRefSectionOffset", (e) => new Ha(e));
|
|
2960
2960
|
const Ga = class {
|
|
2961
2961
|
constructor(e) {
|
|
2962
2962
|
b(this, "dict"), this.dict = e;
|
|
@@ -3074,13 +3074,13 @@ const Ka = class {
|
|
|
3074
3074
|
t += n.sizeInBytes() + 1;
|
|
3075
3075
|
const s = Wa.of(this.createTrailerDict());
|
|
3076
3076
|
t += s.sizeInBytes() + 2;
|
|
3077
|
-
const o =
|
|
3077
|
+
const o = Ti.forLastCrossRefSectionOffset(r);
|
|
3078
3078
|
return t += o.sizeInBytes(), { size: t, header: e, indirectObjects: i, xref: n, trailerDict: s, trailer: o };
|
|
3079
3079
|
}
|
|
3080
3080
|
};
|
|
3081
3081
|
let Vr = Ka;
|
|
3082
3082
|
b(Vr, "forContext", (e, t) => new Ka(e, t));
|
|
3083
|
-
class
|
|
3083
|
+
class Ei {
|
|
3084
3084
|
constructor(t, n, i) {
|
|
3085
3085
|
b(this, "bytes"), b(this, "start"), b(this, "pos"), b(this, "end"), this.bytes = t, this.start = n || 0, this.pos = this.start, this.end = !!n && !!i ? n + i : this.bytes.length;
|
|
3086
3086
|
}
|
|
@@ -3131,16 +3131,16 @@ class Bi {
|
|
|
3131
3131
|
this.start = this.pos;
|
|
3132
3132
|
}
|
|
3133
3133
|
makeSubStream(t, n) {
|
|
3134
|
-
return new
|
|
3134
|
+
return new Ei(this.bytes, t, n);
|
|
3135
3135
|
}
|
|
3136
3136
|
decode() {
|
|
3137
3137
|
return this.bytes;
|
|
3138
3138
|
}
|
|
3139
3139
|
}
|
|
3140
|
-
const
|
|
3140
|
+
const Tu = new Uint8Array(0);
|
|
3141
3141
|
class Un {
|
|
3142
3142
|
constructor(t) {
|
|
3143
|
-
if (b(this, "bufferLength"), b(this, "buffer"), b(this, "eof"), b(this, "pos"), b(this, "minBufferLength"), this.pos = 0, this.bufferLength = 0, this.eof = !1, this.buffer =
|
|
3143
|
+
if (b(this, "bufferLength"), b(this, "buffer"), b(this, "eof"), b(this, "pos"), b(this, "minBufferLength"), this.pos = 0, this.bufferLength = 0, this.eof = !1, this.buffer = Tu, this.minBufferLength = 512, t)
|
|
3144
3144
|
for (; this.minBufferLength < t; )
|
|
3145
3145
|
this.minBufferLength *= 2;
|
|
3146
3146
|
}
|
|
@@ -3201,7 +3201,7 @@ class Un {
|
|
|
3201
3201
|
const i = t + n;
|
|
3202
3202
|
for (; this.bufferLength <= i && !this.eof; )
|
|
3203
3203
|
this.readBlock();
|
|
3204
|
-
return new
|
|
3204
|
+
return new Ei(this.buffer, t, n);
|
|
3205
3205
|
}
|
|
3206
3206
|
decode() {
|
|
3207
3207
|
for (; !this.eof; )
|
|
@@ -3222,7 +3222,7 @@ class Un {
|
|
|
3222
3222
|
return r.set(n), this.buffer = r;
|
|
3223
3223
|
}
|
|
3224
3224
|
}
|
|
3225
|
-
const
|
|
3225
|
+
const To = (e) => e === 32 || e === 9 || e === 13 || e === 10;
|
|
3226
3226
|
class Eu extends Un {
|
|
3227
3227
|
constructor(t, n) {
|
|
3228
3228
|
super(n), b(this, "stream"), b(this, "input"), this.stream = t, this.input = new Uint8Array(5), n && (n = 0.8 * n);
|
|
@@ -3230,7 +3230,7 @@ class Eu extends Un {
|
|
|
3230
3230
|
readBlock() {
|
|
3231
3231
|
const r = this.stream;
|
|
3232
3232
|
let s = r.getByte();
|
|
3233
|
-
for (;
|
|
3233
|
+
for (; To(s); )
|
|
3234
3234
|
s = r.getByte();
|
|
3235
3235
|
if (s === -1 || s === 126) {
|
|
3236
3236
|
this.eof = !0;
|
|
@@ -3245,7 +3245,7 @@ class Eu extends Un {
|
|
|
3245
3245
|
} else {
|
|
3246
3246
|
const a = this.input;
|
|
3247
3247
|
for (a[0] = s, l = 1; l < 5; ++l) {
|
|
3248
|
-
for (s = r.getByte();
|
|
3248
|
+
for (s = r.getByte(); To(s); )
|
|
3249
3249
|
s = r.getByte();
|
|
3250
3250
|
if (a[l] = s, s === -1 || s === 126)
|
|
3251
3251
|
break;
|
|
@@ -4186,7 +4186,7 @@ const Bo = (e, t, n) => {
|
|
|
4186
4186
|
return new Nu(e);
|
|
4187
4187
|
throw new ul(t.asString());
|
|
4188
4188
|
}, Za = ({ dict: e, contents: t }) => {
|
|
4189
|
-
let n = new
|
|
4189
|
+
let n = new Ei(t);
|
|
4190
4190
|
const i = e.lookup(p.of("Filter")), r = e.lookup(p.of("DecodeParms"));
|
|
4191
4191
|
if (i instanceof p)
|
|
4192
4192
|
n = Bo(
|
|
@@ -4202,7 +4202,7 @@ const Bo = (e, t, n) => {
|
|
|
4202
4202
|
r && r.lookupMaybe(s, W)
|
|
4203
4203
|
);
|
|
4204
4204
|
else if (i)
|
|
4205
|
-
throw new
|
|
4205
|
+
throw new or([p, Y], i);
|
|
4206
4206
|
return n;
|
|
4207
4207
|
}, Lu = (e) => {
|
|
4208
4208
|
const t = e.MediaBox(), n = t.lookup(2, M).asNumber() - t.lookup(0, M).asNumber(), i = t.lookup(3, M).asNumber() - t.lookup(1, M).asNumber();
|
|
@@ -4269,7 +4269,7 @@ const Xr = class extends we {
|
|
|
4269
4269
|
};
|
|
4270
4270
|
let Yr = Xr;
|
|
4271
4271
|
b(Yr, "of", (e) => new Xr(e));
|
|
4272
|
-
const
|
|
4272
|
+
const Bi = class extends $r {
|
|
4273
4273
|
constructor(e, t, n = !0) {
|
|
4274
4274
|
super(e, n), b(this, "entries"), b(this, "entryTuplesCache"), b(this, "maxByteWidthsCache"), b(this, "indexCache"), b(this, "computeIndex", () => {
|
|
4275
4275
|
const i = [];
|
|
@@ -4317,7 +4317,7 @@ const Pi = class extends $r {
|
|
|
4317
4317
|
}
|
|
4318
4318
|
clone(e) {
|
|
4319
4319
|
const { dict: t, entries: n, encode: i } = this;
|
|
4320
|
-
return
|
|
4320
|
+
return Bi.of(t.clone(e), n.slice(), i);
|
|
4321
4321
|
}
|
|
4322
4322
|
getContentsString() {
|
|
4323
4323
|
const e = this.entryTuplesCache.access(), t = this.maxByteWidthsCache.access();
|
|
@@ -4357,12 +4357,12 @@ const Pi = class extends $r {
|
|
|
4357
4357
|
this.dict.set(p.of("W"), n.obj(e)), this.dict.set(p.of("Index"), n.obj(t));
|
|
4358
4358
|
}
|
|
4359
4359
|
};
|
|
4360
|
-
let Jr =
|
|
4360
|
+
let Jr = Bi;
|
|
4361
4361
|
b(Jr, "create", (e, t = !0) => {
|
|
4362
|
-
const n = new
|
|
4362
|
+
const n = new Bi(e, [], t);
|
|
4363
4363
|
return n.addDeletedEntry(oe.of(0, 65535), 0), n;
|
|
4364
4364
|
});
|
|
4365
|
-
b(Jr, "of", (e, t, n = !0) => new
|
|
4365
|
+
b(Jr, "of", (e, t, n = !0) => new Bi(e, t, n));
|
|
4366
4366
|
const Va = class extends Vr {
|
|
4367
4367
|
constructor(e, t, n, i) {
|
|
4368
4368
|
super(e, t), b(this, "encodeStreams"), b(this, "objectsPerStream"), this.encodeStreams = n, this.objectsPerStream = i;
|
|
@@ -4396,7 +4396,7 @@ const Va = class extends Vr {
|
|
|
4396
4396
|
i.dict.set(p.of("Size"), M.of(e)), i.addUncompressedEntry(l, n);
|
|
4397
4397
|
const a = n;
|
|
4398
4398
|
n += this.computeIndirectObjectSize([l, i]), r.push([l, i]);
|
|
4399
|
-
const h =
|
|
4399
|
+
const h = Ti.forLastCrossRefSectionOffset(a);
|
|
4400
4400
|
return n += h.sizeInBytes(), { size: n, header: t, indirectObjects: r, trailer: h };
|
|
4401
4401
|
}
|
|
4402
4402
|
};
|
|
@@ -4535,25 +4535,25 @@ A.toRGBA8.decodeImage = function(e, t, n, i) {
|
|
|
4535
4535
|
if (h == 1)
|
|
4536
4536
|
for (var k = 0; k < n; k++)
|
|
4537
4537
|
for (var I = k * o, P = k * t, d = 0; d < t; d++) {
|
|
4538
|
-
var x = P + d << 2,
|
|
4539
|
-
c[x] = v[S], c[x + 1] = v[S + 1], c[x + 2] = v[S + 2], c[x + 3] =
|
|
4538
|
+
var x = P + d << 2, T = e[I + (d >> 3)] >> 7 - ((d & 7) << 0) & 1, S = 3 * T;
|
|
4539
|
+
c[x] = v[S], c[x + 1] = v[S + 1], c[x + 2] = v[S + 2], c[x + 3] = T < C ? R[T] : 255;
|
|
4540
4540
|
}
|
|
4541
4541
|
if (h == 2)
|
|
4542
4542
|
for (var k = 0; k < n; k++)
|
|
4543
4543
|
for (var I = k * o, P = k * t, d = 0; d < t; d++) {
|
|
4544
|
-
var x = P + d << 2,
|
|
4545
|
-
c[x] = v[S], c[x + 1] = v[S + 1], c[x + 2] = v[S + 2], c[x + 3] =
|
|
4544
|
+
var x = P + d << 2, T = e[I + (d >> 2)] >> 6 - ((d & 3) << 1) & 3, S = 3 * T;
|
|
4545
|
+
c[x] = v[S], c[x + 1] = v[S + 1], c[x + 2] = v[S + 2], c[x + 3] = T < C ? R[T] : 255;
|
|
4546
4546
|
}
|
|
4547
4547
|
if (h == 4)
|
|
4548
4548
|
for (var k = 0; k < n; k++)
|
|
4549
4549
|
for (var I = k * o, P = k * t, d = 0; d < t; d++) {
|
|
4550
|
-
var x = P + d << 2,
|
|
4551
|
-
c[x] = v[S], c[x + 1] = v[S + 1], c[x + 2] = v[S + 2], c[x + 3] =
|
|
4550
|
+
var x = P + d << 2, T = e[I + (d >> 1)] >> 4 - ((d & 1) << 2) & 15, S = 3 * T;
|
|
4551
|
+
c[x] = v[S], c[x + 1] = v[S + 1], c[x + 2] = v[S + 2], c[x + 3] = T < C ? R[T] : 255;
|
|
4552
4552
|
}
|
|
4553
4553
|
if (h == 8)
|
|
4554
4554
|
for (var d = 0; d < r; d++) {
|
|
4555
|
-
var x = d << 2,
|
|
4556
|
-
c[x] = v[S], c[x + 1] = v[S + 1], c[x + 2] = v[S + 2], c[x + 3] =
|
|
4555
|
+
var x = d << 2, T = e[d], S = 3 * T;
|
|
4556
|
+
c[x] = v[S], c[x + 1] = v[S + 1], c[x + 2] = v[S + 2], c[x + 3] = T < C ? R[T] : 255;
|
|
4557
4557
|
}
|
|
4558
4558
|
} else if (a == 4) {
|
|
4559
4559
|
if (h == 8)
|
|
@@ -4731,13 +4731,13 @@ A.inflateRaw = function() {
|
|
|
4731
4731
|
}
|
|
4732
4732
|
if (k && (n = e.H.W(n, f + (1 << 17))), s == 1 && (d = C.J, m = C.h, a = (1 << 9) - 1, h = (1 << 5) - 1), s == 2) {
|
|
4733
4733
|
o = _(t, u, 5) + 257, c = _(t, u + 5, 5) + 1, l = _(t, u + 10, 4) + 4, u += 14;
|
|
4734
|
-
for (var
|
|
4734
|
+
for (var T = 1, S = 0; S < 38; S += 2)
|
|
4735
4735
|
C.Q[S] = 0, C.Q[S + 1] = 0;
|
|
4736
4736
|
for (var S = 0; S < l; S++) {
|
|
4737
4737
|
var F = _(t, u + S * 3, 3);
|
|
4738
|
-
C.Q[(C.X[S] << 1) + 1] = F, F >
|
|
4738
|
+
C.Q[(C.X[S] << 1) + 1] = F, F > T && (T = F);
|
|
4739
4739
|
}
|
|
4740
|
-
u += 3 * l, x(C.Q,
|
|
4740
|
+
u += 3 * l, x(C.Q, T), v(C.Q, T, C.u), d = C.w, m = C.d, u = E(C.u, (1 << T) - 1, o + c, t, u, C.v);
|
|
4741
4741
|
var B = y.V(C.v, 0, o, C.C);
|
|
4742
4742
|
a = (1 << B) - 1;
|
|
4743
4743
|
var $ = y.V(C.v, o, c, C.D);
|
|
@@ -5034,8 +5034,8 @@ A.decode._readInterlace = function(e, t) {
|
|
|
5034
5034
|
P = P >> 4 - (I & 7) & 15, c[C * o + (k >> 1)] |= P << 4 - ((k & 1) << 2);
|
|
5035
5035
|
}
|
|
5036
5036
|
if (r >= 8)
|
|
5037
|
-
for (var
|
|
5038
|
-
c[
|
|
5037
|
+
for (var T = C * o + k * s, S = 0; S < s; S++)
|
|
5038
|
+
c[T + S] = e[(I >> 3) + S];
|
|
5039
5039
|
I += r, k += y;
|
|
5040
5040
|
}
|
|
5041
5041
|
R++, C += m;
|
|
@@ -5217,8 +5217,8 @@ A.encode._main = function(e, t, n, i, r) {
|
|
|
5217
5217
|
h && (o(_, a, 26), a += 4, l(_, a, "fcTL"), a += 4, o(_, a, I++), a += 4, o(_, a, w.rect.width), a += 4, o(_, a, w.rect.height), a += 4, o(_, a, w.rect.x), a += 4, o(_, a, w.rect.y), a += 4, c(_, a, i[y]), a += 2, c(_, a, 1e3), a += 2, _[a] = w.dispose, a++, _[a] = w.blend, a++, o(_, a, s(_, a - 30, 30)), a += 4);
|
|
5218
5218
|
var P = w.cimg, d = P.length;
|
|
5219
5219
|
o(_, a, d + (y == 0 ? 0 : 4)), a += 4;
|
|
5220
|
-
var
|
|
5221
|
-
l(_, a, y == 0 ? "IDAT" : "fdAT"), a += 4, y != 0 && (o(_, a, I++), a += 4), _.set(P, a), a += d, o(_, a, s(_,
|
|
5220
|
+
var T = a;
|
|
5221
|
+
l(_, a, y == 0 ? "IDAT" : "fdAT"), a += 4, y != 0 && (o(_, a, I++), a += 4), _.set(P, a), a += d, o(_, a, s(_, T, a - T)), a += 4;
|
|
5222
5222
|
}
|
|
5223
5223
|
return o(_, a, 0), a += 4, l(_, a, "IEND"), a += 4, o(_, a, s(_, a - 4, 4)), a += 4, _.buffer;
|
|
5224
5224
|
};
|
|
@@ -5246,11 +5246,11 @@ A.encode.compress = function(e, t, n, i, r) {
|
|
|
5246
5246
|
if (i != 0) {
|
|
5247
5247
|
for (var C = [], w = 0; w < E.length; w++)
|
|
5248
5248
|
C.push(E[w].img.buffer);
|
|
5249
|
-
for (var k = A.encode.concatRGBA(C), I = A.quantize(k, i), P = 0,
|
|
5249
|
+
for (var k = A.encode.concatRGBA(C), I = A.quantize(k, i), P = 0, T = new Uint8Array(I.abuf), w = 0; w < E.length; w++) {
|
|
5250
5250
|
var S = E[w].img, F = S.length;
|
|
5251
5251
|
R.push(new Uint8Array(I.inds.buffer, P >> 2, F >> 2));
|
|
5252
5252
|
for (var d = 0; d < F; d += 4)
|
|
5253
|
-
S[d] =
|
|
5253
|
+
S[d] = T[P + d], S[d + 1] = T[P + d + 1], S[d + 2] = T[P + d + 2], S[d + 3] = T[P + d + 3];
|
|
5254
5254
|
P += F;
|
|
5255
5255
|
}
|
|
5256
5256
|
for (var w = 0; w < I.plte.length; w++)
|
|
@@ -5280,7 +5280,7 @@ A.encode.compress = function(e, t, n, i, r) {
|
|
|
5280
5280
|
B.rect.x, B.rect.y;
|
|
5281
5281
|
var L = B.rect.width, at = B.rect.height, xe = B.img;
|
|
5282
5282
|
new Uint32Array(xe.buffer);
|
|
5283
|
-
var Ie = 4 * L,
|
|
5283
|
+
var Ie = 4 * L, Hi = 4;
|
|
5284
5284
|
if (He <= 256 && a == !1) {
|
|
5285
5285
|
Ie = Math.ceil(f * L / 8);
|
|
5286
5286
|
for (var Ge = new Uint8Array(Ie * at), Zn = R[d], Vn = 0; Vn < at; Vn++) {
|
|
@@ -5298,15 +5298,15 @@ A.encode.compress = function(e, t, n, i, r) {
|
|
|
5298
5298
|
for (var le = 0; le < L; le++)
|
|
5299
5299
|
Ge[w + (le >> 3)] |= Zn[qn + le] << 7 - (le & 7) * 1;
|
|
5300
5300
|
}
|
|
5301
|
-
xe = Ge, h = 3,
|
|
5301
|
+
xe = Ge, h = 3, Hi = 1;
|
|
5302
5302
|
} else if (_ == !1 && E.length == 1) {
|
|
5303
5303
|
for (var Ge = new Uint8Array(L * at * 3), Ic = L * at, w = 0; w < Ic; w++) {
|
|
5304
|
-
var S = w * 3,
|
|
5305
|
-
Ge[S] = xe[
|
|
5304
|
+
var S = w * 3, Gi = w * 4;
|
|
5305
|
+
Ge[S] = xe[Gi], Ge[S + 1] = xe[Gi + 1], Ge[S + 2] = xe[Gi + 2];
|
|
5306
5306
|
}
|
|
5307
|
-
xe = Ge, h = 2,
|
|
5307
|
+
xe = Ge, h = 2, Hi = 3, Ie = 3 * L;
|
|
5308
5308
|
}
|
|
5309
|
-
B.img = xe, B.bpl = Ie, B.bpp =
|
|
5309
|
+
B.img = xe, B.bpl = Ie, B.bpp = Hi;
|
|
5310
5310
|
}
|
|
5311
5311
|
return { ctype: h, depth: f, plte: v, frames: E };
|
|
5312
5312
|
};
|
|
@@ -5316,9 +5316,9 @@ A.encode.framize = function(e, t, n, i, r, s) {
|
|
|
5316
5316
|
if (c != 0) {
|
|
5317
5317
|
for (var w = s || i || c == 1 || o[c - 2].dispose != 0 ? 1 : 2, _ = 0, E = 1e9, x = 0; x < w; x++) {
|
|
5318
5318
|
for (var B = new Uint8Array(e[c - 1 - x]), v = new Uint32Array(e[c - 1 - x]), R = t, C = n, k = -1, I = -1, P = 0; P < n; P++)
|
|
5319
|
-
for (var
|
|
5320
|
-
var S = P * t +
|
|
5321
|
-
a[S] != v[S] && (
|
|
5319
|
+
for (var T = 0; T < t; T++) {
|
|
5320
|
+
var S = P * t + T;
|
|
5321
|
+
a[S] != v[S] && (T < R && (R = T), T > k && (k = T), P < C && (C = P), P > I && (I = P));
|
|
5322
5322
|
}
|
|
5323
5323
|
k == -1 && (R = C = k = I = 0), r && ((R & 1) == 1 && R--, (C & 1) == 1 && C--);
|
|
5324
5324
|
var F = (k - R + 1) * (I - C + 1);
|
|
@@ -5688,7 +5688,7 @@ class es {
|
|
|
5688
5688
|
return t.register(n);
|
|
5689
5689
|
}
|
|
5690
5690
|
}
|
|
5691
|
-
const
|
|
5691
|
+
const Pi = class extends we {
|
|
5692
5692
|
constructor(e) {
|
|
5693
5693
|
super(), b(this, "value"), this.value = e;
|
|
5694
5694
|
}
|
|
@@ -5718,7 +5718,7 @@ const Ri = class extends we {
|
|
|
5718
5718
|
return this.value;
|
|
5719
5719
|
}
|
|
5720
5720
|
clone() {
|
|
5721
|
-
return
|
|
5721
|
+
return Pi.of(this.value);
|
|
5722
5722
|
}
|
|
5723
5723
|
toString() {
|
|
5724
5724
|
return `(${this.value})`;
|
|
@@ -5730,14 +5730,14 @@ const Ri = class extends we {
|
|
|
5730
5730
|
return e[t++] = g.LeftParen, t += be(this.value, e, t), e[t++] = g.RightParen, this.value.length + 2;
|
|
5731
5731
|
}
|
|
5732
5732
|
};
|
|
5733
|
-
let ce =
|
|
5734
|
-
b(ce, "of", (e) => new
|
|
5733
|
+
let ce = Pi;
|
|
5734
|
+
b(ce, "of", (e) => new Pi(e));
|
|
5735
5735
|
b(ce, "fromDate", (e) => {
|
|
5736
5736
|
const t = je(String(e.getUTCFullYear()), 4, "0"), n = je(String(e.getUTCMonth() + 1), 2, "0"), i = je(String(e.getUTCDate()), 2, "0"), r = je(String(e.getUTCHours()), 2, "0"), s = je(String(e.getUTCMinutes()), 2, "0"), o = je(String(e.getUTCSeconds()), 2, "0");
|
|
5737
|
-
return new
|
|
5737
|
+
return new Pi(`D:${t}${n}${i}${r}${s}${o}Z`);
|
|
5738
5738
|
});
|
|
5739
5739
|
const Hu = /\/([^\0\t\n\f\r\ ]+)[\0\t\n\f\r\ ]*(\d*\.\d+|\d+)?[\0\t\n\f\r\ ]+Tf/;
|
|
5740
|
-
class
|
|
5740
|
+
class Ri {
|
|
5741
5741
|
constructor(t, n) {
|
|
5742
5742
|
b(this, "dict"), b(this, "ref"), this.dict = t, this.ref = n;
|
|
5743
5743
|
}
|
|
@@ -5767,7 +5767,7 @@ class Ii {
|
|
|
5767
5767
|
const t = this.dict.get(p.of("Parent"));
|
|
5768
5768
|
if (t instanceof oe) {
|
|
5769
5769
|
const n = this.dict.lookup(p.of("Parent"), W);
|
|
5770
|
-
return new
|
|
5770
|
+
return new Ri(n, t);
|
|
5771
5771
|
}
|
|
5772
5772
|
}
|
|
5773
5773
|
setParent(t) {
|
|
@@ -6122,7 +6122,7 @@ b(mi, "create", (e, t) => {
|
|
|
6122
6122
|
});
|
|
6123
6123
|
return new ts(n);
|
|
6124
6124
|
});
|
|
6125
|
-
const nc = class extends
|
|
6125
|
+
const nc = class extends Ri {
|
|
6126
6126
|
FT() {
|
|
6127
6127
|
const e = this.getInheritableAttribute(p.of("FT"));
|
|
6128
6128
|
return this.dict.context.lookup(e, p);
|
|
@@ -6352,7 +6352,7 @@ b(os, "create", (e) => {
|
|
|
6352
6352
|
}), n = e.register(t);
|
|
6353
6353
|
return new ss(t, n);
|
|
6354
6354
|
});
|
|
6355
|
-
const as = class extends
|
|
6355
|
+
const as = class extends Ri {
|
|
6356
6356
|
addField(e) {
|
|
6357
6357
|
const { Kids: t } = this.normalizedEntries();
|
|
6358
6358
|
t?.push(e);
|
|
@@ -6362,9 +6362,9 @@ const as = class extends Ii {
|
|
|
6362
6362
|
return e || (e = this.dict.context.obj([]), this.dict.set(p.of("Kids"), e)), { Kids: e };
|
|
6363
6363
|
}
|
|
6364
6364
|
};
|
|
6365
|
-
let
|
|
6366
|
-
b(
|
|
6367
|
-
b(
|
|
6365
|
+
let Ii = as;
|
|
6366
|
+
b(Ii, "fromDict", (e, t) => new as(e, t));
|
|
6367
|
+
b(Ii, "create", (e) => {
|
|
6368
6368
|
const t = e.obj({}), n = e.register(t);
|
|
6369
6369
|
return new as(t, n);
|
|
6370
6370
|
});
|
|
@@ -6487,7 +6487,7 @@ const Ku = (e) => {
|
|
|
6487
6487
|
r instanceof oe && s instanceof W && t.push([oc(s, r), r]);
|
|
6488
6488
|
}
|
|
6489
6489
|
return t;
|
|
6490
|
-
}, oc = (e, t) => Zu(e) ?
|
|
6490
|
+
}, oc = (e, t) => Zu(e) ? Ii.fromDict(e, t) : Vu(e, t), Zu = (e) => {
|
|
6491
6491
|
const t = e.lookup(p.of("Kids"));
|
|
6492
6492
|
if (t instanceof Y)
|
|
6493
6493
|
for (let n = 0, i = t.size(); n < i; n++) {
|
|
@@ -6502,12 +6502,12 @@ const Ku = (e) => {
|
|
|
6502
6502
|
}, qu = (e, t) => {
|
|
6503
6503
|
var n;
|
|
6504
6504
|
const i = ps(e, p.of("Ff")), r = e.context.lookupMaybe(i, M), s = (n = r?.asNumber()) != null ? n : 0;
|
|
6505
|
-
return
|
|
6505
|
+
return pr(s, Pn.PushButton) ? ds.fromDict(e, t) : pr(s, Pn.Radio) ? fs.fromDict(e, t) : rs.fromDict(e, t);
|
|
6506
6506
|
}, Xu = (e, t) => {
|
|
6507
6507
|
var n;
|
|
6508
6508
|
const i = ps(e, p.of("Ff")), r = e.context.lookupMaybe(i, M), s = (n = r?.asNumber()) != null ? n : 0;
|
|
6509
|
-
return
|
|
6510
|
-
},
|
|
6509
|
+
return pr(s, Ht.Combo) ? os.fromDict(e, t) : bs.fromDict(e, t);
|
|
6510
|
+
}, pr = (e, t) => (e & t) !== 0, ps = (e, t) => {
|
|
6511
6511
|
let n;
|
|
6512
6512
|
return ac(e, (i) => {
|
|
6513
6513
|
n || (n = i.get(t));
|
|
@@ -6540,7 +6540,7 @@ const Ku = (e) => {
|
|
|
6540
6540
|
const s = n[i];
|
|
6541
6541
|
e.push(s);
|
|
6542
6542
|
const [o] = s;
|
|
6543
|
-
o instanceof
|
|
6543
|
+
o instanceof Ii && t(Ku(o.Kids()));
|
|
6544
6544
|
}
|
|
6545
6545
|
};
|
|
6546
6546
|
return t(this.getFields()), e;
|
|
@@ -6572,7 +6572,7 @@ const ii = (e, t) => {
|
|
|
6572
6572
|
if (e !== void 0)
|
|
6573
6573
|
return t[e];
|
|
6574
6574
|
};
|
|
6575
|
-
var
|
|
6575
|
+
var mr = /* @__PURE__ */ ((e) => (e.UseNone = "UseNone", e.UseOutlines = "UseOutlines", e.UseThumbs = "UseThumbs", e.UseOC = "UseOC", e))(mr || {}), _r = /* @__PURE__ */ ((e) => (e.L2R = "L2R", e.R2L = "R2L", e))(_r || {}), yr = /* @__PURE__ */ ((e) => (e.None = "None", e.AppDefault = "AppDefault", e))(yr || {}), wr = /* @__PURE__ */ ((e) => (e.Simplex = "Simplex", e.DuplexFlipShortEdge = "DuplexFlipShortEdge", e.DuplexFlipLongEdge = "DuplexFlipLongEdge", e))(wr || {});
|
|
6576
6576
|
const _s = class {
|
|
6577
6577
|
constructor(e) {
|
|
6578
6578
|
b(this, "dict"), this.dict = e;
|
|
@@ -6657,22 +6657,22 @@ const _s = class {
|
|
|
6657
6657
|
getNonFullScreenPageMode() {
|
|
6658
6658
|
var e, t;
|
|
6659
6659
|
const n = (e = this.NonFullScreenPageMode()) == null ? void 0 : e.decodeText();
|
|
6660
|
-
return (t = ii(n,
|
|
6660
|
+
return (t = ii(n, mr)) != null ? t : "UseNone";
|
|
6661
6661
|
}
|
|
6662
6662
|
getReadingDirection() {
|
|
6663
6663
|
var e, t;
|
|
6664
6664
|
const n = (e = this.Direction()) == null ? void 0 : e.decodeText();
|
|
6665
|
-
return (t = ii(n,
|
|
6665
|
+
return (t = ii(n, _r)) != null ? t : "L2R";
|
|
6666
6666
|
}
|
|
6667
6667
|
getPrintScaling() {
|
|
6668
6668
|
var e, t;
|
|
6669
6669
|
const n = (e = this.PrintScaling()) == null ? void 0 : e.decodeText();
|
|
6670
|
-
return (t = ii(n,
|
|
6670
|
+
return (t = ii(n, yr)) != null ? t : "AppDefault";
|
|
6671
6671
|
}
|
|
6672
6672
|
getDuplex() {
|
|
6673
6673
|
var e;
|
|
6674
6674
|
const t = (e = this.Duplex()) == null ? void 0 : e.decodeText();
|
|
6675
|
-
return ii(t,
|
|
6675
|
+
return ii(t, wr);
|
|
6676
6676
|
}
|
|
6677
6677
|
getPickTrayByPDFSize() {
|
|
6678
6678
|
var e;
|
|
@@ -6721,23 +6721,23 @@ const _s = class {
|
|
|
6721
6721
|
fn(
|
|
6722
6722
|
e,
|
|
6723
6723
|
"nonFullScreenPageMode",
|
|
6724
|
-
|
|
6724
|
+
mr
|
|
6725
6725
|
);
|
|
6726
6726
|
const t = p.of(e);
|
|
6727
6727
|
this.dict.set(p.of("NonFullScreenPageMode"), t);
|
|
6728
6728
|
}
|
|
6729
6729
|
setReadingDirection(e) {
|
|
6730
|
-
fn(e, "readingDirection",
|
|
6730
|
+
fn(e, "readingDirection", _r);
|
|
6731
6731
|
const t = p.of(e);
|
|
6732
6732
|
this.dict.set(p.of("Direction"), t);
|
|
6733
6733
|
}
|
|
6734
6734
|
setPrintScaling(e) {
|
|
6735
|
-
fn(e, "printScaling",
|
|
6735
|
+
fn(e, "printScaling", yr);
|
|
6736
6736
|
const t = p.of(e);
|
|
6737
6737
|
this.dict.set(p.of("PrintScaling"), t);
|
|
6738
6738
|
}
|
|
6739
6739
|
setDuplex(e) {
|
|
6740
|
-
fn(e, "duplex",
|
|
6740
|
+
fn(e, "duplex", wr);
|
|
6741
6741
|
const t = p.of(e);
|
|
6742
6742
|
this.dict.set(p.of("Duplex"), t);
|
|
6743
6743
|
}
|
|
@@ -6818,12 +6818,12 @@ b(ws, "withContextAndPages", (e, t) => {
|
|
|
6818
6818
|
return n.set(p.of("Type"), p.of("Catalog")), n.set(p.of("Pages"), t), new ys(n, e);
|
|
6819
6819
|
});
|
|
6820
6820
|
b(ws, "fromMapWithContext", (e, t) => new ys(e, t));
|
|
6821
|
-
const
|
|
6821
|
+
const Oi = class extends W {
|
|
6822
6822
|
constructor(e, t, n = !0) {
|
|
6823
6823
|
super(e, t), b(this, "normalized", !1), b(this, "autoNormalizeCTM"), this.autoNormalizeCTM = n;
|
|
6824
6824
|
}
|
|
6825
6825
|
clone(e) {
|
|
6826
|
-
const t =
|
|
6826
|
+
const t = Oi.fromMapWithContext(
|
|
6827
6827
|
/* @__PURE__ */ new Map(),
|
|
6828
6828
|
e || this.context,
|
|
6829
6829
|
this.autoNormalizeCTM
|
|
@@ -6966,7 +6966,7 @@ const Fi = class extends W {
|
|
|
6966
6966
|
};
|
|
6967
6967
|
}
|
|
6968
6968
|
};
|
|
6969
|
-
let Je =
|
|
6969
|
+
let Je = Oi;
|
|
6970
6970
|
b(Je, "InheritableEntries", [
|
|
6971
6971
|
"Resources",
|
|
6972
6972
|
"MediaBox",
|
|
@@ -6975,9 +6975,9 @@ b(Je, "InheritableEntries", [
|
|
|
6975
6975
|
]);
|
|
6976
6976
|
b(Je, "withContextAndParent", (e, t) => {
|
|
6977
6977
|
const n = /* @__PURE__ */ new Map();
|
|
6978
|
-
return n.set(p.Type, p.Page), n.set(p.Parent, t), n.set(p.Resources, e.obj({})), n.set(p.MediaBox, e.obj([0, 0, 612, 792])), new
|
|
6978
|
+
return n.set(p.Type, p.Page), n.set(p.Parent, t), n.set(p.Resources, e.obj({})), n.set(p.MediaBox, e.obj([0, 0, 612, 792])), new Oi(n, e, !1);
|
|
6979
6979
|
});
|
|
6980
|
-
b(Je, "fromMapWithContext", (e, t, n = !0) => new
|
|
6980
|
+
b(Je, "fromMapWithContext", (e, t, n = !0) => new Oi(e, t, n));
|
|
6981
6981
|
const vs = class {
|
|
6982
6982
|
constructor(e) {
|
|
6983
6983
|
b(this, "bytes"), b(this, "length"), b(this, "idx", 0), b(this, "line", 0), b(this, "column", 0), this.bytes = e, this.length = this.bytes.length;
|
|
@@ -7030,13 +7030,13 @@ me[g.Six] = 1;
|
|
|
7030
7030
|
me[g.Seven] = 1;
|
|
7031
7031
|
me[g.Eight] = 1;
|
|
7032
7032
|
me[g.Nine] = 1;
|
|
7033
|
-
const
|
|
7034
|
-
|
|
7035
|
-
|
|
7036
|
-
|
|
7033
|
+
const Fi = new Uint8Array(256);
|
|
7034
|
+
Fi[g.Period] = 1;
|
|
7035
|
+
Fi[g.Plus] = 1;
|
|
7036
|
+
Fi[g.Minus] = 1;
|
|
7037
7037
|
const xs = new Uint8Array(256);
|
|
7038
7038
|
for (let e = 0, t = 256; e < t; e++)
|
|
7039
|
-
xs[e] = me[e] ||
|
|
7039
|
+
xs[e] = me[e] || Fi[e] ? 1 : 0;
|
|
7040
7040
|
const { Newline: Ro, CarriageReturn: Io } = g;
|
|
7041
7041
|
class Yu {
|
|
7042
7042
|
constructor(t, n = !1) {
|
|
@@ -7389,10 +7389,10 @@ const { Space: Ju, CarriageReturn: on, Newline: an } = g, cn = [
|
|
|
7389
7389
|
return n;
|
|
7390
7390
|
}
|
|
7391
7391
|
};
|
|
7392
|
-
let
|
|
7393
|
-
b(
|
|
7394
|
-
b(
|
|
7395
|
-
const cc = class extends
|
|
7392
|
+
let zi = ks;
|
|
7393
|
+
b(zi, "forBytes", (e, t, n) => new ks(en.of(e), t, n));
|
|
7394
|
+
b(zi, "forByteStream", (e, t, n = !1) => new ks(e, t, n));
|
|
7395
|
+
const cc = class extends zi {
|
|
7396
7396
|
constructor(e, t) {
|
|
7397
7397
|
super(en.fromPDFRawStream(e), e.dict.context), b(this, "alreadyParsed"), b(this, "shouldWaitForTick"), b(this, "firstOffset"), b(this, "objectCount");
|
|
7398
7398
|
const { dict: n } = e;
|
|
@@ -7480,7 +7480,7 @@ const hc = class {
|
|
|
7480
7480
|
};
|
|
7481
7481
|
let dc = hc;
|
|
7482
7482
|
b(dc, "forStream", (e) => new hc(e));
|
|
7483
|
-
const uc = class extends
|
|
7483
|
+
const uc = class extends zi {
|
|
7484
7484
|
constructor(e, t = 1 / 0, n = !1, i = !1) {
|
|
7485
7485
|
super(en.of(e), Gr.create(), i), b(this, "objectsPerTick"), b(this, "throwOnInvalidObject"), b(this, "alreadyParsed", !1), b(this, "parsedObjects", 0), b(this, "shouldWaitForTick", () => (this.parsedObjects += 1, this.parsedObjects % this.objectsPerTick === 0)), this.objectsPerTick = t, this.throwOnInvalidObject = n;
|
|
7486
7486
|
}
|
|
@@ -7611,7 +7611,7 @@ const uc = class extends Ni {
|
|
|
7611
7611
|
return;
|
|
7612
7612
|
this.skipWhitespaceAndComments();
|
|
7613
7613
|
const e = this.parseRawInt();
|
|
7614
|
-
return this.skipWhitespace(), this.matchKeyword(te.eof), this.skipWhitespaceAndComments(), this.matchKeyword(te.eof), this.skipWhitespaceAndComments(),
|
|
7614
|
+
return this.skipWhitespace(), this.matchKeyword(te.eof), this.skipWhitespaceAndComments(), this.matchKeyword(te.eof), this.skipWhitespaceAndComments(), Ti.forLastCrossRefSectionOffset(e);
|
|
7615
7615
|
}
|
|
7616
7616
|
async parseDocumentSection() {
|
|
7617
7617
|
await this.parseIndirectObjects(), this.maybeParseCrossRefSection(), this.maybeParseTrailerDict(), this.maybeParseTrailer(), this.skipJibberish();
|
|
@@ -7638,35 +7638,35 @@ const uc = class extends Ni {
|
|
|
7638
7638
|
};
|
|
7639
7639
|
let fc = uc;
|
|
7640
7640
|
b(fc, "forBytesWithOptions", (e, t, n, i) => new uc(e, t, n, i));
|
|
7641
|
-
const gc = (e) => e instanceof p ? e : p.of(e), G = (e) => e instanceof M ? e : M.of(e),
|
|
7641
|
+
const gc = (e) => e instanceof p ? e : p.of(e), G = (e) => e instanceof M ? e : M.of(e), De = (e) => e instanceof M ? e.asNumber() : e;
|
|
7642
7642
|
var bc = /* @__PURE__ */ ((e) => (e.Degrees = "degrees", e.Radians = "radians", e))(bc || {});
|
|
7643
|
-
const
|
|
7643
|
+
const Te = (e) => (D(e, "degreeAngle", ["number"]), { type: "degrees", angle: e }), { Radians: pc, Degrees: mc } = bc, Qu = (e) => e * Math.PI / 180, ef = (e) => e * 180 / Math.PI, Me = (e) => e.type === pc ? e.angle : e.type === mc ? Qu(e.angle) : vi(`Invalid rotation: ${JSON.stringify(e)}`), tf = (e) => e.type === pc ? ef(e.angle) : e.type === mc ? e.angle : vi(`Invalid rotation: ${JSON.stringify(e)}`), { cos: Oo, sin: Fo, tan: zo } = Math, Ni = (e, t, n, i, r, s) => ie.of(re.ConcatTransformationMatrix, [
|
|
7644
7644
|
G(e),
|
|
7645
7645
|
G(t),
|
|
7646
7646
|
G(n),
|
|
7647
7647
|
G(i),
|
|
7648
7648
|
G(r),
|
|
7649
7649
|
G(s)
|
|
7650
|
-
]), tn = (e, t) =>
|
|
7651
|
-
Oo(
|
|
7652
|
-
Fo(
|
|
7653
|
-
-Fo(
|
|
7654
|
-
Oo(
|
|
7650
|
+
]), tn = (e, t) => Ni(1, 0, 0, 1, e, t), Rn = (e, t) => Ni(e, 0, 0, t, 0, 0), $n = (e) => Ni(
|
|
7651
|
+
Oo(De(e)),
|
|
7652
|
+
Fo(De(e)),
|
|
7653
|
+
-Fo(De(e)),
|
|
7654
|
+
Oo(De(e)),
|
|
7655
7655
|
0,
|
|
7656
7656
|
0
|
|
7657
|
-
), As = (e, t) =>
|
|
7657
|
+
), As = (e, t) => Ni(
|
|
7658
7658
|
1,
|
|
7659
|
-
zo(
|
|
7660
|
-
zo(
|
|
7659
|
+
zo(De(e)),
|
|
7660
|
+
zo(De(t)),
|
|
7661
7661
|
1,
|
|
7662
7662
|
0,
|
|
7663
7663
|
0
|
|
7664
|
-
),
|
|
7664
|
+
), Li = (e, t) => ie.of(re.SetLineDashPattern, [
|
|
7665
7665
|
`[${e.map(G).join(" ")}]`,
|
|
7666
7666
|
G(t)
|
|
7667
7667
|
]);
|
|
7668
7668
|
var pn = /* @__PURE__ */ ((e) => (e[e.Butt = 0] = "Butt", e[e.Round = 1] = "Round", e[e.Projecting = 2] = "Projecting", e))(pn || {});
|
|
7669
|
-
const
|
|
7669
|
+
const ji = (e) => ie.of(re.SetLineCapStyle, [G(e)]), nn = (e) => ie.of(re.SetGraphicsStateParams, [gc(e)]), rt = () => ie.of(re.PushGraphicsState), st = () => ie.of(re.PopGraphicsState), Mi = (e) => ie.of(re.SetLineWidth, [G(e)]), Re = (e, t, n, i, r, s) => ie.of(re.AppendBezierCurve, [
|
|
7670
7670
|
G(e),
|
|
7671
7671
|
G(t),
|
|
7672
7672
|
G(n),
|
|
@@ -7678,7 +7678,7 @@ const Mi = (e) => ie.of(re.SetLineCapStyle, [G(e)]), nn = (e) => ie.of(re.SetGra
|
|
|
7678
7678
|
G(t),
|
|
7679
7679
|
G(n),
|
|
7680
7680
|
G(i)
|
|
7681
|
-
]), qt = () => ie.of(re.ClosePath),
|
|
7681
|
+
]), qt = () => ie.of(re.ClosePath), Dt = (e, t) => ie.of(re.MoveTo, [G(e), G(t)]), Ze = (e, t) => ie.of(re.LineTo, [G(e), G(t)]), Ui = () => ie.of(re.StrokePath), Cs = () => ie.of(re.FillNonZero), Ds = () => ie.of(re.FillNonZeroAndStroke), _c = (e) => ie.of(re.DrawObject, [gc(e)]), nf = (e) => ie.of(re.NonStrokingColorGray, [G(e)]), rf = (e) => ie.of(re.StrokingColorGray, [G(e)]), sf = (e, t, n) => ie.of(re.NonStrokingColorRgb, [
|
|
7682
7682
|
G(e),
|
|
7683
7683
|
G(t),
|
|
7684
7684
|
G(n)
|
|
@@ -7698,7 +7698,7 @@ const Mi = (e) => ie.of(re.SetLineCapStyle, [G(e)]), nn = (e) => ie.of(re.SetGra
|
|
|
7698
7698
|
G(i)
|
|
7699
7699
|
]);
|
|
7700
7700
|
var yc = /* @__PURE__ */ ((e) => (e.Grayscale = "Grayscale", e.RGB = "RGB", e.CMYK = "CMYK", e))(yc || {});
|
|
7701
|
-
const ln = (e, t, n) => (ht(e, "red", 0, 1), ht(t, "green", 0, 1), ht(n, "blue", 0, 1), { type: "RGB", red: e, green: t, blue: n }), { Grayscale: wc, RGB: vc, CMYK: xc } = yc,
|
|
7701
|
+
const ln = (e, t, n) => (ht(e, "red", 0, 1), ht(t, "green", 0, 1), ht(n, "blue", 0, 1), { type: "RGB", red: e, green: t, blue: n }), { Grayscale: wc, RGB: vc, CMYK: xc } = yc, Ts = (e) => e.type === wc ? nf(e.gray) : e.type === vc ? sf(e.red, e.green, e.blue) : e.type === xc ? af(e.cyan, e.magenta, e.yellow, e.key) : vi(`Invalid color: ${JSON.stringify(e)}`), $i = (e) => e.type === wc ? rf(e.gray) : e.type === vc ? of(e.red, e.green, e.blue) : e.type === xc ? cf(e.cyan, e.magenta, e.yellow, e.key) : vi(`Invalid color: ${JSON.stringify(e)}`);
|
|
7702
7702
|
class lf extends Error {
|
|
7703
7703
|
constructor() {
|
|
7704
7704
|
const t = "Input document to `PDFDocument.load` is encrypted. You can use `PDFDocument.load(..., { ignoreEncryption: true })` if you wish to load the document anyways.";
|
|
@@ -7766,10 +7766,10 @@ const No = /* @__PURE__ */ new Map([
|
|
|
7766
7766
|
return t;
|
|
7767
7767
|
}, Lo = {
|
|
7768
7768
|
M(e) {
|
|
7769
|
-
return z = e[0], N = e[1], K = Z = null, mn = z, _n = N,
|
|
7769
|
+
return z = e[0], N = e[1], K = Z = null, mn = z, _n = N, Dt(z, N);
|
|
7770
7770
|
},
|
|
7771
7771
|
m(e) {
|
|
7772
|
-
return z += e[0], N += e[1], K = Z = null, mn = z, _n = N,
|
|
7772
|
+
return z += e[0], N += e[1], K = Z = null, mn = z, _n = N, Dt(z, N);
|
|
7773
7773
|
},
|
|
7774
7774
|
C(e) {
|
|
7775
7775
|
return z = e[4], N = e[5], K = e[2], Z = e[3], Re(e[0], e[1], e[2], e[3], e[4], e[5]);
|
|
@@ -7883,12 +7883,12 @@ const No = /* @__PURE__ */ new Map([
|
|
|
7883
7883
|
C < 0 && (C = 0);
|
|
7884
7884
|
let k = Math.sqrt(C);
|
|
7885
7885
|
s === r && (k = -k);
|
|
7886
|
-
const I = 0.5 * (_ + x) - k * (v - E), P = 0.5 * (E + v) + k * (x - _),
|
|
7887
|
-
let F = Math.atan2(v - P, x - I) -
|
|
7886
|
+
const I = 0.5 * (_ + x) - k * (v - E), P = 0.5 * (E + v) + k * (x - _), T = Math.atan2(E - P, _ - I);
|
|
7887
|
+
let F = Math.atan2(v - P, x - I) - T;
|
|
7888
7888
|
F < 0 && s === 1 ? F += 2 * Math.PI : F > 0 && s === 0 && (F -= 2 * Math.PI);
|
|
7889
7889
|
const B = Math.ceil(Math.abs(F / (Math.PI * 0.5 + 1e-3))), $ = [];
|
|
7890
7890
|
for (let L = 0; L < B; L++) {
|
|
7891
|
-
const O =
|
|
7891
|
+
const O = T + L * F / B, q = T + (L + 1) * F / B;
|
|
7892
7892
|
$[L] = [I, P, O, q, n, i, h, f];
|
|
7893
7893
|
}
|
|
7894
7894
|
return $;
|
|
@@ -7925,14 +7925,14 @@ const No = /* @__PURE__ */ new Map([
|
|
|
7925
7925
|
return [
|
|
7926
7926
|
rt(),
|
|
7927
7927
|
e.graphicsState && nn(e.graphicsState),
|
|
7928
|
-
e.color &&
|
|
7929
|
-
|
|
7930
|
-
|
|
7931
|
-
|
|
7932
|
-
e.lineCap &&
|
|
7933
|
-
|
|
7928
|
+
e.color && $i(e.color),
|
|
7929
|
+
Mi(e.thickness),
|
|
7930
|
+
Li((t = e.dashArray) != null ? t : [], (n = e.dashPhase) != null ? n : 0),
|
|
7931
|
+
Dt(e.start.x, e.start.y),
|
|
7932
|
+
e.lineCap && ji(e.lineCap),
|
|
7933
|
+
Dt(e.start.x, e.start.y),
|
|
7934
7934
|
Ze(e.end.x, e.end.y),
|
|
7935
|
-
|
|
7935
|
+
Ui(),
|
|
7936
7936
|
st()
|
|
7937
7937
|
].filter(Boolean);
|
|
7938
7938
|
}, wf = (e) => {
|
|
@@ -7940,30 +7940,30 @@ const No = /* @__PURE__ */ new Map([
|
|
|
7940
7940
|
return [
|
|
7941
7941
|
rt(),
|
|
7942
7942
|
e.graphicsState && nn(e.graphicsState),
|
|
7943
|
-
e.color &&
|
|
7944
|
-
e.borderColor &&
|
|
7945
|
-
|
|
7946
|
-
e.borderLineCap &&
|
|
7947
|
-
|
|
7943
|
+
e.color && Ts(e.color),
|
|
7944
|
+
e.borderColor && $i(e.borderColor),
|
|
7945
|
+
Mi(e.borderWidth),
|
|
7946
|
+
e.borderLineCap && ji(e.borderLineCap),
|
|
7947
|
+
Li((t = e.borderDashArray) != null ? t : [], (n = e.borderDashPhase) != null ? n : 0),
|
|
7948
7948
|
tn(e.x, e.y),
|
|
7949
7949
|
$n(Me(e.rotate)),
|
|
7950
7950
|
As(Me(e.xSkew), Me(e.ySkew)),
|
|
7951
|
-
|
|
7951
|
+
Dt(0, 0),
|
|
7952
7952
|
Ze(0, e.height),
|
|
7953
7953
|
Ze(e.width, e.height),
|
|
7954
7954
|
Ze(e.width, 0),
|
|
7955
7955
|
qt(),
|
|
7956
|
-
e.color && e.borderWidth ?
|
|
7956
|
+
e.color && e.borderWidth ? Ds() : e.color ? Cs() : e.borderColor ? Ui() : qt(),
|
|
7957
7957
|
st()
|
|
7958
7958
|
].filter(Boolean);
|
|
7959
7959
|
}, wi = 4 * ((Math.sqrt(2) - 1) / 3), vf = (e) => {
|
|
7960
|
-
let t =
|
|
7961
|
-
const i =
|
|
7960
|
+
let t = De(e.x), n = De(e.y);
|
|
7961
|
+
const i = De(e.xScale), r = De(e.yScale);
|
|
7962
7962
|
t -= i, n -= r;
|
|
7963
7963
|
const s = i * wi, o = r * wi, c = t + i * 2, l = n + r * 2, a = t + i, h = n + r;
|
|
7964
7964
|
return [
|
|
7965
7965
|
rt(),
|
|
7966
|
-
|
|
7966
|
+
Dt(t, h),
|
|
7967
7967
|
Re(t, h - o, a - s, n, a, n),
|
|
7968
7968
|
Re(a + s, n, c, h - o, c, h),
|
|
7969
7969
|
Re(c, h + o, a + s, l, a, l),
|
|
@@ -7971,11 +7971,11 @@ const No = /* @__PURE__ */ new Map([
|
|
|
7971
7971
|
st()
|
|
7972
7972
|
];
|
|
7973
7973
|
}, xf = (e) => {
|
|
7974
|
-
const t =
|
|
7974
|
+
const t = De(e.x), n = De(e.y), i = De(e.xScale), r = De(e.yScale), s = -i, o = -r, c = i * wi, l = r * wi, a = s + i * 2, h = o + r * 2, f = s + i, u = o + r;
|
|
7975
7975
|
return [
|
|
7976
7976
|
tn(t, n),
|
|
7977
7977
|
$n(Me(e.rotate)),
|
|
7978
|
-
|
|
7978
|
+
Dt(s, u),
|
|
7979
7979
|
Re(s, u - l, f - c, o, f, o),
|
|
7980
7980
|
Re(f + c, o, a, u - l, a, u),
|
|
7981
7981
|
Re(a, u + l, f + c, h, f, h),
|
|
@@ -7986,11 +7986,11 @@ const No = /* @__PURE__ */ new Map([
|
|
|
7986
7986
|
return [
|
|
7987
7987
|
rt(),
|
|
7988
7988
|
e.graphicsState && nn(e.graphicsState),
|
|
7989
|
-
e.color &&
|
|
7990
|
-
e.borderColor &&
|
|
7991
|
-
|
|
7992
|
-
e.borderLineCap &&
|
|
7993
|
-
|
|
7989
|
+
e.color && Ts(e.color),
|
|
7990
|
+
e.borderColor && $i(e.borderColor),
|
|
7991
|
+
Mi(e.borderWidth),
|
|
7992
|
+
e.borderLineCap && ji(e.borderLineCap),
|
|
7993
|
+
Li((t = e.borderDashArray) != null ? t : [], (n = e.borderDashPhase) != null ? n : 0),
|
|
7994
7994
|
...e.rotate === void 0 ? vf({
|
|
7995
7995
|
x: e.x,
|
|
7996
7996
|
y: e.y,
|
|
@@ -8001,9 +8001,9 @@ const No = /* @__PURE__ */ new Map([
|
|
|
8001
8001
|
y: e.y,
|
|
8002
8002
|
xScale: e.xScale,
|
|
8003
8003
|
yScale: e.yScale,
|
|
8004
|
-
rotate: (i = e.rotate) != null ? i :
|
|
8004
|
+
rotate: (i = e.rotate) != null ? i : Te(0)
|
|
8005
8005
|
}),
|
|
8006
|
-
e.color && e.borderWidth ?
|
|
8006
|
+
e.color && e.borderWidth ? Ds() : e.color ? Cs() : e.borderColor ? Ui() : qt(),
|
|
8007
8007
|
st()
|
|
8008
8008
|
].filter(Boolean);
|
|
8009
8009
|
}, kf = (e, t) => {
|
|
@@ -8012,15 +8012,15 @@ const No = /* @__PURE__ */ new Map([
|
|
|
8012
8012
|
rt(),
|
|
8013
8013
|
t.graphicsState && nn(t.graphicsState),
|
|
8014
8014
|
tn(t.x, t.y),
|
|
8015
|
-
$n(Me((n = t.rotate) != null ? n :
|
|
8015
|
+
$n(Me((n = t.rotate) != null ? n : Te(0))),
|
|
8016
8016
|
t.scale ? Rn(t.scale, -t.scale) : Rn(1, -1),
|
|
8017
|
-
t.color &&
|
|
8018
|
-
t.borderColor &&
|
|
8019
|
-
t.borderWidth &&
|
|
8020
|
-
t.borderLineCap &&
|
|
8021
|
-
|
|
8017
|
+
t.color && Ts(t.color),
|
|
8018
|
+
t.borderColor && $i(t.borderColor),
|
|
8019
|
+
t.borderWidth && Mi(t.borderWidth),
|
|
8020
|
+
t.borderLineCap && ji(t.borderLineCap),
|
|
8021
|
+
Li((i = t.borderDashArray) != null ? i : [], (r = t.borderDashPhase) != null ? r : 0),
|
|
8022
8022
|
...pf(e),
|
|
8023
|
-
t.color && t.borderWidth ?
|
|
8023
|
+
t.color && t.borderWidth ? Ds() : t.color ? Cs() : t.borderColor ? Ui() : qt(),
|
|
8024
8024
|
st()
|
|
8025
8025
|
].filter(Boolean);
|
|
8026
8026
|
}, Af = {
|
|
@@ -8078,10 +8078,10 @@ const No = /* @__PURE__ */ new Map([
|
|
|
8078
8078
|
var _t = /* @__PURE__ */ ((e) => (e.Normal = "Normal", e.Multiply = "Multiply", e.Screen = "Screen", e.Overlay = "Overlay", e.Darken = "Darken", e.Lighten = "Lighten", e.ColorDodge = "ColorDodge", e.ColorBurn = "ColorBurn", e.HardLight = "HardLight", e.SoftLight = "SoftLight", e.Difference = "Difference", e.Exclusion = "Exclusion", e))(_t || {});
|
|
8079
8079
|
const Sc = class {
|
|
8080
8080
|
constructor(e, t, n) {
|
|
8081
|
-
b(this, "ref"), b(this, "doc"), b(this, "width"), b(this, "height"), b(this, "alreadyEmbedded", !1), b(this, "embedder"),
|
|
8081
|
+
b(this, "ref"), b(this, "doc"), b(this, "width"), b(this, "height"), b(this, "alreadyEmbedded", !1), b(this, "embedder"), D(e, "ref", [[oe, "PDFRef"]]), D(t, "doc", [[mt, "PDFDocument"]]), D(n, "embedder", [[qr, "PDFPageEmbedder"]]), this.ref = e, this.doc = t, this.width = n.width, this.height = n.height, this.embedder = n;
|
|
8082
8082
|
}
|
|
8083
8083
|
scale(e) {
|
|
8084
|
-
return
|
|
8084
|
+
return D(e, "factor", ["number"]), { width: this.width * e, height: this.height * e };
|
|
8085
8085
|
}
|
|
8086
8086
|
size() {
|
|
8087
8087
|
return this.scale(1);
|
|
@@ -8094,22 +8094,22 @@ let kc = Sc;
|
|
|
8094
8094
|
b(kc, "of", (e, t, n) => new Sc(e, t, n));
|
|
8095
8095
|
const Ac = class {
|
|
8096
8096
|
constructor(e, t, n) {
|
|
8097
|
-
b(this, "ref"), b(this, "doc"), b(this, "name"), b(this, "modified", !0), b(this, "embedder"),
|
|
8097
|
+
b(this, "ref"), b(this, "doc"), b(this, "name"), b(this, "modified", !0), b(this, "embedder"), D(e, "ref", [[oe, "PDFRef"]]), D(t, "doc", [[mt, "PDFDocument"]]), this.ref = e, this.doc = t, this.name = n.fontName, this.embedder = n;
|
|
8098
8098
|
}
|
|
8099
8099
|
encodeText(e) {
|
|
8100
|
-
return
|
|
8100
|
+
return D(e, "text", ["string"]), this.modified = !0, this.embedder.encodeText(e);
|
|
8101
8101
|
}
|
|
8102
8102
|
widthOfTextAtSize(e, t) {
|
|
8103
|
-
return
|
|
8103
|
+
return D(e, "text", ["string"]), D(t, "size", ["number"]), this.embedder.widthOfTextAtSize(e, t);
|
|
8104
8104
|
}
|
|
8105
8105
|
heightAtSize(e, t) {
|
|
8106
8106
|
var n;
|
|
8107
|
-
return
|
|
8107
|
+
return D(e, "size", ["number"]), j(t?.descender, "options.descender", ["boolean"]), this.embedder.heightOfFontAtSize(e, {
|
|
8108
8108
|
descender: (n = t?.descender) != null ? n : !0
|
|
8109
8109
|
});
|
|
8110
8110
|
}
|
|
8111
8111
|
sizeAtHeight(e) {
|
|
8112
|
-
return
|
|
8112
|
+
return D(e, "height", ["number"]), this.embedder.sizeOfFontAtHeight(e);
|
|
8113
8113
|
}
|
|
8114
8114
|
getCharacterSet() {
|
|
8115
8115
|
return this.embedder.font.characterSet;
|
|
@@ -8120,18 +8120,18 @@ const Ac = class {
|
|
|
8120
8120
|
};
|
|
8121
8121
|
let Cc = Ac;
|
|
8122
8122
|
b(Cc, "of", (e, t, n) => new Ac(e, t, n));
|
|
8123
|
-
const
|
|
8123
|
+
const Dc = class {
|
|
8124
8124
|
constructor(e, t, n) {
|
|
8125
|
-
b(this, "ref"), b(this, "doc"), b(this, "width"), b(this, "height"), b(this, "embedder"), b(this, "embedTask"),
|
|
8125
|
+
b(this, "ref"), b(this, "doc"), b(this, "width"), b(this, "height"), b(this, "embedder"), b(this, "embedTask"), D(e, "ref", [[oe, "PDFRef"]]), D(t, "doc", [[mt, "PDFDocument"]]), D(n, "embedder", [
|
|
8126
8126
|
[Qr, "JpegEmbedder"],
|
|
8127
8127
|
[es, "PngEmbedder"]
|
|
8128
8128
|
]), this.ref = e, this.doc = t, this.width = n.width, this.height = n.height, this.embedder = n;
|
|
8129
8129
|
}
|
|
8130
8130
|
scale(e) {
|
|
8131
|
-
return
|
|
8131
|
+
return D(e, "factor", ["number"]), { width: this.width * e, height: this.height * e };
|
|
8132
8132
|
}
|
|
8133
8133
|
scaleToFit(e, t) {
|
|
8134
|
-
|
|
8134
|
+
D(e, "width", ["number"]), D(t, "height", ["number"]);
|
|
8135
8135
|
const n = e / this.width, i = t / this.height, r = Math.min(n, i);
|
|
8136
8136
|
return this.scale(r);
|
|
8137
8137
|
}
|
|
@@ -8148,11 +8148,11 @@ const Tc = class {
|
|
|
8148
8148
|
}
|
|
8149
8149
|
}
|
|
8150
8150
|
};
|
|
8151
|
-
let
|
|
8152
|
-
b(
|
|
8151
|
+
let Tc = Dc;
|
|
8152
|
+
b(Tc, "of", (e, t, n) => new Dc(e, t, n));
|
|
8153
8153
|
const Es = class {
|
|
8154
8154
|
constructor(e, t, n) {
|
|
8155
|
-
b(this, "node"), b(this, "ref"), b(this, "doc"), b(this, "fontKey"), b(this, "font"), b(this, "fontSize", 24), b(this, "fontColor", ln(0, 0, 0)), b(this, "lineHeight", 24), b(this, "x", 0), b(this, "y", 0), b(this, "contentStream"), b(this, "contentStreamRef"),
|
|
8155
|
+
b(this, "node"), b(this, "ref"), b(this, "doc"), b(this, "fontKey"), b(this, "font"), b(this, "fontSize", 24), b(this, "fontColor", ln(0, 0, 0)), b(this, "lineHeight", 24), b(this, "x", 0), b(this, "y", 0), b(this, "contentStream"), b(this, "contentStreamRef"), D(e, "leafNode", [[Je, "PDFPageLeaf"]]), D(t, "ref", [[oe, "PDFRef"]]), D(n, "doc", [[mt, "PDFDocument"]]), this.node = e, this.ref = t, this.doc = n;
|
|
8156
8156
|
}
|
|
8157
8157
|
setRotation(e) {
|
|
8158
8158
|
const t = tf(e);
|
|
@@ -8160,43 +8160,43 @@ const Es = class {
|
|
|
8160
8160
|
}
|
|
8161
8161
|
getRotation() {
|
|
8162
8162
|
const e = this.node.Rotate();
|
|
8163
|
-
return
|
|
8163
|
+
return Te(e ? e.asNumber() : 0);
|
|
8164
8164
|
}
|
|
8165
8165
|
setSize(e, t) {
|
|
8166
|
-
|
|
8166
|
+
D(e, "width", ["number"]), D(t, "height", ["number"]);
|
|
8167
8167
|
const n = this.getMediaBox();
|
|
8168
8168
|
this.setMediaBox(n.x, n.y, e, t);
|
|
8169
8169
|
const i = this.getCropBox(), r = this.getBleedBox(), s = this.getTrimBox(), o = this.getArtBox(), c = this.node.CropBox(), l = this.node.BleedBox(), a = this.node.TrimBox(), h = this.node.ArtBox();
|
|
8170
8170
|
c && Yn(i, n) && this.setCropBox(n.x, n.y, e, t), l && Yn(r, n) && this.setBleedBox(n.x, n.y, e, t), a && Yn(s, n) && this.setTrimBox(n.x, n.y, e, t), h && Yn(o, n) && this.setArtBox(n.x, n.y, e, t);
|
|
8171
8171
|
}
|
|
8172
8172
|
setWidth(e) {
|
|
8173
|
-
|
|
8173
|
+
D(e, "width", ["number"]), this.setSize(e, this.getSize().height);
|
|
8174
8174
|
}
|
|
8175
8175
|
setHeight(e) {
|
|
8176
|
-
|
|
8176
|
+
D(e, "height", ["number"]), this.setSize(this.getSize().width, e);
|
|
8177
8177
|
}
|
|
8178
8178
|
setMediaBox(e, t, n, i) {
|
|
8179
|
-
|
|
8179
|
+
D(e, "x", ["number"]), D(t, "y", ["number"]), D(n, "width", ["number"]), D(i, "height", ["number"]);
|
|
8180
8180
|
const r = this.doc.context.obj([e, t, e + n, t + i]);
|
|
8181
8181
|
this.node.set(p.MediaBox, r);
|
|
8182
8182
|
}
|
|
8183
8183
|
setCropBox(e, t, n, i) {
|
|
8184
|
-
|
|
8184
|
+
D(e, "x", ["number"]), D(t, "y", ["number"]), D(n, "width", ["number"]), D(i, "height", ["number"]);
|
|
8185
8185
|
const r = this.doc.context.obj([e, t, e + n, t + i]);
|
|
8186
8186
|
this.node.set(p.CropBox, r);
|
|
8187
8187
|
}
|
|
8188
8188
|
setBleedBox(e, t, n, i) {
|
|
8189
|
-
|
|
8189
|
+
D(e, "x", ["number"]), D(t, "y", ["number"]), D(n, "width", ["number"]), D(i, "height", ["number"]);
|
|
8190
8190
|
const r = this.doc.context.obj([e, t, e + n, t + i]);
|
|
8191
8191
|
this.node.set(p.BleedBox, r);
|
|
8192
8192
|
}
|
|
8193
8193
|
setTrimBox(e, t, n, i) {
|
|
8194
|
-
|
|
8194
|
+
D(e, "x", ["number"]), D(t, "y", ["number"]), D(n, "width", ["number"]), D(i, "height", ["number"]);
|
|
8195
8195
|
const r = this.doc.context.obj([e, t, e + n, t + i]);
|
|
8196
8196
|
this.node.set(p.TrimBox, r);
|
|
8197
8197
|
}
|
|
8198
8198
|
setArtBox(e, t, n, i) {
|
|
8199
|
-
|
|
8199
|
+
D(e, "x", ["number"]), D(t, "y", ["number"]), D(n, "width", ["number"]), D(i, "height", ["number"]);
|
|
8200
8200
|
const r = this.doc.context.obj([e, t, e + n, t + i]);
|
|
8201
8201
|
this.node.set(p.ArtBox, r);
|
|
8202
8202
|
}
|
|
@@ -8234,7 +8234,7 @@ const Es = class {
|
|
|
8234
8234
|
return (e = t?.asRectangle()) != null ? e : this.getCropBox();
|
|
8235
8235
|
}
|
|
8236
8236
|
translateContent(e, t) {
|
|
8237
|
-
|
|
8237
|
+
D(e, "x", ["number"]), D(t, "y", ["number"]), this.node.normalize(), this.getContentStream();
|
|
8238
8238
|
const n = this.createContentStream(
|
|
8239
8239
|
rt(),
|
|
8240
8240
|
tn(e, t)
|
|
@@ -8242,15 +8242,15 @@ const Es = class {
|
|
|
8242
8242
|
this.node.wrapContentStreams(i, s);
|
|
8243
8243
|
}
|
|
8244
8244
|
scale(e, t) {
|
|
8245
|
-
|
|
8245
|
+
D(e, "x", ["number"]), D(t, "y", ["number"]), this.setSize(this.getWidth() * e, this.getHeight() * t), this.scaleContent(e, t), this.scaleAnnotations(e, t);
|
|
8246
8246
|
}
|
|
8247
8247
|
scaleContent(e, t) {
|
|
8248
|
-
|
|
8248
|
+
D(e, "x", ["number"]), D(t, "y", ["number"]), this.node.normalize(), this.getContentStream();
|
|
8249
8249
|
const n = this.createContentStream(rt(), Rn(e, t)), i = this.doc.context.register(n), r = this.createContentStream(st()), s = this.doc.context.register(r);
|
|
8250
8250
|
this.node.wrapContentStreams(i, s);
|
|
8251
8251
|
}
|
|
8252
8252
|
scaleAnnotations(e, t) {
|
|
8253
|
-
|
|
8253
|
+
D(e, "x", ["number"]), D(t, "y", ["number"]);
|
|
8254
8254
|
const n = this.node.Annots();
|
|
8255
8255
|
if (!!n)
|
|
8256
8256
|
for (let i = 0; i < n.size(); i++) {
|
|
@@ -8262,16 +8262,16 @@ const Es = class {
|
|
|
8262
8262
|
this.getContentStream(!1), this.x = 0, this.y = 0;
|
|
8263
8263
|
}
|
|
8264
8264
|
setFont(e) {
|
|
8265
|
-
|
|
8265
|
+
D(e, "font", [[Cc, "PDFFont"]]), this.font = e, this.fontKey = this.node.newFontDictionary(this.font.name, this.font.ref);
|
|
8266
8266
|
}
|
|
8267
8267
|
setFontSize(e) {
|
|
8268
|
-
|
|
8268
|
+
D(e, "fontSize", ["number"]), this.fontSize = e;
|
|
8269
8269
|
}
|
|
8270
8270
|
setFontColor(e) {
|
|
8271
|
-
|
|
8271
|
+
D(e, "fontColor", [[Object, "Color"]]), this.fontColor = e;
|
|
8272
8272
|
}
|
|
8273
8273
|
setLineHeight(e) {
|
|
8274
|
-
|
|
8274
|
+
D(e, "lineHeight", ["number"]), this.lineHeight = e;
|
|
8275
8275
|
}
|
|
8276
8276
|
getPosition() {
|
|
8277
8277
|
return { x: this.x, y: this.y };
|
|
@@ -8283,26 +8283,26 @@ const Es = class {
|
|
|
8283
8283
|
return this.y;
|
|
8284
8284
|
}
|
|
8285
8285
|
moveTo(e, t) {
|
|
8286
|
-
|
|
8286
|
+
D(e, "x", ["number"]), D(t, "y", ["number"]), this.x = e, this.y = t;
|
|
8287
8287
|
}
|
|
8288
8288
|
moveDown(e) {
|
|
8289
|
-
|
|
8289
|
+
D(e, "yDecrease", ["number"]), this.y -= e;
|
|
8290
8290
|
}
|
|
8291
8291
|
moveUp(e) {
|
|
8292
|
-
|
|
8292
|
+
D(e, "yIncrease", ["number"]), this.y += e;
|
|
8293
8293
|
}
|
|
8294
8294
|
moveLeft(e) {
|
|
8295
|
-
|
|
8295
|
+
D(e, "xDecrease", ["number"]), this.x -= e;
|
|
8296
8296
|
}
|
|
8297
8297
|
moveRight(e) {
|
|
8298
|
-
|
|
8298
|
+
D(e, "xIncrease", ["number"]), this.x += e;
|
|
8299
8299
|
}
|
|
8300
8300
|
pushOperators(...e) {
|
|
8301
8301
|
Qo(e, "operator", [[ie, "PDFOperator"]]), this.getContentStream().push(...e);
|
|
8302
8302
|
}
|
|
8303
8303
|
drawImage(e, t = {}) {
|
|
8304
8304
|
var n, i, r, s, o, c, l;
|
|
8305
|
-
|
|
8305
|
+
D(e, "image", [[Tc, "PDFImage"]]), j(t.x, "options.x", ["number"]), j(t.y, "options.y", ["number"]), j(t.width, "options.width", ["number"]), j(t.height, "options.height", ["number"]), j(t.rotate, "options.rotate", [[Object, "Rotation"]]), j(t.xSkew, "options.xSkew", [[Object, "Rotation"]]), j(t.ySkew, "options.ySkew", [[Object, "Rotation"]]), Qe(t.opacity, "opacity.opacity", 0, 1), We(t.blendMode, "options.blendMode", _t);
|
|
8306
8306
|
const a = this.node.newXObject("Image", e.ref), h = this.maybeEmbedGraphicsState({
|
|
8307
8307
|
opacity: t.opacity,
|
|
8308
8308
|
blendMode: t.blendMode
|
|
@@ -8313,16 +8313,16 @@ const Es = class {
|
|
|
8313
8313
|
y: (i = t.y) != null ? i : this.y,
|
|
8314
8314
|
width: (r = t.width) != null ? r : e.size().width,
|
|
8315
8315
|
height: (s = t.height) != null ? s : e.size().height,
|
|
8316
|
-
rotate: (o = t.rotate) != null ? o :
|
|
8317
|
-
xSkew: (c = t.xSkew) != null ? c :
|
|
8318
|
-
ySkew: (l = t.ySkew) != null ? l :
|
|
8316
|
+
rotate: (o = t.rotate) != null ? o : Te(0),
|
|
8317
|
+
xSkew: (c = t.xSkew) != null ? c : Te(0),
|
|
8318
|
+
ySkew: (l = t.ySkew) != null ? l : Te(0),
|
|
8319
8319
|
graphicsState: h
|
|
8320
8320
|
})
|
|
8321
8321
|
);
|
|
8322
8322
|
}
|
|
8323
8323
|
drawPage(e, t = {}) {
|
|
8324
8324
|
var n, i, r, s, o;
|
|
8325
|
-
|
|
8325
|
+
D(e, "embeddedPage", [
|
|
8326
8326
|
[kc, "PDFEmbeddedPage"]
|
|
8327
8327
|
]), j(t.x, "options.x", ["number"]), j(t.y, "options.y", ["number"]), j(t.xScale, "options.xScale", ["number"]), j(t.yScale, "options.yScale", ["number"]), j(t.width, "options.width", ["number"]), j(t.height, "options.height", ["number"]), j(t.rotate, "options.rotate", [[Object, "Rotation"]]), j(t.xSkew, "options.xSkew", [[Object, "Rotation"]]), j(t.ySkew, "options.ySkew", [[Object, "Rotation"]]), Qe(t.opacity, "opacity.opacity", 0, 1), We(t.blendMode, "options.blendMode", _t);
|
|
8328
8328
|
const c = this.node.newXObject(
|
|
@@ -8338,16 +8338,16 @@ const Es = class {
|
|
|
8338
8338
|
y: (i = t.y) != null ? i : this.y,
|
|
8339
8339
|
xScale: a,
|
|
8340
8340
|
yScale: h,
|
|
8341
|
-
rotate: (r = t.rotate) != null ? r :
|
|
8342
|
-
xSkew: (s = t.xSkew) != null ? s :
|
|
8343
|
-
ySkew: (o = t.ySkew) != null ? o :
|
|
8341
|
+
rotate: (r = t.rotate) != null ? r : Te(0),
|
|
8342
|
+
xSkew: (s = t.xSkew) != null ? s : Te(0),
|
|
8343
|
+
ySkew: (o = t.ySkew) != null ? o : Te(0),
|
|
8344
8344
|
graphicsState: l
|
|
8345
8345
|
})
|
|
8346
8346
|
);
|
|
8347
8347
|
}
|
|
8348
8348
|
drawSvgPath(e, t = {}) {
|
|
8349
8349
|
var n, i, r, s, o, c, l, a, h;
|
|
8350
|
-
|
|
8350
|
+
D(e, "path", ["string"]), j(t.x, "options.x", ["number"]), j(t.y, "options.y", ["number"]), j(t.scale, "options.scale", ["number"]), j(t.rotate, "options.rotate", [[Object, "Rotation"]]), j(t.borderWidth, "options.borderWidth", ["number"]), j(t.color, "options.color", [[Object, "Color"]]), Qe(t.opacity, "opacity.opacity", 0, 1), j(t.borderColor, "options.borderColor", [
|
|
8351
8351
|
[Object, "Color"]
|
|
8352
8352
|
]), j(t.borderDashArray, "options.borderDashArray", [
|
|
8353
8353
|
Array
|
|
@@ -8373,7 +8373,7 @@ const Es = class {
|
|
|
8373
8373
|
x: (n = t.x) != null ? n : this.x,
|
|
8374
8374
|
y: (i = t.y) != null ? i : this.y,
|
|
8375
8375
|
scale: t.scale,
|
|
8376
|
-
rotate: (r = t.rotate) != null ? r :
|
|
8376
|
+
rotate: (r = t.rotate) != null ? r : Te(0),
|
|
8377
8377
|
color: (s = t.color) != null ? s : void 0,
|
|
8378
8378
|
borderColor: (o = t.borderColor) != null ? o : void 0,
|
|
8379
8379
|
borderWidth: (c = t.borderWidth) != null ? c : 0,
|
|
@@ -8386,11 +8386,11 @@ const Es = class {
|
|
|
8386
8386
|
}
|
|
8387
8387
|
drawLine(e) {
|
|
8388
8388
|
var t, n, i, r, s;
|
|
8389
|
-
|
|
8389
|
+
D(e.start, "options.start", [
|
|
8390
8390
|
[Object, "{ x: number, y: number }"]
|
|
8391
|
-
]),
|
|
8391
|
+
]), D(e.end, "options.end", [
|
|
8392
8392
|
[Object, "{ x: number, y: number }"]
|
|
8393
|
-
]),
|
|
8393
|
+
]), D(e.start.x, "options.start.x", ["number"]), D(e.start.y, "options.start.y", ["number"]), D(e.end.x, "options.end.x", ["number"]), D(e.end.y, "options.end.y", ["number"]), j(e.thickness, "options.thickness", ["number"]), j(e.color, "options.color", [[Object, "Color"]]), j(e.dashArray, "options.dashArray", [Array]), j(e.dashPhase, "options.dashPhase", ["number"]), We(e.lineCap, "options.lineCap", pn), Qe(e.opacity, "opacity.opacity", 0, 1), We(e.blendMode, "options.blendMode", _t);
|
|
8394
8394
|
const o = this.maybeEmbedGraphicsState({
|
|
8395
8395
|
borderOpacity: e.opacity,
|
|
8396
8396
|
blendMode: e.blendMode
|
|
@@ -8437,9 +8437,9 @@ const Es = class {
|
|
|
8437
8437
|
y: (n = e.y) != null ? n : this.y,
|
|
8438
8438
|
width: (i = e.width) != null ? i : 150,
|
|
8439
8439
|
height: (r = e.height) != null ? r : 100,
|
|
8440
|
-
rotate: (s = e.rotate) != null ? s :
|
|
8441
|
-
xSkew: (o = e.xSkew) != null ? o :
|
|
8442
|
-
ySkew: (c = e.ySkew) != null ? c :
|
|
8440
|
+
rotate: (s = e.rotate) != null ? s : Te(0),
|
|
8441
|
+
xSkew: (o = e.xSkew) != null ? o : Te(0),
|
|
8442
|
+
ySkew: (c = e.ySkew) != null ? c : Te(0),
|
|
8443
8443
|
borderWidth: (l = e.borderWidth) != null ? l : 0,
|
|
8444
8444
|
color: (a = e.color) != null ? a : void 0,
|
|
8445
8445
|
borderColor: (h = e.borderColor) != null ? h : void 0,
|
|
@@ -8537,7 +8537,7 @@ const Es = class {
|
|
|
8537
8537
|
let Lt = Es;
|
|
8538
8538
|
b(Lt, "of", (e, t, n) => new Es(e, t, n));
|
|
8539
8539
|
b(Lt, "create", (e) => {
|
|
8540
|
-
|
|
8540
|
+
D(e, "doc", [[mt, "PDFDocument"]]);
|
|
8541
8541
|
const t = oe.of(-1), n = Je.withContextAndParent(e.context, t), i = e.context.register(n);
|
|
8542
8542
|
return new Es(n, i, e);
|
|
8543
8543
|
});
|
|
@@ -8589,7 +8589,7 @@ class mt {
|
|
|
8589
8589
|
o || (o = Lt.of(r, s, this), this.pageMap.set(r, o)), i.push(o);
|
|
8590
8590
|
}
|
|
8591
8591
|
}), i;
|
|
8592
|
-
}),
|
|
8592
|
+
}), D(t, "context", [[Gr, "PDFContext"]]), D(n, "ignoreEncryption", ["boolean"]), this.context = t, this.catalog = t.lookup(t.trailerInfo.Root), this.isEncrypted = !!t.lookup(t.trailerInfo.Encrypt), this.pageCache = Mt.populatedBy(this.computePages), this.pageMap = /* @__PURE__ */ new Map(), this.fonts = [], this.images = [], this.embeddedPages = [], this.embeddedFiles = [], this.javaScripts = [], !n && this.isEncrypted)
|
|
8593
8593
|
throw new lf();
|
|
8594
8594
|
}
|
|
8595
8595
|
static async load(t, n = {}) {
|
|
@@ -8600,7 +8600,7 @@ class mt {
|
|
|
8600
8600
|
updateMetadata: o = !0,
|
|
8601
8601
|
capNumbers: c = !1
|
|
8602
8602
|
} = n;
|
|
8603
|
-
|
|
8603
|
+
D(t, "pdf", ["string", Uint8Array, ArrayBuffer]), D(i, "ignoreEncryption", ["boolean"]), D(r, "parseSpeed", ["number"]), D(s, "throwOnInvalidObject", ["boolean"]);
|
|
8604
8604
|
const l = Jc(t), a = await fc.forBytesWithOptions(
|
|
8605
8605
|
l,
|
|
8606
8606
|
r,
|
|
@@ -8632,11 +8632,11 @@ class mt {
|
|
|
8632
8632
|
ht(t, "index", 0, n - 1), this.catalog.removeLeafNode(t), this.pageCount = n - 1;
|
|
8633
8633
|
}
|
|
8634
8634
|
addPage(t) {
|
|
8635
|
-
return
|
|
8635
|
+
return D(t, "page", ["undefined", [Lt, "PDFPage"], Array]), this.insertPage(this.getPageCount(), t);
|
|
8636
8636
|
}
|
|
8637
8637
|
insertPage(t, n) {
|
|
8638
8638
|
const i = this.getPageCount();
|
|
8639
|
-
if (ht(t, "index", 0, i),
|
|
8639
|
+
if (ht(t, "index", 0, i), D(n, "page", ["undefined", [Lt, "PDFPage"], Array]), !n || Array.isArray(n)) {
|
|
8640
8640
|
const s = Array.isArray(n) ? n : Af.A4;
|
|
8641
8641
|
n = Lt.create(this), n.setSize(...s);
|
|
8642
8642
|
} else if (n.doc !== this)
|
|
@@ -8645,7 +8645,7 @@ class mt {
|
|
|
8645
8645
|
return n.node.setParent(r), this.pageMap.set(n.node, n), this.pageCache.invalidate(), this.pageCount = i + 1, n;
|
|
8646
8646
|
}
|
|
8647
8647
|
addJavaScript(t, n) {
|
|
8648
|
-
|
|
8648
|
+
D(t, "name", ["string"]), D(n, "script", ["string"]);
|
|
8649
8649
|
const i = Bs.for(n, t), r = this.context.nextRef(), s = Bc.of(r, this, i);
|
|
8650
8650
|
this.javaScripts.push(s);
|
|
8651
8651
|
}
|
|
@@ -8659,11 +8659,11 @@ class mt {
|
|
|
8659
8659
|
objectsPerTick: r = 50,
|
|
8660
8660
|
updateFieldAppearances: s = !0
|
|
8661
8661
|
} = t;
|
|
8662
|
-
return
|
|
8662
|
+
return D(n, "useObjectStreams", ["boolean"]), D(i, "addDefaultPage", ["boolean"]), D(r, "objectsPerTick", ["number"]), D(s, "updateFieldAppearances", ["boolean"]), i && this.getPageCount() === 0 && this.addPage(), await this.flush(), (n ? qa : Vr).forContext(this.context, r).serializeToBuffer();
|
|
8663
8663
|
}
|
|
8664
8664
|
async saveAsBase64(t = {}) {
|
|
8665
8665
|
const { dataUri: n = !1, ...i } = t;
|
|
8666
|
-
|
|
8666
|
+
D(n, "dataUri", ["boolean"]);
|
|
8667
8667
|
const r = await this.save(i), s = Hc(r);
|
|
8668
8668
|
return n ? `data:application/pdf;base64,${s}` : s;
|
|
8669
8669
|
}
|
|
@@ -8765,10 +8765,10 @@ var jt;
|
|
|
8765
8765
|
(function(e) {
|
|
8766
8766
|
e.textSelection = "vpv:annotation:textSelection", e.freeText = "vpv:annotation:freeText", e.signature = "vpv:annotation:signature", e.image = "vpv:annotation:image", e.highlight = "vpv:annotation:highlight", e.underline = "vpv:annotation:underline", e.strikeout = "vpv:annotation:strikeout";
|
|
8767
8767
|
})(jt || (jt = {}));
|
|
8768
|
-
var
|
|
8768
|
+
var vr;
|
|
8769
8769
|
(function(e) {
|
|
8770
8770
|
e.AnnotationCreated = "vpv:annotation:created", e.AnnotationUpdated = "vpv:annotation:updated", e.AnnotationDeleted = "vpv:annotation:deleted", e.AnnotationMounted = "vpv:annotation:mounted", e.Rotate = "vpv:rotate";
|
|
8771
|
-
})(
|
|
8771
|
+
})(vr || (vr = {}));
|
|
8772
8772
|
var Mo;
|
|
8773
8773
|
(function(e) {
|
|
8774
8774
|
e[e.Text = 1] = "Text", e[e.Link = 2] = "Link", e[e.FreeText = 3] = "FreeText", e[e.Line = 4] = "Line", e[e.Square = 5] = "Square", e[e.Circle = 6] = "Circle", e[e.Polygon = 7] = "Polygon", e[e.Polyline = 8] = "Polyline", e[e.Highlight = 9] = "Highlight", e[e.Underline = 10] = "Underline", e[e.Squiggly = 11] = "Squiggly", e[e.StrikeOut = 12] = "StrikeOut", e[e.Stamp = 13] = "Stamp", e[e.Caret = 14] = "Caret", e[e.Ink = 15] = "Ink", e[e.Popup = 16] = "Popup", e[e.FileAttachment = 17] = "FileAttachment", e[e.Sound = 18] = "Sound", e[e.Movie = 19] = "Movie", e[e.Widget = 20] = "Widget", e[e.Screen = 21] = "Screen", e[e.PrinterMark = 22] = "PrinterMark", e[e.TrapNet = 23] = "TrapNet", e[e.Watermark = 24] = "Watermark", e[e.ThreeD = 25] = "ThreeD", e[e.Redact = 26] = "Redact";
|
|
@@ -8777,9 +8777,9 @@ var Uo;
|
|
|
8777
8777
|
(function(e) {
|
|
8778
8778
|
e[e.INVISIBLE = 1] = "INVISIBLE", e[e.HIDDEN = 2] = "HIDDEN", e[e.PRINT = 4] = "PRINT", e[e.NOZOOM = 8] = "NOZOOM", e[e.NOROTATE = 16] = "NOROTATE", e[e.NOVIEW = 32] = "NOVIEW", e[e.READONLY = 64] = "READONLY", e[e.LOCKED = 128] = "LOCKED", e[e.TOGGLENOVIEW = 256] = "TOGGLENOVIEW", e[e.LOCKEDCONTENTS = 512] = "LOCKEDCONTENTS";
|
|
8779
8779
|
})(Uo || (Uo = {}));
|
|
8780
|
-
const
|
|
8780
|
+
const Df = {
|
|
8781
8781
|
ANNOTATIONS: "annotations"
|
|
8782
|
-
}, Hn = Symbol("VPV Shared UIs"), Pc = Symbol("VPV Current Localization"), hn =
|
|
8782
|
+
}, Hn = Symbol("VPV Shared UIs"), Pc = Symbol("VPV Current Localization"), hn = vr, Rc = {
|
|
8783
8783
|
Black: "#000000",
|
|
8784
8784
|
DarkGray: "#444444",
|
|
8785
8785
|
Gray: "#696969",
|
|
@@ -8802,7 +8802,7 @@ const Tf = {
|
|
|
8802
8802
|
Yellow: "#FCE244",
|
|
8803
8803
|
Green: "#A0F751",
|
|
8804
8804
|
...Rc
|
|
8805
|
-
},
|
|
8805
|
+
}, Tf = {
|
|
8806
8806
|
[Fe.Purple]: "Purple",
|
|
8807
8807
|
[Fe.Cyan]: "Cyan",
|
|
8808
8808
|
[Fe.Red]: "Red",
|
|
@@ -8991,7 +8991,12 @@ const Tf = {
|
|
|
8991
8991
|
], 16));
|
|
8992
8992
|
}
|
|
8993
8993
|
}), Wn = /* @__PURE__ */ Ue({
|
|
8994
|
+
inheritAttrs: !1,
|
|
8994
8995
|
__name: "AppButton",
|
|
8996
|
+
props: {
|
|
8997
|
+
ariaLabel: {},
|
|
8998
|
+
ariaDisabled: { type: Boolean }
|
|
8999
|
+
},
|
|
8995
9000
|
setup(e) {
|
|
8996
9001
|
const t = In(Hn), n = fe(() => t?.AppButton);
|
|
8997
9002
|
return (i, r) => n.value ? (ee(), ae(Se(n.value), xt(ve({ key: 0 }, i.$attrs)), {
|
|
@@ -9025,7 +9030,7 @@ const Ps = (e, t) => {
|
|
|
9025
9030
|
for (const [i, r] of t)
|
|
9026
9031
|
n[i] = r;
|
|
9027
9032
|
return n;
|
|
9028
|
-
}, bt = /* @__PURE__ */ Ps(Of, [["__scopeId", "data-v-
|
|
9033
|
+
}, bt = /* @__PURE__ */ Ps(Of, [["__scopeId", "data-v-9d5f0033"]]), Kn = () => {
|
|
9029
9034
|
const e = In(
|
|
9030
9035
|
Pc,
|
|
9031
9036
|
fe(() => ({}))
|
|
@@ -9070,25 +9075,28 @@ const Ps = (e, t) => {
|
|
|
9070
9075
|
}));
|
|
9071
9076
|
}
|
|
9072
9077
|
});
|
|
9073
|
-
const zf = /* @__PURE__ */ Ps(Ff, [["__scopeId", "data-v-
|
|
9078
|
+
const zf = /* @__PURE__ */ Ps(Ff, [["__scopeId", "data-v-df5778ee"]]), Nf = /* @__PURE__ */ Ue({
|
|
9074
9079
|
__name: "ToolAnnotationTextSelection",
|
|
9075
|
-
props: {
|
|
9080
|
+
props: /* @__PURE__ */ xr({
|
|
9081
|
+
ariaDisabled: { type: Boolean },
|
|
9082
|
+
active: { type: Boolean }
|
|
9083
|
+
}, {
|
|
9076
9084
|
active: { type: Boolean, required: !0 },
|
|
9077
9085
|
activeModifiers: {}
|
|
9078
|
-
},
|
|
9086
|
+
}),
|
|
9079
9087
|
emits: ["update:active"],
|
|
9080
9088
|
setup(e) {
|
|
9081
|
-
const t = Sr(e, "active"), { t:
|
|
9082
|
-
r.value || (
|
|
9089
|
+
const t = e, n = Sr(e, "active"), { t: i } = Kn(), r = fe(() => t.ariaDisabled === !0), s = () => {
|
|
9090
|
+
r.value || (n.value = !n.value);
|
|
9083
9091
|
};
|
|
9084
9092
|
return (o, c) => o.$slots.default ? pe(o.$slots, "default", ve({ key: 0 }, o.$attrs, { onClick: s })) : (ee(), ae(Gn, { key: 1 }, {
|
|
9085
9093
|
content: Q(() => [
|
|
9086
|
-
On(Fn(Be(
|
|
9094
|
+
On(Fn(Be(i)("annotationTextSelectionTooltip")), 1)
|
|
9087
9095
|
]),
|
|
9088
9096
|
default: Q(() => [
|
|
9089
9097
|
Ae(Wn, ve({
|
|
9090
|
-
"aria-label": Be(
|
|
9091
|
-
class: ["vpv-toolbar-btn", { "vpv-toolbar-btn-active":
|
|
9098
|
+
"aria-label": Be(i)("annotationTextSelectionLabel"),
|
|
9099
|
+
class: ["vpv-toolbar-btn", { "vpv-toolbar-btn-active": n.value }]
|
|
9092
9100
|
}, o.$attrs, { onClick: s }), {
|
|
9093
9101
|
default: Q(() => [
|
|
9094
9102
|
pe(o.$slots, "icon", {}, () => [
|
|
@@ -9102,7 +9110,15 @@ const zf = /* @__PURE__ */ Ps(Ff, [["__scopeId", "data-v-da575fac"]]), Nf = /* @
|
|
|
9102
9110
|
}));
|
|
9103
9111
|
}
|
|
9104
9112
|
}), Lf = /* @__PURE__ */ Ue({
|
|
9113
|
+
inheritAttrs: !1,
|
|
9105
9114
|
__name: "AppPopover",
|
|
9115
|
+
props: {
|
|
9116
|
+
open: { type: Boolean },
|
|
9117
|
+
side: {},
|
|
9118
|
+
sideOffset: {},
|
|
9119
|
+
class: {},
|
|
9120
|
+
ariaLabel: {}
|
|
9121
|
+
},
|
|
9106
9122
|
setup(e) {
|
|
9107
9123
|
const t = In(Hn), n = fe(() => t?.AppPopover);
|
|
9108
9124
|
return (i, r) => n.value ? (ee(), ae(Se(n.value), xt(ve({ key: 0 }, i.$attrs)), {
|
|
@@ -9125,14 +9141,17 @@ const zf = /* @__PURE__ */ Ps(Ff, [["__scopeId", "data-v-da575fac"]]), Nf = /* @
|
|
|
9125
9141
|
}
|
|
9126
9142
|
}), Mf = /* @__PURE__ */ Ue({
|
|
9127
9143
|
__name: "ToolAnnotationSignature",
|
|
9128
|
-
props: {
|
|
9144
|
+
props: /* @__PURE__ */ xr({
|
|
9145
|
+
ariaDisabled: { type: Boolean },
|
|
9146
|
+
active: { type: Boolean }
|
|
9147
|
+
}, {
|
|
9129
9148
|
active: { type: Boolean, required: !0 },
|
|
9130
9149
|
activeModifiers: {}
|
|
9131
|
-
},
|
|
9150
|
+
}),
|
|
9132
9151
|
emits: ["update:active"],
|
|
9133
9152
|
setup(e) {
|
|
9134
|
-
const t = Sr(e, "active"), { t:
|
|
9135
|
-
s.value || (!
|
|
9153
|
+
const t = e, n = Sr(e, "active"), { t: i } = Kn(), r = di(!1), s = fe(() => t.ariaDisabled === !0), o = () => {
|
|
9154
|
+
s.value || (!n.value && !r.value && (r.value = !0), n.value = !n.value);
|
|
9136
9155
|
}, c = (l) => {
|
|
9137
9156
|
r.value = !1;
|
|
9138
9157
|
};
|
|
@@ -9147,12 +9166,12 @@ const zf = /* @__PURE__ */ Ps(Ff, [["__scopeId", "data-v-da575fac"]]), Nf = /* @
|
|
|
9147
9166
|
trigger: Q(() => [
|
|
9148
9167
|
Ae(Gn, null, {
|
|
9149
9168
|
content: Q(() => [
|
|
9150
|
-
On(Fn(Be(
|
|
9169
|
+
On(Fn(Be(i)("annotationSignatureTooltip")), 1)
|
|
9151
9170
|
]),
|
|
9152
9171
|
default: Q(() => [
|
|
9153
9172
|
Ae(Wn, ve({
|
|
9154
|
-
"aria-label": Be(
|
|
9155
|
-
class: ["vpv-toolbar-btn", { "vpv-toolbar-btn-active":
|
|
9173
|
+
"aria-label": Be(i)("annotationSignatureLabel"),
|
|
9174
|
+
class: ["vpv-toolbar-btn", { "vpv-toolbar-btn-active": n.value }]
|
|
9156
9175
|
}, l.$attrs, { onClick: o }), {
|
|
9157
9176
|
default: Q(() => [
|
|
9158
9177
|
pe(l.$slots, "icon", {}, () => [
|
|
@@ -9173,23 +9192,26 @@ const zf = /* @__PURE__ */ Ps(Ff, [["__scopeId", "data-v-da575fac"]]), Nf = /* @
|
|
|
9173
9192
|
}
|
|
9174
9193
|
}), Uf = /* @__PURE__ */ Ue({
|
|
9175
9194
|
__name: "ToolAnnotationFreeText",
|
|
9176
|
-
props: {
|
|
9195
|
+
props: /* @__PURE__ */ xr({
|
|
9196
|
+
ariaDisabled: { type: Boolean },
|
|
9197
|
+
active: { type: Boolean }
|
|
9198
|
+
}, {
|
|
9177
9199
|
active: { type: Boolean, required: !0 },
|
|
9178
9200
|
activeModifiers: {}
|
|
9179
|
-
},
|
|
9201
|
+
}),
|
|
9180
9202
|
emits: ["update:active"],
|
|
9181
9203
|
setup(e) {
|
|
9182
|
-
const t = Sr(e, "active"), { t:
|
|
9183
|
-
r.value || (
|
|
9204
|
+
const t = e, n = Sr(e, "active"), { t: i } = Kn(), r = fe(() => t.ariaDisabled === !0), s = () => {
|
|
9205
|
+
r.value || (n.value = !n.value);
|
|
9184
9206
|
};
|
|
9185
9207
|
return (o, c) => o.$slots.default ? pe(o.$slots, "default", ve({ key: 0 }, o.$attrs, { onClick: s })) : (ee(), ae(Gn, { key: 1 }, {
|
|
9186
9208
|
content: Q(() => [
|
|
9187
|
-
On(Fn(Be(
|
|
9209
|
+
On(Fn(Be(i)("annotationFreeTextTooltip")), 1)
|
|
9188
9210
|
]),
|
|
9189
9211
|
default: Q(() => [
|
|
9190
9212
|
Ae(Wn, ve({
|
|
9191
|
-
"aria-label": Be(
|
|
9192
|
-
class: ["vpv-toolbar-btn", { "vpv-toolbar-btn-active":
|
|
9213
|
+
"aria-label": Be(i)("annotationFreeTextLabel"),
|
|
9214
|
+
class: ["vpv-toolbar-btn", { "vpv-toolbar-btn-active": n.value }]
|
|
9193
9215
|
}, o.$attrs, { onClick: s }), {
|
|
9194
9216
|
default: Q(() => [
|
|
9195
9217
|
pe(o.$slots, "icon", {}, () => [
|
|
@@ -9204,24 +9226,27 @@ const zf = /* @__PURE__ */ Ps(Ff, [["__scopeId", "data-v-da575fac"]]), Nf = /* @
|
|
|
9204
9226
|
}
|
|
9205
9227
|
}), $f = /* @__PURE__ */ Ue({
|
|
9206
9228
|
__name: "ToolAnnotationImage",
|
|
9229
|
+
props: {
|
|
9230
|
+
ariaDisabled: { type: Boolean }
|
|
9231
|
+
},
|
|
9207
9232
|
emits: ["change"],
|
|
9208
9233
|
setup(e, { emit: t }) {
|
|
9209
|
-
const { t:
|
|
9234
|
+
const n = e, { t: i } = Kn(), r = t, s = fe(() => n.ariaDisabled === !0), o = () => {
|
|
9210
9235
|
if (s.value)
|
|
9211
9236
|
return;
|
|
9212
9237
|
const c = document.createElement("input");
|
|
9213
9238
|
c.type = "file", c.accept = "image/*", c.onchange = (l) => {
|
|
9214
9239
|
const a = l.target.files?.[0];
|
|
9215
|
-
|
|
9240
|
+
r("change", a);
|
|
9216
9241
|
}, c.click();
|
|
9217
9242
|
};
|
|
9218
9243
|
return (c, l) => c.$slots.default ? pe(c.$slots, "default", ve({ key: 0 }, c.$attrs, { onClick: o })) : (ee(), ae(Gn, { key: 1 }, {
|
|
9219
9244
|
content: Q(() => [
|
|
9220
|
-
On(Fn(Be(
|
|
9245
|
+
On(Fn(Be(i)("annotationImageTooltip")), 1)
|
|
9221
9246
|
]),
|
|
9222
9247
|
default: Q(() => [
|
|
9223
9248
|
Ae(Wn, ve({
|
|
9224
|
-
"aria-label": Be(
|
|
9249
|
+
"aria-label": Be(i)("annotationImageLabel"),
|
|
9225
9250
|
class: "vpv-toolbar-btn"
|
|
9226
9251
|
}, c.$attrs, { onClick: o }), {
|
|
9227
9252
|
default: Q(() => [
|
|
@@ -9338,7 +9363,7 @@ const Hf = { class: "vpv-annotation-tools-container" }, Gf = {
|
|
|
9338
9363
|
const _ = (S) => {
|
|
9339
9364
|
c.value = S, S || (a.value = !1, h.value = !1, f.value = !1);
|
|
9340
9365
|
}, E = Object.entries(
|
|
9341
|
-
|
|
9366
|
+
Tf
|
|
9342
9367
|
).map(
|
|
9343
9368
|
([S, F]) => ({ value: S, label: F })
|
|
9344
9369
|
), x = (S) => {
|
|
@@ -9386,7 +9411,7 @@ const Hf = { class: "vpv-annotation-tools-container" }, Gf = {
|
|
|
9386
9411
|
Xn(r, (S) => {
|
|
9387
9412
|
S && (l.textSelection = !1, l.freeText = !1, l.signature = !1, k());
|
|
9388
9413
|
});
|
|
9389
|
-
const
|
|
9414
|
+
const T = (S) => {
|
|
9390
9415
|
const { id: F, ...B } = S;
|
|
9391
9416
|
return {
|
|
9392
9417
|
...B,
|
|
@@ -9399,7 +9424,7 @@ const Hf = { class: "vpv-annotation-tools-container" }, Gf = {
|
|
|
9399
9424
|
if (!S)
|
|
9400
9425
|
return;
|
|
9401
9426
|
const $ = (O) => {
|
|
9402
|
-
S(
|
|
9427
|
+
S(T(O.detail));
|
|
9403
9428
|
}, L = Ft(
|
|
9404
9429
|
n.instanceId,
|
|
9405
9430
|
hn.AnnotationCreated
|
|
@@ -9415,7 +9440,7 @@ const Hf = { class: "vpv-annotation-tools-container" }, Gf = {
|
|
|
9415
9440
|
if (!S)
|
|
9416
9441
|
return;
|
|
9417
9442
|
const $ = (O) => {
|
|
9418
|
-
S(
|
|
9443
|
+
S(T(O.detail));
|
|
9419
9444
|
}, L = Ft(
|
|
9420
9445
|
n.instanceId,
|
|
9421
9446
|
hn.AnnotationUpdated
|
|
@@ -9431,7 +9456,7 @@ const Hf = { class: "vpv-annotation-tools-container" }, Gf = {
|
|
|
9431
9456
|
if (!S)
|
|
9432
9457
|
return;
|
|
9433
9458
|
const $ = (O) => {
|
|
9434
|
-
S(
|
|
9459
|
+
S(T(O.detail));
|
|
9435
9460
|
}, L = Ft(
|
|
9436
9461
|
n.instanceId,
|
|
9437
9462
|
hn.AnnotationDeleted
|
|
@@ -9547,7 +9572,7 @@ const Hf = { class: "vpv-annotation-tools-container" }, Gf = {
|
|
|
9547
9572
|
]));
|
|
9548
9573
|
}
|
|
9549
9574
|
});
|
|
9550
|
-
const Kf = /* @__PURE__ */ Ps(Wf, [["__scopeId", "data-v-
|
|
9575
|
+
const Kf = /* @__PURE__ */ Ps(Wf, [["__scopeId", "data-v-8583d7e5"]]), Vf = (e = {}) => {
|
|
9551
9576
|
const { textSelection: t, freeText: n, image: i, ...r } = e;
|
|
9552
9577
|
let s = null;
|
|
9553
9578
|
return {
|
|
@@ -9555,7 +9580,7 @@ const Kf = /* @__PURE__ */ Ps(Wf, [["__scopeId", "data-v-657bb6a9"]]), Vf = (e =
|
|
|
9555
9580
|
setup(o) {
|
|
9556
9581
|
const { componentInstance: c, shared: l } = o, a = c?.uid ?? 0;
|
|
9557
9582
|
o.toolbar.addItem({
|
|
9558
|
-
id:
|
|
9583
|
+
id: Df.ANNOTATIONS,
|
|
9559
9584
|
toolbarDirection: "left",
|
|
9560
9585
|
component: oi(Kf, {
|
|
9561
9586
|
textSelection: t,
|