提交 00dface6 编写于 作者: lxm1993's avatar lxm1993

feat: 插件更新

上级 9292ad5c
......@@ -31,11 +31,11 @@ const gB = rt({
proxy: A
} = tt(), r = dn(A, e.modelPath);
En(A, "deName", r.setDeName.bind(r));
const t = et("wf-step-trace-grid"), B = Xe([]), n = (a, i, o = !1) => {
a.identitylinks.length > 0 || a.comments.length > 0 && a.comments.forEach((Q) => {
o && Q.type === "启动流程" || i.push({
const t = et("wf-step-trace-grid"), B = Xe([]), n = (i, a, o = !1) => {
i.comments.length > 0 && i.comments.forEach((Q) => {
o && Q.type === "启动流程" || a.push({
id: ct(),
nodeName: a.userTaskName,
nodeName: i.userTaskName,
personName: Q.authorName,
time: Q.time,
content: Q.type,
......@@ -44,15 +44,15 @@ const gB = rt({
});
};
r.nerve.self.evt.on("mounted", () => {
var a;
r.data && ((a = r.data.usertasks) == null || a.forEach((i) => {
if (i.usertasks && i.usertasks.length > 0) {
var i;
r.data && ((i = r.data.usertasks) == null || i.forEach((a) => {
if (a.usertasks && a.usertasks.length > 0) {
const o = [];
i.usertasks.forEach((Q) => {
a.usertasks.forEach((Q) => {
n(Q, o, !0);
}), B.value.push({
id: ct(),
nodeName: `${i.userTaskName}`,
nodeName: `${a.userTaskName}`,
personName: "",
time: "",
content: "",
......@@ -61,8 +61,8 @@ const gB = rt({
_showChildren: !0
});
} else
n(i, B.value);
}), B.value.sort((i, o) => Date.parse(i.time) - Date.parse(o.time)));
n(a, B.value);
}), B.value.sort((a, o) => Date.parse(a.time) - Date.parse(o.time)));
});
const s = Xe([{
title: "处理环节",
......@@ -141,7 +141,7 @@ const yn = rt({
setup(e) {
const {
proxy: A
} = tt(), r = Hn(A, (s, a) => new mn(e.modelPath, s, a)), t = et(`view-${In.DE_WF_DYNA_EDIT_VIEW3}`.toLowerCase()), B = Xe(["mainForm"]);
} = tt(), r = Hn(A, (s, i) => new mn(e.modelPath, s, i)), t = et(`view-${In.DE_WF_DYNA_EDIT_VIEW3}`.toLowerCase()), B = Xe(["mainForm"]);
return {
c: r,
ns: t,
......@@ -404,14 +404,14 @@ function J(e, A, r, t) {
});
}
return new (r || (r = Promise))(function(n, s) {
function a(Q) {
function i(Q) {
try {
o(t.next(Q));
} catch (c) {
s(c);
}
}
function i(Q) {
function a(Q) {
try {
o(t.throw(Q));
} catch (c) {
......@@ -419,7 +419,7 @@ function J(e, A, r, t) {
}
}
function o(Q) {
Q.done ? n(Q.value) : B(Q.value).then(a, i);
Q.done ? n(Q.value) : B(Q.value).then(i, a);
}
o((t = t.apply(e, A || [])).next());
});
......@@ -430,15 +430,15 @@ function X(e, A) {
throw n[1];
return n[1];
}, trys: [], ops: [] }, t, B, n, s;
return s = { next: a(0), throw: a(1), return: a(2) }, typeof Symbol == "function" && (s[Symbol.iterator] = function() {
return s = { next: i(0), throw: i(1), return: i(2) }, typeof Symbol == "function" && (s[Symbol.iterator] = function() {
return this;
}), s;
function a(o) {
function i(o) {
return function(Q) {
return i([o, Q]);
return a([o, Q]);
};
}
function i(o) {
function a(o) {
if (t)
throw new TypeError("Generator is already executing.");
for (; r; )
......@@ -550,11 +550,11 @@ var wt = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/", jA
for (var Ue = 0; Ue < wt.length; Ue++)
jA[wt.charCodeAt(Ue)] = Ue;
var Tn = function(e) {
var A = e.length * 0.75, r = e.length, t, B = 0, n, s, a, i;
var A = e.length * 0.75, r = e.length, t, B = 0, n, s, i, a;
e[e.length - 1] === "=" && (A--, e[e.length - 2] === "=" && A--);
var o = typeof ArrayBuffer < "u" && typeof Uint8Array < "u" && typeof Uint8Array.prototype.slice < "u" ? new ArrayBuffer(A) : new Array(A), Q = Array.isArray(o) ? o : new Uint8Array(o);
for (t = 0; t < r; t += 4)
n = jA[e.charCodeAt(t)], s = jA[e.charCodeAt(t + 1)], a = jA[e.charCodeAt(t + 2)], i = jA[e.charCodeAt(t + 3)], Q[B++] = n << 2 | s >> 4, Q[B++] = (s & 15) << 4 | a >> 2, Q[B++] = (a & 3) << 6 | i & 63;
n = jA[e.charCodeAt(t)], s = jA[e.charCodeAt(t + 1)], i = jA[e.charCodeAt(t + 2)], a = jA[e.charCodeAt(t + 3)], Q[B++] = n << 2 | s >> 4, Q[B++] = (s & 15) << 4 | i >> 2, Q[B++] = (i & 3) << 6 | a & 63;
return o;
}, Sn = function(e) {
for (var A = e.length, r = [], t = 0; t < A; t += 2)
......@@ -569,8 +569,8 @@ var Tn = function(e) {
}, Wn = function(e, A, r) {
return e.slice ? e.slice(A, r) : new Uint32Array(Array.prototype.slice.call(e, A, r));
}, Yn = function(e, A) {
var r = Tn(e), t = Array.isArray(r) ? On(r) : new Uint32Array(r), B = Array.isArray(r) ? Sn(r) : new Uint16Array(r), n = 24, s = lt(B, n / 2, t[4] / 2), a = t[5] === 2 ? lt(B, (n + t[4]) / 2) : Wn(t, Math.ceil((n + t[4]) / 4));
return new Zn(t[0], t[1], t[2], t[3], s, a);
var r = Tn(e), t = Array.isArray(r) ? On(r) : new Uint32Array(r), B = Array.isArray(r) ? Sn(r) : new Uint16Array(r), n = 24, s = lt(B, n / 2, t[4] / 2), i = t[5] === 2 ? lt(B, (n + t[4]) / 2) : Wn(t, Math.ceil((n + t[4]) / 4));
return new Zn(t[0], t[1], t[2], t[3], s, i);
}, Zn = (
/** @class */
function() {
......@@ -599,22 +599,22 @@ var zn = "KwAAAAAAAAAACA4AUD0AADAgAAACAAAAAAAIABAAGABAAEgAUABYAGAAaABgAGgAYgBqAF
A === void 0 && (A = "strict");
var r = [], t = [], B = [];
return e.forEach(function(n, s) {
var a = Pr.get(n);
if (a > Ct ? (B.push(!0), a -= Ct) : B.push(!1), ["normal", "auto", "loose"].indexOf(A) !== -1 && [8208, 8211, 12316, 12448].indexOf(n) !== -1)
var i = Pr.get(n);
if (i > Ct ? (B.push(!0), i -= Ct) : B.push(!1), ["normal", "auto", "loose"].indexOf(A) !== -1 && [8208, 8211, 12316, 12448].indexOf(n) !== -1)
return t.push(s), r.push(Or);
if (a === $n || a === Tr) {
if (i === $n || i === Tr) {
if (s === 0)
return t.push(s), r.push(LA);
var i = r[s - 1];
return as.indexOf(i) === -1 ? (t.push(t[s - 1]), r.push(i)) : (t.push(s), r.push(LA));
var a = r[s - 1];
return as.indexOf(a) === -1 ? (t.push(t[s - 1]), r.push(a)) : (t.push(s), r.push(LA));
}
if (t.push(s), a === Bs)
if (t.push(s), i === Bs)
return r.push(A === "strict" ? Mr : Qe);
if (a === fB || a === ts)
if (i === fB || i === ts)
return r.push(LA);
if (a === ns)
if (i === ns)
return n >= 131072 && n <= 196605 || n >= 196608 && n <= 262141 ? r.push(Qe) : r.push(LA);
r.push(a);
r.push(i);
}), [t, r, B];
}, ur = function(e, A, r, t) {
var B = t[r];
......@@ -630,17 +630,17 @@ var zn = "KwAAAAAAAAAACA4AUD0AADAgAAACAAAAAAAIABAAGABAAEgAUABYAGAAaABgAGgAYgBqAF
if (B === FA)
for (var n = r; n > 0; ) {
n--;
var a = t[n];
if (Array.isArray(e) ? e.indexOf(a) !== -1 : e === a)
for (var i = r; i <= t.length; ) {
i++;
var s = t[i];
var i = t[n];
if (Array.isArray(e) ? e.indexOf(i) !== -1 : e === i)
for (var a = r; a <= t.length; ) {
a++;
var s = t[a];
if (s === A)
return !0;
if (s !== FA)
break;
}
if (a !== FA)
if (i !== FA)
break;
}
return !1;
......@@ -659,27 +659,27 @@ var zn = "KwAAAAAAAAAACA4AUD0AADAgAAACAAAAAAAIABAAGABAAEgAUABYAGAAaABgAGgAYgBqAF
var n = t - 1;
if (Array.isArray(B) && B[n] === !0)
return I;
var s = n - 1, a = n + 1, i = A[n], o = s >= 0 ? A[s] : 0, Q = A[a];
if (i === lB && Q === uB)
var s = n - 1, i = n + 1, a = A[n], o = s >= 0 ? A[s] : 0, Q = A[i];
if (a === lB && Q === uB)
return I;
if (Xr.indexOf(i) !== -1)
if (Xr.indexOf(a) !== -1)
return UB;
if (Xr.indexOf(Q) !== -1 || FB.indexOf(Q) !== -1)
return I;
if (Ht(n, A) === CB)
return He;
if (Pr.get(e[n]) === Tr || (i === de || i === Ee) && Pr.get(e[a]) === Tr || i === ft || Q === ft || i === Ut || [FA, Sr, $A].indexOf(i) === -1 && Q === Ut || [he, YA, rs, SA, OA].indexOf(Q) !== -1 || Ht(n, A) === ZA || ur(wr, ZA, n, A) || ur([he, YA], Mr, n, A) || ur(Ft, Ft, n, A))
if (Pr.get(e[n]) === Tr || (a === de || a === Ee) && Pr.get(e[i]) === Tr || a === ft || Q === ft || a === Ut || [FA, Sr, $A].indexOf(a) === -1 && Q === Ut || [he, YA, rs, SA, OA].indexOf(Q) !== -1 || Ht(n, A) === ZA || ur(wr, ZA, n, A) || ur([he, YA], Mr, n, A) || ur(Ft, Ft, n, A))
return I;
if (i === FA)
if (a === FA)
return He;
if (i === wr || Q === wr)
if (a === wr || Q === wr)
return I;
if (Q === Or || i === Or)
if (Q === Or || a === Or)
return He;
if ([Sr, $A, Mr].indexOf(Q) !== -1 || i === es || o === Vr && is.indexOf(i) !== -1 || i === OA && Q === Vr || Q === ht || QA.indexOf(Q) !== -1 && i === z || QA.indexOf(i) !== -1 && Q === z || i === ee && [Qe, de, Ee].indexOf(Q) !== -1 || [Qe, de, Ee].indexOf(i) !== -1 && Q === Ae || QA.indexOf(i) !== -1 && dt.indexOf(Q) !== -1 || dt.indexOf(i) !== -1 && QA.indexOf(Q) !== -1 || // (PR | PO) × ( OP | HY )? NU
[ee, Ae].indexOf(i) !== -1 && (Q === z || [ZA, $A].indexOf(Q) !== -1 && A[a + 1] === z) || // ( OP | HY ) × NU
[ZA, $A].indexOf(i) !== -1 && Q === z || // NU × (NU | SY | IS)
i === z && [z, OA, SA].indexOf(Q) !== -1)
if ([Sr, $A, Mr].indexOf(Q) !== -1 || a === es || o === Vr && is.indexOf(a) !== -1 || a === OA && Q === Vr || Q === ht || QA.indexOf(Q) !== -1 && a === z || QA.indexOf(a) !== -1 && Q === z || a === ee && [Qe, de, Ee].indexOf(Q) !== -1 || [Qe, de, Ee].indexOf(a) !== -1 && Q === Ae || QA.indexOf(a) !== -1 && dt.indexOf(Q) !== -1 || dt.indexOf(a) !== -1 && QA.indexOf(Q) !== -1 || // (PR | PO) × ( OP | HY )? NU
[ee, Ae].indexOf(a) !== -1 && (Q === z || [ZA, $A].indexOf(Q) !== -1 && A[i + 1] === z) || // ( OP | HY ) × NU
[ZA, $A].indexOf(a) !== -1 && Q === z || // NU × (NU | SY | IS)
a === z && [z, OA, SA].indexOf(Q) !== -1)
return I;
if ([z, OA, SA, he, YA].indexOf(Q) !== -1)
for (var c = n; c >= 0; ) {
......@@ -692,7 +692,7 @@ var zn = "KwAAAAAAAAAACA4AUD0AADAgAAACAAAAAAAIABAAGABAAEgAUABYAGAAaABgAGgAYgBqAF
break;
}
if ([ee, Ae].indexOf(Q) !== -1)
for (var c = [he, YA].indexOf(i) !== -1 ? s : n; c >= 0; ) {
for (var c = [he, YA].indexOf(a) !== -1 ? s : n; c >= 0; ) {
var g = A[c];
if (g === z)
return I;
......@@ -701,23 +701,23 @@ var zn = "KwAAAAAAAAAACA4AUD0AADAgAAACAAAAAAAIABAAGABAAEgAUABYAGAAaABgAGgAYgBqAF
else
break;
}
if (Nr === i && [Nr, Re, Gr, Rr].indexOf(Q) !== -1 || [Re, Gr].indexOf(i) !== -1 && [Re, Ve].indexOf(Q) !== -1 || [Ve, Rr].indexOf(i) !== -1 && Q === Ve || Et.indexOf(i) !== -1 && [ht, Ae].indexOf(Q) !== -1 || Et.indexOf(Q) !== -1 && i === ee || QA.indexOf(i) !== -1 && QA.indexOf(Q) !== -1 || i === SA && QA.indexOf(Q) !== -1 || QA.concat(z).indexOf(i) !== -1 && Q === ZA && ss.indexOf(e[a]) === -1 || QA.concat(z).indexOf(Q) !== -1 && i === YA)
if (Nr === a && [Nr, Re, Gr, Rr].indexOf(Q) !== -1 || [Re, Gr].indexOf(a) !== -1 && [Re, Ve].indexOf(Q) !== -1 || [Ve, Rr].indexOf(a) !== -1 && Q === Ve || Et.indexOf(a) !== -1 && [ht, Ae].indexOf(Q) !== -1 || Et.indexOf(Q) !== -1 && a === ee || QA.indexOf(a) !== -1 && QA.indexOf(Q) !== -1 || a === SA && QA.indexOf(Q) !== -1 || QA.concat(z).indexOf(a) !== -1 && Q === ZA && ss.indexOf(e[i]) === -1 || QA.concat(z).indexOf(Q) !== -1 && a === YA)
return I;
if (i === lr && Q === lr) {
if (a === lr && Q === lr) {
for (var f = r[n], w = 1; f > 0 && (f--, A[f] === lr); )
w++;
if (w % 2 !== 0)
return I;
}
return i === de && Q === Ee ? I : He;
return a === de && Q === Ee ? I : He;
}, cs = function(e, A) {
A || (A = { lineBreak: "normal", wordBreak: "normal" });
var r = os(e, A.lineBreak), t = r[0], B = r[1], n = r[2];
(A.wordBreak === "break-all" || A.wordBreak === "break-word") && (B = B.map(function(a) {
return [z, LA, fB].indexOf(a) !== -1 ? Qe : a;
(A.wordBreak === "break-all" || A.wordBreak === "break-word") && (B = B.map(function(i) {
return [z, LA, fB].indexOf(i) !== -1 ? Qe : i;
}));
var s = A.wordBreak === "keep-all" ? n.map(function(a, i) {
return a && e[i] >= 19968 && e[i] <= 40959;
var s = A.wordBreak === "keep-all" ? n.map(function(i, a) {
return i && e[a] >= 19968 && e[a] <= 40959;
}) : void 0;
return [t, B, s];
}, gs = (
......@@ -731,16 +731,16 @@ var zn = "KwAAAAAAAAAACA4AUD0AADAgAAACAAAAAAAIABAAGABAAEgAUABYAGAAaABgAGgAYgBqAF
}, e;
}()
), ws = function(e, A) {
var r = er(e), t = cs(r, A), B = t[0], n = t[1], s = t[2], a = r.length, i = 0, o = 0;
var r = er(e), t = cs(r, A), B = t[0], n = t[1], s = t[2], i = r.length, a = 0, o = 0;
return {
next: function() {
if (o >= a)
if (o >= i)
return { done: !0, value: null };
for (var Q = I; o < a && (Q = Qs(r, n, B, ++o, s)) === I; )
for (var Q = I; o < i && (Q = Qs(r, n, B, ++o, s)) === I; )
;
if (Q !== I || o === a) {
var c = new gs(r, Q, i, o);
return i = o, { value: c, done: !1 };
if (Q !== I || o === i) {
var c = new gs(r, Q, a, o);
return a = o, { value: c, done: !1 };
}
return { done: !0, value: null };
}
......@@ -782,14 +782,14 @@ var zn = "KwAAAAAAAAAACA4AUD0AADAgAAACAAAAAAAIABAAGABAAEgAUABYAGAAaABgAGgAYgBqAF
e[A] === ce && A++;
for (var n = []; _(e[A]); )
n.push(e[A++]);
var s = n.length, a = s ? parseInt(S.apply(void 0, n), 10) : 0;
var s = n.length, i = s ? parseInt(S.apply(void 0, n), 10) : 0;
(e[A] === pB || e[A] === EB) && A++;
var i = 1;
(e[A] === bA || e[A] === Z) && (e[A] === Z && (i = -1), A++);
var a = 1;
(e[A] === bA || e[A] === Z) && (e[A] === Z && (a = -1), A++);
for (var o = []; _(e[A]); )
o.push(e[A++]);
var Q = o.length ? parseInt(S.apply(void 0, o), 10) : 0;
return r * (B + a * Math.pow(10, -s)) * Math.pow(10, i * Q);
return r * (B + i * Math.pow(10, -s)) * Math.pow(10, a * Q);
}, Aa = {
type: 2
/* LEFT_PARENTHESIS_TOKEN */
......@@ -898,12 +898,12 @@ var zn = "KwAAAAAAAAAACA4AUD0AADAgAAACAAAAAAAIABAAGABAAEgAUABYAGAAaABgAGgAYgBqAF
case xs:
return ra;
case Z:
var a = A, i = this.peekCodePoint(0), o = this.peekCodePoint(1);
if (fr(a, i, o))
var i = A, a = this.peekCodePoint(0), o = this.peekCodePoint(1);
if (fr(i, a, o))
return this.reconsumeCodePoint(A), this.consumeNumericToken();
if (Ke(a, i, o))
if (Ke(i, a, o))
return this.reconsumeCodePoint(A), this.consumeIdentLikeToken();
if (i === Z && o === ps)
if (a === Z && o === ps)
return this.consumeCodePoint(), this.consumeCodePoint(), wa;
break;
case ce:
......@@ -982,19 +982,19 @@ var zn = "KwAAAAAAAAAACA4AUD0AADAgAAACAAAAAAAIABAAGABAAEgAUABYAGAAaABgAGgAYgBqAF
for (var t = !1; r === me && A.length < 6; )
A.push(r), r = this.consumeCodePoint(), t = !0;
if (t) {
var B = parseInt(S.apply(void 0, A.map(function(i) {
return i === me ? hB : i;
})), 16), n = parseInt(S.apply(void 0, A.map(function(i) {
return i === me ? IB : i;
var B = parseInt(S.apply(void 0, A.map(function(a) {
return a === me ? hB : a;
})), 16), n = parseInt(S.apply(void 0, A.map(function(a) {
return a === me ? IB : a;
})), 16);
return { type: 30, start: B, end: n };
}
var s = parseInt(S.apply(void 0, A), 16);
if (this.peekCodePoint(0) === Z && MA(this.peekCodePoint(1))) {
this.consumeCodePoint(), r = this.consumeCodePoint();
for (var a = []; MA(r) && a.length < 6; )
a.push(r), r = this.consumeCodePoint();
var n = parseInt(S.apply(void 0, a), 16);
for (var i = []; MA(r) && i.length < 6; )
i.push(r), r = this.consumeCodePoint();
var n = parseInt(S.apply(void 0, i), 16);
return { type: 30, start: s, end: n };
} else
return { type: 30, start: s, end: s };
......@@ -1074,8 +1074,8 @@ var zn = "KwAAAAAAAAAACA4AUD0AADAgAAACAAAAAAAIABAAGABAAEgAUABYAGAAaABgAGgAYgBqAF
}, e.prototype.consumeNumericToken = function() {
var A = this.consumeNumber(), r = A[0], t = A[1], B = this.peekCodePoint(0), n = this.peekCodePoint(1), s = this.peekCodePoint(2);
if (Ke(B, n, s)) {
var a = this.consumeName();
return { type: 15, number: r, flags: t, unit: a };
var i = this.consumeName();
return { type: 15, number: r, flags: t, unit: i };
}
return B === hs ? (this.consumeCodePoint(), { type: 16, number: r, flags: t }) : { type: 17, number: r, flags: t };
}, e.prototype.consumeEscapedCodePoint = function() {
......@@ -1317,9 +1317,9 @@ var zn = "KwAAAAAAAAAACA4AUD0AADAgAAACAAAAAAAIABAAGABAAEgAUABYAGAAaABgAGgAYgBqAF
}
}
if (A.type === 20) {
var a = gA[A.value.toUpperCase()];
if (typeof a < "u")
return a;
var i = gA[A.value.toUpperCase()];
if (typeof i < "u")
return i;
}
return gA.TRANSPARENT;
}
......@@ -1345,8 +1345,8 @@ var zn = "KwAAAAAAAAAACA4AUD0AADAgAAACAAAAAAAIABAAGABAAEgAUABYAGAAaABgAGgAYgBqAF
return dA(B, n, s, 1);
}
if (r.length === 4) {
var a = r.map(Kt), B = a[0], n = a[1], s = a[2], i = a[3];
return dA(B, n, s, i);
var i = r.map(Kt), B = i[0], n = i[1], s = i[2], a = i[3];
return dA(B, n, s, a);
}
return 0;
};
......@@ -1354,10 +1354,10 @@ function Ur(e, A, r) {
return r < 0 && (r += 1), r >= 1 && (r -= 1), r < 1 / 6 ? (A - e) * r * 6 + e : r < 1 / 2 ? A : r < 2 / 3 ? (A - e) * 6 * (2 / 3 - r) + e : e;
}
var bt = function(e, A) {
var r = A.filter(JA), t = r[0], B = r[1], n = r[2], s = r[3], a = (t.type === 17 ? AA(t.number) : rr.parse(e, t)) / (Math.PI * 2), i = M(B) ? B.number / 100 : 0, o = M(n) ? n.number / 100 : 0, Q = typeof s < "u" && M(s) ? D(s, 1) : 1;
if (i === 0)
var r = A.filter(JA), t = r[0], B = r[1], n = r[2], s = r[3], i = (t.type === 17 ? AA(t.number) : rr.parse(e, t)) / (Math.PI * 2), a = M(B) ? B.number / 100 : 0, o = M(n) ? n.number / 100 : 0, Q = typeof s < "u" && M(s) ? D(s, 1) : 1;
if (a === 0)
return dA(o * 255, o * 255, o * 255, 1);
var c = o <= 0.5 ? o * (i + 1) : o + i - o * i, g = o * 2 - c, f = Ur(g, c, a + 1 / 3), w = Ur(g, c, a), l = Ur(g, c, a - 1 / 3);
var c = o <= 0.5 ? o * (a + 1) : o + a - o * a, g = o * 2 - c, f = Ur(g, c, i + 1 / 3), w = Ur(g, c, i), l = Ur(g, c, i - 1 / 3);
return dA(f * 255, w * 255, l * 255, Q);
}, da = {
hsl: bt,
......@@ -1546,10 +1546,10 @@ var bt = function(e, A) {
var r = e[0], t = e[e.length - 1];
r.stop === null && (r.stop = P), t.stop === null && (t.stop = hA);
for (var B = [], n = 0, s = 0; s < e.length; s++) {
var a = e[s].stop;
if (a !== null) {
var i = D(a, A);
i > n ? B.push(i) : B.push(n), n = i;
var i = e[s].stop;
if (i !== null) {
var a = D(i, A);
a > n ? B.push(a) : B.push(n), n = a;
} else
B.push(null);
}
......@@ -1571,8 +1571,8 @@ var bt = function(e, A) {
var t = A / 2, B = r / 2, n = D(e[0], A) - t, s = B - D(e[1], r);
return (Math.atan2(s, n) + Math.PI * 2) % (Math.PI * 2);
}, Ia = function(e, A, r) {
var t = typeof e == "number" ? e : pa(e, A, r), B = Math.abs(A * Math.sin(t)) + Math.abs(r * Math.cos(t)), n = A / 2, s = r / 2, a = B / 2, i = Math.sin(t - Math.PI / 2) * a, o = Math.cos(t - Math.PI / 2) * a;
return [B, n - o, n + o, s - i, s + i];
var t = typeof e == "number" ? e : pa(e, A, r), B = Math.abs(A * Math.sin(t)) + Math.abs(r * Math.cos(t)), n = A / 2, s = r / 2, i = B / 2, a = Math.sin(t - Math.PI / 2) * i, o = Math.cos(t - Math.PI / 2) * i;
return [B, n - o, n + o, s - a, s + a];
}, rA = function(e, A) {
return Math.sqrt(e * e + A * A);
}, xt = function(e, A, r, t, B) {
......@@ -1582,10 +1582,10 @@ var bt = function(e, A) {
[e, 0],
[e, A]
];
return n.reduce(function(s, a) {
var i = a[0], o = a[1], Q = rA(r - i, t - o);
return n.reduce(function(s, i) {
var a = i[0], o = i[1], Q = rA(r - a, t - o);
return (B ? Q < s.optimumDistance : Q > s.optimumDistance) ? {
optimumCorner: a,
optimumCorner: i,
optimumDistance: Q
} : s;
}, {
......@@ -1602,8 +1602,8 @@ var bt = function(e, A) {
if (e.shape === 0)
n = s = Math.min(rA(A, r), rA(A, r - B), rA(A - t, r), rA(A - t, r - B));
else if (e.shape === 1) {
var a = Math.min(Math.abs(r), Math.abs(r - B)) / Math.min(Math.abs(A), Math.abs(A - t)), i = xt(t, B, A, r, !0), o = i[0], Q = i[1];
n = rA(o - A, (Q - r) / a), s = a * n;
var i = Math.min(Math.abs(r), Math.abs(r - B)) / Math.min(Math.abs(A), Math.abs(A - t)), a = xt(t, B, A, r, !0), o = a[0], Q = a[1];
n = rA(o - A, (Q - r) / i), s = i * n;
}
break;
case 1:
......@@ -1613,8 +1613,8 @@ var bt = function(e, A) {
if (e.shape === 0)
n = s = Math.max(rA(A, r), rA(A, r - B), rA(A - t, r), rA(A - t, r - B));
else if (e.shape === 1) {
var a = Math.max(Math.abs(r), Math.abs(r - B)) / Math.max(Math.abs(A), Math.abs(A - t)), c = xt(t, B, A, r, !1), o = c[0], Q = c[1];
n = rA(o - A, (Q - r) / a), s = a * n;
var i = Math.max(Math.abs(r), Math.abs(r - B)) / Math.max(Math.abs(A), Math.abs(A - t)), c = xt(t, B, A, r, !1), o = c[0], Q = c[1];
n = rA(o - A, (Q - r) / i), s = i * n;
}
break;
}
......@@ -1632,8 +1632,8 @@ var bt = function(e, A) {
return;
}
}
var a = tr(e, B);
t.push(a);
var i = tr(e, B);
t.push(i);
}), {
angle: r,
stops: t,
......@@ -1653,8 +1653,8 @@ var bt = function(e, A) {
return;
}
}
var a = tr(e, B);
t.push(a);
var i = tr(e, B);
t.push(i);
}), {
angle: r,
stops: t,
......@@ -1662,9 +1662,9 @@ var bt = function(e, A) {
/* LINEAR_GRADIENT */
};
}, ya = function(e, A) {
var r = AA(180), t = [], B = 1, n = 0, s = 3, a = [];
return sA(A).forEach(function(i, o) {
var Q = i[0];
var r = AA(180), t = [], B = 1, n = 0, s = 3, i = [];
return sA(A).forEach(function(a, o) {
var Q = a[0];
if (o === 0) {
if (b(Q) && Q.value === "linear") {
B = 1;
......@@ -1696,14 +1696,14 @@ var bt = function(e, A) {
angle: (r + AA(180)) % AA(360),
stops: t,
type: B
} : { size: s, shape: n, stops: t, position: a, type: B };
} : { size: s, shape: n, stops: t, position: i, type: B };
}, OB = "closest-side", MB = "farthest-side", GB = "closest-corner", RB = "farthest-corner", VB = "circle", NB = "ellipse", PB = "cover", XB = "contain", Ka = function(e, A) {
var r = 0, t = 3, B = [], n = [];
return sA(A).forEach(function(s, a) {
var i = !0;
if (a === 0) {
return sA(A).forEach(function(s, i) {
var a = !0;
if (i === 0) {
var o = !1;
i = s.reduce(function(c, g) {
a = s.reduce(function(c, g) {
if (o)
if (b(g))
switch (g.value) {
......@@ -1740,9 +1740,9 @@ var bt = function(e, A) {
else if (pA(g) || M(g))
return Array.isArray(t) || (t = []), t.push(g), !1;
return c;
}, i);
}, a);
}
if (i) {
if (a) {
var Q = tr(e, s);
B.push(Q);
}
......@@ -1756,9 +1756,9 @@ var bt = function(e, A) {
};
}, De = function(e, A) {
var r = 0, t = 3, B = [], n = [];
return sA(A).forEach(function(s, a) {
var i = !0;
if (a === 0 ? i = s.reduce(function(Q, c) {
return sA(A).forEach(function(s, i) {
var a = !0;
if (i === 0 ? a = s.reduce(function(Q, c) {
if (b(c))
switch (c.value) {
case "center":
......@@ -1773,7 +1773,7 @@ var bt = function(e, A) {
else if (M(c) || pA(c))
return n.push(c), !1;
return Q;
}, i) : a === 1 && (i = s.reduce(function(Q, c) {
}, a) : i === 1 && (a = s.reduce(function(Q, c) {
if (b(c))
switch (c.value) {
case VB:
......@@ -1794,7 +1794,7 @@ var bt = function(e, A) {
else if (pA(c) || M(c))
return Array.isArray(t) || (t = []), t.push(c), !1;
return Q;
}, i)), i) {
}, a)), a) {
var o = tr(e, s);
B.push(o);
}
......@@ -2414,16 +2414,16 @@ var ii = {
});
return A.length === 6 ? A : null;
}, yi = function(e) {
var A = e.filter(function(i) {
return i.type === 17;
}).map(function(i) {
return i.number;
var A = e.filter(function(a) {
return a.type === 17;
}).map(function(a) {
return a.number;
}), r = A[0], t = A[1];
A[2], A[3];
var B = A[4], n = A[5];
A[6], A[7], A[8], A[9], A[10], A[11];
var s = A[12], a = A[13];
return A[14], A[15], A.length === 16 ? [r, t, B, n, s, a] : null;
var s = A[12], i = A[13];
return A[14], A[15], A.length === 16 ? [r, t, B, n, s, i] : null;
}, Ki = {
matrix: mi,
matrix3d: yi
......@@ -2635,10 +2635,10 @@ var xi = {
if (r.type === 20 && r.value === "none")
return null;
for (var t = [], B = A.filter(yB), n = 0; n < B.length; n++) {
var s = B[n], a = B[n + 1];
var s = B[n], i = B[n + 1];
if (s.type === 20) {
var i = a && kA(a) ? a.number : 1;
t.push({ counter: s.value, increment: i });
var a = i && kA(i) ? i.number : 1;
t.push({ counter: s.value, increment: a });
}
}
return t;
......@@ -2654,8 +2654,8 @@ var xi = {
for (var r = [], t = A.filter(yB), B = 0; B < t.length; B++) {
var n = t[B], s = t[B + 1];
if (b(n) && n.value !== "none") {
var a = s && kA(s) ? s.number : 0;
r.push({ counter: n.value, reset: a });
var i = s && kA(s) ? s.number : 0;
r.push({ counter: n.value, reset: i });
}
}
return r;
......@@ -2685,8 +2685,8 @@ var xi = {
if (B.length % 2 !== 0)
return null;
for (var n = 0; n < B.length; n += 2) {
var s = B[n].value, a = B[n + 1].value;
t.push({ open: s, close: a });
var s = B[n].value, i = B[n + 1].value;
t.push({ open: s, close: i });
}
return t;
}
......@@ -2855,11 +2855,11 @@ var xi = {
case "image":
return st.parse(e, n.parseComponentValue());
case "length":
var a = n.parseComponentValue();
return pA(a) ? a : P;
case "length-percentage":
var i = n.parseComponentValue();
return M(i) ? i : P;
return pA(i) ? i : P;
case "length-percentage":
var a = n.parseComponentValue();
return M(a) ? a : P;
case "time":
return JB.parse(e, n.parseComponentValue());
}
......@@ -2906,11 +2906,11 @@ var xi = {
for (var xe = 0; xe < Gt.length; xe++)
te[Gt.charCodeAt(xe)] = xe;
var to = function(e) {
var A = e.length * 0.75, r = e.length, t, B = 0, n, s, a, i;
var A = e.length * 0.75, r = e.length, t, B = 0, n, s, i, a;
e[e.length - 1] === "=" && (A--, e[e.length - 2] === "=" && A--);
var o = typeof ArrayBuffer < "u" && typeof Uint8Array < "u" && typeof Uint8Array.prototype.slice < "u" ? new ArrayBuffer(A) : new Array(A), Q = Array.isArray(o) ? o : new Uint8Array(o);
for (t = 0; t < r; t += 4)
n = te[e.charCodeAt(t)], s = te[e.charCodeAt(t + 1)], a = te[e.charCodeAt(t + 2)], i = te[e.charCodeAt(t + 3)], Q[B++] = n << 2 | s >> 4, Q[B++] = (s & 15) << 4 | a >> 2, Q[B++] = (a & 3) << 6 | i & 63;
n = te[e.charCodeAt(t)], s = te[e.charCodeAt(t + 1)], i = te[e.charCodeAt(t + 2)], a = te[e.charCodeAt(t + 3)], Q[B++] = n << 2 | s >> 4, Q[B++] = (s & 15) << 4 | i >> 2, Q[B++] = (i & 3) << 6 | a & 63;
return o;
}, Bo = function(e) {
for (var A = e.length, r = [], t = 0; t < A; t += 2)
......@@ -2925,8 +2925,8 @@ var to = function(e) {
}, Co = function(e, A, r) {
return e.slice ? e.slice(A, r) : new Uint32Array(Array.prototype.slice.call(e, A, r));
}, fo = function(e, A) {
var r = to(e), t = Array.isArray(r) ? no(r) : new Uint32Array(r), B = Array.isArray(r) ? Bo(r) : new Uint16Array(r), n = 24, s = Rt(B, n / 2, t[4] / 2), a = t[5] === 2 ? Rt(B, (n + t[4]) / 2) : Co(t, Math.ceil((n + t[4]) / 4));
return new Uo(t[0], t[1], t[2], t[3], s, a);
var r = to(e), t = Array.isArray(r) ? no(r) : new Uint32Array(r), B = Array.isArray(r) ? Bo(r) : new Uint16Array(r), n = 24, s = Rt(B, n / 2, t[4] / 2), i = t[5] === 2 ? Rt(B, (n + t[4]) / 2) : Co(t, Math.ceil((n + t[4]) / 4));
return new Uo(t[0], t[1], t[2], t[3], s, i);
}, Uo = (
/** @class */
function() {
......@@ -2991,9 +2991,9 @@ var ho = 1, dr = 2, Er = 3, Nt = 4, Pt = 5, Eo = 7, Xt = 8, Hr = 9, pr = 10, _t
return j;
}
if (n === Ir && s === Ir) {
for (var a = 0; B === Ir; )
a++, B = A[--t];
if (a % 2 === 0)
for (var i = 0; B === Ir; )
i++, B = A[--t];
if (i % 2 === 0)
return j;
}
return vr;
......@@ -3006,8 +3006,8 @@ var ho = 1, dr = 2, Er = 3, Nt = 4, Pt = 5, Eo = 7, Xt = 8, Hr = 9, pr = 10, _t
for (var s = j; t < r && (s = mo(A, n, ++t)) === j; )
;
if (s !== j || t === r) {
var a = po.apply(null, A.slice(B, t));
return B = t, { value: a, done: !1 };
var i = po.apply(null, A.slice(B, t));
return B = t, { value: i, done: !1 };
}
return { done: !0, value: null };
}
......@@ -3034,16 +3034,16 @@ var ho = 1, dr = 2, Er = 3, Nt = 4, Pt = 5, Eo = 7, Xt = 8, Hr = 9, pr = 10, _t
A.style.width = "50px", A.style.display = "block", A.style.fontSize = "12px", A.style.letterSpacing = "0px", A.style.wordSpacing = "0px", e.body.appendChild(A);
var r = e.createRange();
A.innerHTML = typeof "".repeat == "function" ? "&#128104;".repeat(10) : "";
var t = A.firstChild, B = er(t.data).map(function(i) {
return S(i);
}), n = 0, s = {}, a = B.every(function(i, o) {
r.setStart(t, n), r.setEnd(t, n + i.length);
var t = A.firstChild, B = er(t.data).map(function(a) {
return S(a);
}), n = 0, s = {}, i = B.every(function(a, o) {
r.setStart(t, n), r.setEnd(t, n + a.length);
var Q = r.getBoundingClientRect();
n += i.length;
n += a.length;
var c = Q.x > s.x || Q.y > s.y;
return s = Q, o === 0 ? !0 : c;
});
return e.body.removeChild(A), a;
return e.body.removeChild(A), i;
}, Do = function() {
return typeof new Image().crossOrigin < "u";
}, xo = function() {
......@@ -3071,20 +3071,20 @@ var ho = 1, dr = 2, Er = 3, Nt = 4, Pt = 5, Eo = 7, Xt = 8, Hr = 9, pr = 10, _t
var B = new Image(), n = A.toDataURL();
B.src = n;
var s = Yr(r, r, 0, 0, B);
return t.fillStyle = "red", t.fillRect(0, 0, r, r), Zt(s).then(function(a) {
t.drawImage(a, 0, 0);
var i = t.getImageData(0, 0, r, r).data;
return t.fillStyle = "red", t.fillRect(0, 0, r, r), Zt(s).then(function(i) {
t.drawImage(i, 0, 0);
var a = t.getImageData(0, 0, r, r).data;
t.fillStyle = "red", t.fillRect(0, 0, r, r);
var o = e.createElement("div");
return o.style.backgroundImage = "url(" + n + ")", o.style.height = r + "px", Yt(i) ? Zt(Yr(r, r, 0, 0, o)) : Promise.reject(!1);
}).then(function(a) {
return t.drawImage(a, 0, 0), Yt(t.getImageData(0, 0, r, r).data);
return o.style.backgroundImage = "url(" + n + ")", o.style.height = r + "px", Yt(a) ? Zt(Yr(r, r, 0, 0, o)) : Promise.reject(!1);
}).then(function(i) {
return t.drawImage(i, 0, 0), Yt(t.getImageData(0, 0, r, r).data);
}).catch(function() {
return !1;
});
}, Yr = function(e, A, r, t, B) {
var n = "http://www.w3.org/2000/svg", s = document.createElementNS(n, "svg"), a = document.createElementNS(n, "foreignObject");
return s.setAttributeNS(null, "width", e.toString()), s.setAttributeNS(null, "height", A.toString()), a.setAttributeNS(null, "width", "100%"), a.setAttributeNS(null, "height", "100%"), a.setAttributeNS(null, "x", r.toString()), a.setAttributeNS(null, "y", t.toString()), a.setAttributeNS(null, "externalResourcesRequired", "true"), s.appendChild(a), a.appendChild(B), s;
var n = "http://www.w3.org/2000/svg", s = document.createElementNS(n, "svg"), i = document.createElementNS(n, "foreignObject");
return s.setAttributeNS(null, "width", e.toString()), s.setAttributeNS(null, "height", A.toString()), i.setAttributeNS(null, "width", "100%"), i.setAttributeNS(null, "height", "100%"), i.setAttributeNS(null, "x", r.toString()), i.setAttributeNS(null, "y", t.toString()), i.setAttributeNS(null, "externalResourcesRequired", "true"), s.appendChild(i), i.appendChild(B), s;
}, Zt = function(e) {
return new Promise(function(A, r) {
var t = new Image();
......@@ -3135,24 +3135,24 @@ var ho = 1, dr = 2, Er = 3, Nt = 4, Pt = 5, Eo = 7, Xt = 8, Hr = 9, pr = 10, _t
}()
), Oo = function(e, A, r, t) {
var B = Ro(A, r), n = [], s = 0;
return B.forEach(function(a) {
if (r.textDecorationLine.length || a.trim().length > 0)
return B.forEach(function(i) {
if (r.textDecorationLine.length || i.trim().length > 0)
if (N.SUPPORT_RANGE_BOUNDS) {
var i = qt(t, s, a.length).getClientRects();
if (i.length > 1) {
var o = it(a), Q = 0;
var a = qt(t, s, i.length).getClientRects();
if (a.length > 1) {
var o = it(i), Q = 0;
o.forEach(function(g) {
n.push(new ie(g, wA.fromDOMRectList(e, qt(t, Q + s, g.length).getClientRects()))), Q += g.length;
});
} else
n.push(new ie(a, wA.fromDOMRectList(e, i)));
n.push(new ie(i, wA.fromDOMRectList(e, a)));
} else {
var c = t.splitText(a.length);
n.push(new ie(a, Mo(e, t))), t = c;
var c = t.splitText(i.length);
n.push(new ie(i, Mo(e, t))), t = c;
}
else
N.SUPPORT_RANGE_BOUNDS || (t = t.splitText(a.length));
s += a.length;
N.SUPPORT_RANGE_BOUNDS || (t = t.splitText(i.length));
s += i.length;
}), n;
}, Mo = function(e, A) {
var r = A.ownerDocument;
......@@ -3199,10 +3199,10 @@ var ho = 1, dr = 2, Er = 3, Nt = 4, Pt = 5, Eo = 7, Xt = 8, Hr = 9, pr = 10, _t
wordBreak: A.overflowWrap === "break-word" ? "break-word" : A.wordBreak
}), t = [], B, n = function() {
if (B.value) {
var s = B.value.slice(), a = er(s), i = "";
a.forEach(function(o) {
Vo.indexOf(o) === -1 ? i += S(o) : (i.length && t.push(i), t.push(S(o)), i = "");
}), i.length && t.push(i);
var s = B.value.slice(), i = er(s), a = "";
i.forEach(function(o) {
Vo.indexOf(o) === -1 ? a += S(o) : (a.length && t.push(a), t.push(S(o)), a = "");
}), a.length && t.push(a);
}
}; !(B = r.next()).done; )
n();
......@@ -3353,7 +3353,7 @@ var ho = 1, dr = 2, Er = 3, Nt = 4, Pt = 5, Eo = 7, Xt = 8, Hr = 9, pr = 10, _t
var n = t.contentWindow.document.documentElement ? se(r, getComputedStyle(t.contentWindow.document.documentElement).backgroundColor) : gA.TRANSPARENT, s = t.contentWindow.document.body ? se(r, getComputedStyle(t.contentWindow.document.body).backgroundColor) : gA.TRANSPARENT;
B.backgroundColor = HA(n) ? HA(s) ? B.styles.backgroundColor : s : n;
}
} catch (a) {
} catch (i) {
}
return B;
}
......@@ -3365,8 +3365,8 @@ var ho = 1, dr = 2, Er = 3, Nt = 4, Pt = 5, Eo = 7, Xt = 8, Hr = 9, pr = 10, _t
r.textNodes.push(new Po(e, B, r.styles));
else if (XA(B))
if (sn(B) && B.assignedNodes)
B.assignedNodes().forEach(function(a) {
return Ne(e, a, r, t);
B.assignedNodes().forEach(function(i) {
return Ne(e, i, r, t);
});
else {
var s = An(e, B);
......@@ -3440,14 +3440,14 @@ var ho = 1, dr = 2, Er = 3, Nt = 4, Pt = 5, Eo = 7, Xt = 8, Hr = 9, pr = 10, _t
});
}, e.prototype.parse = function(A) {
var r = this, t = A.counterIncrement, B = A.counterReset, n = !0;
t !== null && t.forEach(function(a) {
var i = r.counters[a.counter];
i && a.increment !== 0 && (n = !1, i.length || i.push(1), i[Math.max(0, i.length - 1)] += a.increment);
t !== null && t.forEach(function(i) {
var a = r.counters[i.counter];
a && i.increment !== 0 && (n = !1, a.length || a.push(1), a[Math.max(0, a.length - 1)] += i.increment);
});
var s = [];
return n && B.forEach(function(a) {
var i = r.counters[a.counter];
s.push(a.counter), i || (i = r.counters[a.counter] = []), i.push(a.reset);
return n && B.forEach(function(i) {
var a = r.counters[i.counter];
s.push(i.counter), a || (a = r.counters[i.counter] = []), a.push(i.reset);
}), s;
}, e;
}()
......@@ -3690,9 +3690,9 @@ var ho = 1, dr = 2, Er = 3, Nt = 4, Pt = 5, Eo = 7, Xt = 8, Hr = 9, pr = 10, _t
"ა"
]
}, GA = function(e, A, r, t, B, n) {
return e < A || e > r ? ge(e, B, n.length > 0) : t.integers.reduce(function(s, a, i) {
for (; e >= a; )
e -= a, s += t.values[i];
return e < A || e > r ? ge(e, B, n.length > 0) : t.integers.reduce(function(s, i, a) {
for (; e >= i; )
e -= i, s += t.values[a];
return s;
}, "") + n;
}, an = function(e, A, r, t) {
......@@ -3715,14 +3715,14 @@ var ho = 1, dr = 2, Er = 3, Nt = 4, Pt = 5, Eo = 7, Xt = 8, Hr = 9, pr = 10, _t
}, NA = 1 << 0, CA = 1 << 1, fA = 1 << 2, Be = 1 << 3, cA = function(e, A, r, t, B, n) {
if (e < -9999 || e > 9999)
return ge(e, 4, B.length > 0);
var s = Math.abs(e), a = B;
var s = Math.abs(e), i = B;
if (s === 0)
return A[0] + a;
for (var i = 0; s > 0 && i <= 4; i++) {
return A[0] + i;
for (var a = 0; s > 0 && a <= 4; a++) {
var o = s % 10;
o === 0 && G(n, NA) && a !== "" ? a = A[o] + a : o > 1 || o === 1 && i === 0 || o === 1 && i === 1 && G(n, CA) || o === 1 && i === 1 && G(n, fA) && e > 100 || o === 1 && i > 1 && G(n, Be) ? a = A[o] + (i > 0 ? r[i - 1] : "") + a : o === 1 && i > 0 && (a = r[i - 1] + a), s = Math.floor(s / 10);
o === 0 && G(n, NA) && i !== "" ? i = A[o] + i : o > 1 || o === 1 && a === 0 || o === 1 && a === 1 && G(n, CA) || o === 1 && a === 1 && G(n, fA) && e > 100 || o === 1 && a > 1 && G(n, Be) ? i = A[o] + (a > 0 ? r[a - 1] : "") + i : o === 1 && a > 0 && (i = r[a - 1] + i), s = Math.floor(s / 10);
}
return (e < 0 ? t : "") + a;
return (e < 0 ? t : "") + i;
}, tB = "十百千萬", BB = "拾佰仟萬", nB = "マイナス", mr = "마이너스", ge = function(e, A, r) {
var t = r ? ". " : "", B = r ? "、" : "", n = r ? ", " : "", s = r ? " " : "";
switch (A) {
......@@ -3733,8 +3733,8 @@ var ho = 1, dr = 2, Er = 3, Nt = 4, Pt = 5, Eo = 7, Xt = 8, Hr = 9, pr = 10, _t
case 2:
return "◾" + s;
case 5:
var a = T(e, 48, 57, !0, t);
return a.length < 4 ? "0" + a : a;
var i = T(e, 48, 57, !0, t);
return i.length < 4 ? "0" + i : i;
case 4:
return KA(e, "〇一二三四五六七八九", B);
case 6:
......@@ -3836,22 +3836,22 @@ var ho = 1, dr = 2, Er = 3, Nt = 4, Pt = 5, Eo = 7, Xt = 8, Hr = 9, pr = 10, _t
var t = this, B = iQ(A, r);
if (!B.contentWindow)
return Promise.reject("Unable to find iframe window");
var n = A.defaultView.pageXOffset, s = A.defaultView.pageYOffset, a = B.contentWindow, i = a.document, o = cQ(B).then(function() {
var n = A.defaultView.pageXOffset, s = A.defaultView.pageYOffset, i = B.contentWindow, a = i.document, o = cQ(B).then(function() {
return J(t, void 0, void 0, function() {
var Q, c;
return X(this, function(g) {
switch (g.label) {
case 0:
return this.scrolledElements.forEach(uQ), a && (a.scrollTo(r.left, r.top), /(iPad|iPhone|iPod)/g.test(navigator.userAgent) && (a.scrollY !== r.top || a.scrollX !== r.left) && (this.context.logger.warn("Unable to restore scroll position for cloned document"), this.context.windowBounds = this.context.windowBounds.add(a.scrollX - r.left, a.scrollY - r.top, 0, 0))), Q = this.options.onclone, c = this.clonedReferenceElement, typeof c > "u" ? [2, Promise.reject("Error finding the " + this.referenceElement.nodeName + " in the cloned document")] : i.fonts && i.fonts.ready ? [4, i.fonts.ready] : [3, 2];
return this.scrolledElements.forEach(uQ), i && (i.scrollTo(r.left, r.top), /(iPad|iPhone|iPod)/g.test(navigator.userAgent) && (i.scrollY !== r.top || i.scrollX !== r.left) && (this.context.logger.warn("Unable to restore scroll position for cloned document"), this.context.windowBounds = this.context.windowBounds.add(i.scrollX - r.left, i.scrollY - r.top, 0, 0))), Q = this.options.onclone, c = this.clonedReferenceElement, typeof c > "u" ? [2, Promise.reject("Error finding the " + this.referenceElement.nodeName + " in the cloned document")] : a.fonts && a.fonts.ready ? [4, a.fonts.ready] : [3, 2];
case 1:
g.sent(), g.label = 2;
case 2:
return /(AppleWebKit)/g.test(navigator.userAgent) ? [4, QQ(i)] : [3, 4];
return /(AppleWebKit)/g.test(navigator.userAgent) ? [4, QQ(a)] : [3, 4];
case 3:
g.sent(), g.label = 4;
case 4:
return typeof Q == "function" ? [2, Promise.resolve().then(function() {
return Q(i, c);
return Q(a, c);
}).then(function() {
return B;
})] : [2, B];
......@@ -3859,7 +3859,7 @@ var ho = 1, dr = 2, Er = 3, Nt = 4, Pt = 5, Eo = 7, Xt = 8, Hr = 9, pr = 10, _t
});
});
});
return i.open(), i.write(wQ(document.doctype) + "<html></html>"), lQ(this.referenceElement.ownerDocument, n, s), i.replaceChild(i.adoptNode(this.documentElement), i.documentElement), i.close(), o;
return a.open(), a.write(wQ(document.doctype) + "<html></html>"), lQ(this.referenceElement.ownerDocument, n, s), a.replaceChild(a.adoptNode(this.documentElement), a.documentElement), a.close(), o;
}, e.prototype.createElementClone = function(A) {
if (Wr(
A,
......@@ -3910,10 +3910,10 @@ var ho = 1, dr = 2, Er = 3, Nt = 4, Pt = 5, Eo = 7, Xt = 8, Hr = 9, pr = 10, _t
if (!this.options.allowTaint && n)
s.putImageData(n.getImageData(0, 0, A.width, A.height), 0, 0);
else {
var a = (r = A.getContext("webgl2")) !== null && r !== void 0 ? r : A.getContext("webgl");
if (a) {
var i = a.getContextAttributes();
(i == null ? void 0 : i.preserveDrawingBuffer) === !1 && this.context.logger.warn("Unable to clone WebGL context as it has preserveDrawingBuffer=false", A);
var i = (r = A.getContext("webgl2")) !== null && r !== void 0 ? r : A.getContext("webgl");
if (i) {
var a = i.getContextAttributes();
(a == null ? void 0 : a.preserveDrawingBuffer) === !1 && this.context.logger.warn("Unable to clone WebGL context as it has preserveDrawingBuffer=false", A);
}
s.drawImage(A, 0, 0);
}
......@@ -3939,8 +3939,8 @@ var ho = 1, dr = 2, Er = 3, Nt = 4, Pt = 5, Eo = 7, Xt = 8, Hr = 9, pr = 10, _t
for (var B = this, n = A.shadowRoot ? A.shadowRoot.firstChild : A.firstChild; n; n = n.nextSibling)
if (XA(n) && sn(n) && typeof n.assignedNodes == "function") {
var s = n.assignedNodes();
s.length && s.forEach(function(a) {
return B.appendChildNode(r, a, t);
s.length && s.forEach(function(i) {
return B.appendChildNode(r, i, t);
});
} else
this.appendChildNode(r, n, t);
......@@ -3953,36 +3953,36 @@ var ho = 1, dr = 2, Er = 3, Nt = 4, Pt = 5, Eo = 7, Xt = 8, Hr = 9, pr = 10, _t
if (t && XA(A) && (qr(A) || Pe(A))) {
var B = this.createElementClone(A);
B.style.transitionProperty = "none";
var n = t.getComputedStyle(A), s = t.getComputedStyle(A, ":before"), a = t.getComputedStyle(A, ":after");
var n = t.getComputedStyle(A), s = t.getComputedStyle(A, ":before"), i = t.getComputedStyle(A, ":after");
this.referenceElement === A && qr(B) && (this.clonedReferenceElement = B), Qt(B) && UQ(B);
var i = this.counters.parse(new Mt(this.context, n)), o = this.resolvePseudoContent(A, B, s, oe.BEFORE);
var a = this.counters.parse(new Mt(this.context, n)), o = this.resolvePseudoContent(A, B, s, oe.BEFORE);
AB(A) && (r = !0), jt(A) || this.cloneChildNodes(A, B, r), o && B.insertBefore(o, B.firstChild);
var Q = this.resolvePseudoContent(A, B, a, oe.AFTER);
return Q && B.appendChild(Q), this.counters.pop(i), (n && (this.options.copyStyles || Pe(A)) && !nn(A) || r) && yr(n, B), (A.scrollTop !== 0 || A.scrollLeft !== 0) && this.scrolledElements.push([B, A.scrollLeft, A.scrollTop]), (Ze(A) || qe(A)) && (Ze(B) || qe(B)) && (B.value = A.value), B;
var Q = this.resolvePseudoContent(A, B, i, oe.AFTER);
return Q && B.appendChild(Q), this.counters.pop(a), (n && (this.options.copyStyles || Pe(A)) && !nn(A) || r) && yr(n, B), (A.scrollTop !== 0 || A.scrollLeft !== 0) && this.scrolledElements.push([B, A.scrollLeft, A.scrollTop]), (Ze(A) || qe(A)) && (Ze(B) || qe(B)) && (B.value = A.value), B;
}
return A.cloneNode(!1);
}, e.prototype.resolvePseudoContent = function(A, r, t, B) {
var n = this;
if (t) {
var s = t.content, a = r.ownerDocument;
if (!(!a || !s || s === "none" || s === "-moz-alt-content" || t.display === "none")) {
var s = t.content, i = r.ownerDocument;
if (!(!i || !s || s === "none" || s === "-moz-alt-content" || t.display === "none")) {
this.counters.parse(new Mt(this.context, t));
var i = new $i(this.context, t), o = a.createElement("html2canvaspseudoelement");
yr(t, o), i.content.forEach(function(c) {
var a = new $i(this.context, t), o = i.createElement("html2canvaspseudoelement");
yr(t, o), a.content.forEach(function(c) {
if (c.type === 0)
o.appendChild(a.createTextNode(c.value));
o.appendChild(i.createTextNode(c.value));
else if (c.type === 22) {
var g = a.createElement("img");
var g = i.createElement("img");
g.src = c.value, g.style.opacity = "1", o.appendChild(g);
} else if (c.type === 18) {
if (c.name === "attr") {
var f = c.values.filter(b);
f.length && o.appendChild(a.createTextNode(A.getAttribute(f[0].value) || ""));
f.length && o.appendChild(i.createTextNode(A.getAttribute(f[0].value) || ""));
} else if (c.name === "counter") {
var w = c.values.filter(JA), l = w[0], H = w[1];
if (l && b(l)) {
var h = n.counters.getCounterValue(l.value), F = H && b(H) ? kr.parse(n.context, H.value) : 3;
o.appendChild(a.createTextNode(ge(h, F, !1)));
o.appendChild(i.createTextNode(ge(h, F, !1)));
}
} else if (c.name === "counters") {
var y = c.values.filter(JA), l = y[0], p = y[1], H = y[2];
......@@ -3990,19 +3990,19 @@ var ho = 1, dr = 2, Er = 3, Nt = 4, Pt = 5, Eo = 7, Xt = 8, Hr = 9, pr = 10, _t
var d = n.counters.getCounterValues(l.value), C = H && b(H) ? kr.parse(n.context, H.value) : 3, v = p && p.type === 0 ? p.value : "", m = d.map(function(k) {
return ge(k, C, !1);
}).join(v);
o.appendChild(a.createTextNode(m));
o.appendChild(i.createTextNode(m));
}
}
} else if (c.type === 20)
switch (c.value) {
case "open-quote":
o.appendChild(a.createTextNode(Ot(i.quotes, n.quoteDepth++, !0)));
o.appendChild(i.createTextNode(Ot(a.quotes, n.quoteDepth++, !0)));
break;
case "close-quote":
o.appendChild(a.createTextNode(Ot(i.quotes, --n.quoteDepth, !1)));
o.appendChild(i.createTextNode(Ot(a.quotes, --n.quoteDepth, !1)));
break;
default:
o.appendChild(a.createTextNode(c.value));
o.appendChild(i.createTextNode(c.value));
}
}), o.className = jr + " " + $r;
var Q = B === oe.BEFORE ? " " + jr : " " + $r;
......@@ -4107,28 +4107,28 @@ var iQ = function(e, A) {
}, e.prototype.loadImage = function(A) {
return J(this, void 0, void 0, function() {
var r, t, B, n, s = this;
return X(this, function(a) {
switch (a.label) {
return X(this, function(i) {
switch (i.label) {
case 0:
return r = Qn.isSameOrigin(A), t = !Kr(A) && this._options.useCORS === !0 && N.SUPPORT_CORS_IMAGES && !r, B = !Kr(A) && !r && !Lr(A) && typeof this._options.proxy == "string" && N.SUPPORT_CORS_XHR && !t, !r && this._options.allowTaint === !1 && !Kr(A) && !Lr(A) && !B && !t ? [
2
/*return*/
] : (n = A, B ? [4, this.proxy(n)] : [3, 2]);
case 1:
n = a.sent(), a.label = 2;
n = i.sent(), i.label = 2;
case 2:
return this.context.logger.debug("Added image " + A.substring(0, 256)), [4, new Promise(function(i, o) {
return this.context.logger.debug("Added image " + A.substring(0, 256)), [4, new Promise(function(a, o) {
var Q = new Image();
Q.onload = function() {
return i(Q);
return a(Q);
}, Q.onerror = o, (IQ(n) || t) && (Q.crossOrigin = "anonymous"), Q.src = n, Q.complete === !0 && setTimeout(function() {
return i(Q);
return a(Q);
}, 500), s._options.imageTimeout > 0 && setTimeout(function() {
return o("Timed out (" + s._options.imageTimeout + "ms) loading image");
}, s._options.imageTimeout);
})];
case 3:
return [2, a.sent()];
return [2, i.sent()];
}
});
});
......@@ -4142,30 +4142,30 @@ var iQ = function(e, A) {
throw new Error("No proxy defined");
var B = A.substring(0, 256);
return new Promise(function(n, s) {
var a = N.SUPPORT_RESPONSE_TYPE ? "blob" : "text", i = new XMLHttpRequest();
i.onload = function() {
if (i.status === 200)
if (a === "text")
n(i.response);
var i = N.SUPPORT_RESPONSE_TYPE ? "blob" : "text", a = new XMLHttpRequest();
a.onload = function() {
if (a.status === 200)
if (i === "text")
n(a.response);
else {
var c = new FileReader();
c.addEventListener("load", function() {
return n(c.result);
}, !1), c.addEventListener("error", function(g) {
return s(g);
}, !1), c.readAsDataURL(i.response);
}, !1), c.readAsDataURL(a.response);
}
else
s("Failed to proxy resource " + B + " with status code " + i.status);
}, i.onerror = s;
s("Failed to proxy resource " + B + " with status code " + a.status);
}, a.onerror = s;
var o = t.indexOf("?") > -1 ? "&" : "?";
if (i.open("GET", "" + t + o + "url=" + encodeURIComponent(A) + "&responseType=" + a), a !== "text" && i instanceof XMLHttpRequest && (i.responseType = a), r._options.imageTimeout) {
if (a.open("GET", "" + t + o + "url=" + encodeURIComponent(A) + "&responseType=" + i), i !== "text" && a instanceof XMLHttpRequest && (a.responseType = i), r._options.imageTimeout) {
var Q = r._options.imageTimeout;
i.timeout = Q, i.ontimeout = function() {
a.timeout = Q, a.ontimeout = function() {
return s("Timed out (" + Q + "ms) proxying " + B);
};
}
i.send();
a.send();
});
}, e;
}()
......@@ -4198,8 +4198,8 @@ var iQ = function(e, A) {
this.type = 1, this.start = A, this.startControl = r, this.endControl = t, this.end = B;
}
return e.prototype.subdivide = function(A, r) {
var t = RA(this.start, this.startControl, A), B = RA(this.startControl, this.endControl, A), n = RA(this.endControl, this.end, A), s = RA(t, B, A), a = RA(B, n, A), i = RA(s, a, A);
return r ? new e(this.start, t, s, i) : new e(i, a, n, this.end);
var t = RA(this.start, this.startControl, A), B = RA(this.startControl, this.endControl, A), n = RA(this.endControl, this.end, A), s = RA(t, B, A), i = RA(B, n, A), a = RA(s, i, A);
return r ? new e(this.start, t, s, a) : new e(a, i, n, this.end);
}, e.prototype.add = function(A, r) {
return new e(this.start.add(A, r), this.startControl.add(A, r), this.endControl.add(A, r), this.end.add(A, r));
}, e.prototype.reverse = function() {
......@@ -4212,12 +4212,12 @@ var iQ = function(e, A) {
/** @class */
function() {
function e(A) {
var r = A.styles, t = A.bounds, B = re(r.borderTopLeftRadius, t.width, t.height), n = B[0], s = B[1], a = re(r.borderTopRightRadius, t.width, t.height), i = a[0], o = a[1], Q = re(r.borderBottomRightRadius, t.width, t.height), c = Q[0], g = Q[1], f = re(r.borderBottomLeftRadius, t.width, t.height), w = f[0], l = f[1], H = [];
H.push((n + i) / t.width), H.push((w + c) / t.width), H.push((s + l) / t.height), H.push((o + g) / t.height);
var r = A.styles, t = A.bounds, B = re(r.borderTopLeftRadius, t.width, t.height), n = B[0], s = B[1], i = re(r.borderTopRightRadius, t.width, t.height), a = i[0], o = i[1], Q = re(r.borderBottomRightRadius, t.width, t.height), c = Q[0], g = Q[1], f = re(r.borderBottomLeftRadius, t.width, t.height), w = f[0], l = f[1], H = [];
H.push((n + a) / t.width), H.push((w + c) / t.width), H.push((s + l) / t.height), H.push((o + g) / t.height);
var h = Math.max.apply(Math, H);
h > 1 && (n /= h, s /= h, i /= h, o /= h, c /= h, g /= h, w /= h, l /= h);
var F = t.width - i, y = t.height - g, p = t.width - c, d = t.height - l, C = r.borderTopWidth, v = r.borderRightWidth, m = r.borderBottomWidth, E = r.borderLeftWidth, O = D(r.paddingTop, A.bounds.width), k = D(r.paddingRight, A.bounds.width), q = D(r.paddingBottom, A.bounds.width), L = D(r.paddingLeft, A.bounds.width);
this.topLeftBorderDoubleOuterBox = n > 0 || s > 0 ? x(t.left + E / 3, t.top + C / 3, n - E / 3, s - C / 3, K.TOP_LEFT) : new u(t.left + E / 3, t.top + C / 3), this.topRightBorderDoubleOuterBox = n > 0 || s > 0 ? x(t.left + F, t.top + C / 3, i - v / 3, o - C / 3, K.TOP_RIGHT) : new u(t.left + t.width - v / 3, t.top + C / 3), this.bottomRightBorderDoubleOuterBox = c > 0 || g > 0 ? x(t.left + p, t.top + y, c - v / 3, g - m / 3, K.BOTTOM_RIGHT) : new u(t.left + t.width - v / 3, t.top + t.height - m / 3), this.bottomLeftBorderDoubleOuterBox = w > 0 || l > 0 ? x(t.left + E / 3, t.top + d, w - E / 3, l - m / 3, K.BOTTOM_LEFT) : new u(t.left + E / 3, t.top + t.height - m / 3), this.topLeftBorderDoubleInnerBox = n > 0 || s > 0 ? x(t.left + E * 2 / 3, t.top + C * 2 / 3, n - E * 2 / 3, s - C * 2 / 3, K.TOP_LEFT) : new u(t.left + E * 2 / 3, t.top + C * 2 / 3), this.topRightBorderDoubleInnerBox = n > 0 || s > 0 ? x(t.left + F, t.top + C * 2 / 3, i - v * 2 / 3, o - C * 2 / 3, K.TOP_RIGHT) : new u(t.left + t.width - v * 2 / 3, t.top + C * 2 / 3), this.bottomRightBorderDoubleInnerBox = c > 0 || g > 0 ? x(t.left + p, t.top + y, c - v * 2 / 3, g - m * 2 / 3, K.BOTTOM_RIGHT) : new u(t.left + t.width - v * 2 / 3, t.top + t.height - m * 2 / 3), this.bottomLeftBorderDoubleInnerBox = w > 0 || l > 0 ? x(t.left + E * 2 / 3, t.top + d, w - E * 2 / 3, l - m * 2 / 3, K.BOTTOM_LEFT) : new u(t.left + E * 2 / 3, t.top + t.height - m * 2 / 3), this.topLeftBorderStroke = n > 0 || s > 0 ? x(t.left + E / 2, t.top + C / 2, n - E / 2, s - C / 2, K.TOP_LEFT) : new u(t.left + E / 2, t.top + C / 2), this.topRightBorderStroke = n > 0 || s > 0 ? x(t.left + F, t.top + C / 2, i - v / 2, o - C / 2, K.TOP_RIGHT) : new u(t.left + t.width - v / 2, t.top + C / 2), this.bottomRightBorderStroke = c > 0 || g > 0 ? x(t.left + p, t.top + y, c - v / 2, g - m / 2, K.BOTTOM_RIGHT) : new u(t.left + t.width - v / 2, t.top + t.height - m / 2), this.bottomLeftBorderStroke = w > 0 || l > 0 ? x(t.left + E / 2, t.top + d, w - E / 2, l - m / 2, K.BOTTOM_LEFT) : new u(t.left + E / 2, t.top + t.height - m / 2), this.topLeftBorderBox = n > 0 || s > 0 ? x(t.left, t.top, n, s, K.TOP_LEFT) : new u(t.left, t.top), this.topRightBorderBox = i > 0 || o > 0 ? x(t.left + F, t.top, i, o, K.TOP_RIGHT) : new u(t.left + t.width, t.top), this.bottomRightBorderBox = c > 0 || g > 0 ? x(t.left + p, t.top + y, c, g, K.BOTTOM_RIGHT) : new u(t.left + t.width, t.top + t.height), this.bottomLeftBorderBox = w > 0 || l > 0 ? x(t.left, t.top + d, w, l, K.BOTTOM_LEFT) : new u(t.left, t.top + t.height), this.topLeftPaddingBox = n > 0 || s > 0 ? x(t.left + E, t.top + C, Math.max(0, n - E), Math.max(0, s - C), K.TOP_LEFT) : new u(t.left + E, t.top + C), this.topRightPaddingBox = i > 0 || o > 0 ? x(t.left + Math.min(F, t.width - v), t.top + C, F > t.width + v ? 0 : Math.max(0, i - v), Math.max(0, o - C), K.TOP_RIGHT) : new u(t.left + t.width - v, t.top + C), this.bottomRightPaddingBox = c > 0 || g > 0 ? x(t.left + Math.min(p, t.width - E), t.top + Math.min(y, t.height - m), Math.max(0, c - v), Math.max(0, g - m), K.BOTTOM_RIGHT) : new u(t.left + t.width - v, t.top + t.height - m), this.bottomLeftPaddingBox = w > 0 || l > 0 ? x(t.left + E, t.top + Math.min(d, t.height - m), Math.max(0, w - E), Math.max(0, l - m), K.BOTTOM_LEFT) : new u(t.left + E, t.top + t.height - m), this.topLeftContentBox = n > 0 || s > 0 ? x(t.left + E + L, t.top + C + O, Math.max(0, n - (E + L)), Math.max(0, s - (C + O)), K.TOP_LEFT) : new u(t.left + E + L, t.top + C + O), this.topRightContentBox = i > 0 || o > 0 ? x(t.left + Math.min(F, t.width + E + L), t.top + C + O, F > t.width + E + L ? 0 : i - E + L, o - (C + O), K.TOP_RIGHT) : new u(t.left + t.width - (v + k), t.top + C + O), this.bottomRightContentBox = c > 0 || g > 0 ? x(t.left + Math.min(p, t.width - (E + L)), t.top + Math.min(y, t.height + C + O), Math.max(0, c - (v + k)), g - (m + q), K.BOTTOM_RIGHT) : new u(t.left + t.width - (v + k), t.top + t.height - (m + q)), this.bottomLeftContentBox = w > 0 || l > 0 ? x(t.left + E + L, t.top + d, Math.max(0, w - (E + L)), l - (m + q), K.BOTTOM_LEFT) : new u(t.left + E + L, t.top + t.height - (m + q));
h > 1 && (n /= h, s /= h, a /= h, o /= h, c /= h, g /= h, w /= h, l /= h);
var F = t.width - a, y = t.height - g, p = t.width - c, d = t.height - l, C = r.borderTopWidth, v = r.borderRightWidth, m = r.borderBottomWidth, E = r.borderLeftWidth, O = D(r.paddingTop, A.bounds.width), k = D(r.paddingRight, A.bounds.width), q = D(r.paddingBottom, A.bounds.width), L = D(r.paddingLeft, A.bounds.width);
this.topLeftBorderDoubleOuterBox = n > 0 || s > 0 ? x(t.left + E / 3, t.top + C / 3, n - E / 3, s - C / 3, K.TOP_LEFT) : new u(t.left + E / 3, t.top + C / 3), this.topRightBorderDoubleOuterBox = n > 0 || s > 0 ? x(t.left + F, t.top + C / 3, a - v / 3, o - C / 3, K.TOP_RIGHT) : new u(t.left + t.width - v / 3, t.top + C / 3), this.bottomRightBorderDoubleOuterBox = c > 0 || g > 0 ? x(t.left + p, t.top + y, c - v / 3, g - m / 3, K.BOTTOM_RIGHT) : new u(t.left + t.width - v / 3, t.top + t.height - m / 3), this.bottomLeftBorderDoubleOuterBox = w > 0 || l > 0 ? x(t.left + E / 3, t.top + d, w - E / 3, l - m / 3, K.BOTTOM_LEFT) : new u(t.left + E / 3, t.top + t.height - m / 3), this.topLeftBorderDoubleInnerBox = n > 0 || s > 0 ? x(t.left + E * 2 / 3, t.top + C * 2 / 3, n - E * 2 / 3, s - C * 2 / 3, K.TOP_LEFT) : new u(t.left + E * 2 / 3, t.top + C * 2 / 3), this.topRightBorderDoubleInnerBox = n > 0 || s > 0 ? x(t.left + F, t.top + C * 2 / 3, a - v * 2 / 3, o - C * 2 / 3, K.TOP_RIGHT) : new u(t.left + t.width - v * 2 / 3, t.top + C * 2 / 3), this.bottomRightBorderDoubleInnerBox = c > 0 || g > 0 ? x(t.left + p, t.top + y, c - v * 2 / 3, g - m * 2 / 3, K.BOTTOM_RIGHT) : new u(t.left + t.width - v * 2 / 3, t.top + t.height - m * 2 / 3), this.bottomLeftBorderDoubleInnerBox = w > 0 || l > 0 ? x(t.left + E * 2 / 3, t.top + d, w - E * 2 / 3, l - m * 2 / 3, K.BOTTOM_LEFT) : new u(t.left + E * 2 / 3, t.top + t.height - m * 2 / 3), this.topLeftBorderStroke = n > 0 || s > 0 ? x(t.left + E / 2, t.top + C / 2, n - E / 2, s - C / 2, K.TOP_LEFT) : new u(t.left + E / 2, t.top + C / 2), this.topRightBorderStroke = n > 0 || s > 0 ? x(t.left + F, t.top + C / 2, a - v / 2, o - C / 2, K.TOP_RIGHT) : new u(t.left + t.width - v / 2, t.top + C / 2), this.bottomRightBorderStroke = c > 0 || g > 0 ? x(t.left + p, t.top + y, c - v / 2, g - m / 2, K.BOTTOM_RIGHT) : new u(t.left + t.width - v / 2, t.top + t.height - m / 2), this.bottomLeftBorderStroke = w > 0 || l > 0 ? x(t.left + E / 2, t.top + d, w - E / 2, l - m / 2, K.BOTTOM_LEFT) : new u(t.left + E / 2, t.top + t.height - m / 2), this.topLeftBorderBox = n > 0 || s > 0 ? x(t.left, t.top, n, s, K.TOP_LEFT) : new u(t.left, t.top), this.topRightBorderBox = a > 0 || o > 0 ? x(t.left + F, t.top, a, o, K.TOP_RIGHT) : new u(t.left + t.width, t.top), this.bottomRightBorderBox = c > 0 || g > 0 ? x(t.left + p, t.top + y, c, g, K.BOTTOM_RIGHT) : new u(t.left + t.width, t.top + t.height), this.bottomLeftBorderBox = w > 0 || l > 0 ? x(t.left, t.top + d, w, l, K.BOTTOM_LEFT) : new u(t.left, t.top + t.height), this.topLeftPaddingBox = n > 0 || s > 0 ? x(t.left + E, t.top + C, Math.max(0, n - E), Math.max(0, s - C), K.TOP_LEFT) : new u(t.left + E, t.top + C), this.topRightPaddingBox = a > 0 || o > 0 ? x(t.left + Math.min(F, t.width - v), t.top + C, F > t.width + v ? 0 : Math.max(0, a - v), Math.max(0, o - C), K.TOP_RIGHT) : new u(t.left + t.width - v, t.top + C), this.bottomRightPaddingBox = c > 0 || g > 0 ? x(t.left + Math.min(p, t.width - E), t.top + Math.min(y, t.height - m), Math.max(0, c - v), Math.max(0, g - m), K.BOTTOM_RIGHT) : new u(t.left + t.width - v, t.top + t.height - m), this.bottomLeftPaddingBox = w > 0 || l > 0 ? x(t.left + E, t.top + Math.min(d, t.height - m), Math.max(0, w - E), Math.max(0, l - m), K.BOTTOM_LEFT) : new u(t.left + E, t.top + t.height - m), this.topLeftContentBox = n > 0 || s > 0 ? x(t.left + E + L, t.top + C + O, Math.max(0, n - (E + L)), Math.max(0, s - (C + O)), K.TOP_LEFT) : new u(t.left + E + L, t.top + C + O), this.topRightContentBox = a > 0 || o > 0 ? x(t.left + Math.min(F, t.width + E + L), t.top + C + O, F > t.width + E + L ? 0 : a - E + L, o - (C + O), K.TOP_RIGHT) : new u(t.left + t.width - (v + k), t.top + C + O), this.bottomRightContentBox = c > 0 || g > 0 ? x(t.left + Math.min(p, t.width - (E + L)), t.top + Math.min(y, t.height + C + O), Math.max(0, c - (v + k)), g - (m + q), K.BOTTOM_RIGHT) : new u(t.left + t.width - (v + k), t.top + t.height - (m + q)), this.bottomLeftContentBox = w > 0 || l > 0 ? x(t.left + E + L, t.top + d, Math.max(0, w - (E + L)), l - (m + q), K.BOTTOM_LEFT) : new u(t.left + E + L, t.top + t.height - (m + q));
}
return e;
}()
......@@ -4226,17 +4226,17 @@ var iQ = function(e, A) {
e[e.TOP_LEFT = 0] = "TOP_LEFT", e[e.TOP_RIGHT = 1] = "TOP_RIGHT", e[e.BOTTOM_RIGHT = 2] = "BOTTOM_RIGHT", e[e.BOTTOM_LEFT = 3] = "BOTTOM_LEFT";
})(K || (K = {}));
var x = function(e, A, r, t, B) {
var n = 4 * ((Math.sqrt(2) - 1) / 3), s = r * n, a = t * n, i = e + r, o = A + t;
var n = 4 * ((Math.sqrt(2) - 1) / 3), s = r * n, i = t * n, a = e + r, o = A + t;
switch (B) {
case K.TOP_LEFT:
return new Se(new u(e, o), new u(e, o - a), new u(i - s, A), new u(i, A));
return new Se(new u(e, o), new u(e, o - i), new u(a - s, A), new u(a, A));
case K.TOP_RIGHT:
return new Se(new u(e, A), new u(e + s, A), new u(i, o - a), new u(i, o));
return new Se(new u(e, A), new u(e + s, A), new u(a, o - i), new u(a, o));
case K.BOTTOM_RIGHT:
return new Se(new u(i, A), new u(i, A + a), new u(e + s, o), new u(e, o));
return new Se(new u(a, A), new u(a, A + i), new u(e + s, o), new u(e, o));
case K.BOTTOM_LEFT:
default:
return new Se(new u(i, o), new u(i - s, o), new u(e, A + a), new u(e, A));
return new Se(new u(a, o), new u(a - s, o), new u(e, A + i), new u(e, A));
}
}, ze = function(e) {
return [e.topLeftBorderBox, e.topRightBorderBox, e.bottomRightBorderBox, e.bottomLeftBorderBox];
......@@ -4319,8 +4319,8 @@ var x = function(e, A, r, t, B) {
this.effects.push(new KQ(t, B, n));
}
if (this.container.styles.overflowX !== 0) {
var s = ze(this.curves), a = je(this.curves);
iB(s, a) ? this.effects.push(new Oe(
var s = ze(this.curves), i = je(this.curves);
iB(s, i) ? this.effects.push(new Oe(
s,
6
/* CONTENT */
......@@ -4329,7 +4329,7 @@ var x = function(e, A, r, t, B) {
2
/* BACKGROUND_BORDERS */
)), this.effects.push(new Oe(
a,
i,
4
/* CONTENT */
)));
......@@ -4341,8 +4341,8 @@ var x = function(e, A, r, t, B) {
3
/* FIXED */
].indexOf(this.container.styles.position) === -1, t = this.parent, B = this.effects.slice(0); t; ) {
var n = t.effects.filter(function(i) {
return !cn(i);
var n = t.effects.filter(function(a) {
return !cn(a);
});
if (r || t.container.styles.position !== 0 || !t.parent) {
if (B.unshift.apply(B, n), r = [
......@@ -4350,9 +4350,9 @@ var x = function(e, A, r, t, B) {
3
/* FIXED */
].indexOf(t.container.styles.position) === -1, t.container.styles.overflowX !== 0) {
var s = ze(t.curves), a = je(t.curves);
iB(s, a) || B.unshift(new Oe(
a,
var s = ze(t.curves), i = je(t.curves);
iB(s, i) || B.unshift(new Oe(
i,
6
/* CONTENT */
));
......@@ -4361,8 +4361,8 @@ var x = function(e, A, r, t, B) {
B.unshift.apply(B, n);
t = t.parent;
}
return B.filter(function(i) {
return G(i.target, A);
return B.filter(function(a) {
return G(a.target, A);
});
}, e;
}()
......@@ -4376,19 +4376,19 @@ var x = function(e, A, r, t, B) {
B.flags,
2
/* CREATES_STACKING_CONTEXT */
), a = new wn(B, e);
), i = new wn(B, e);
G(
B.styles.display,
2048
/* LIST_ITEM */
) && t.push(a);
var i = G(
) && t.push(i);
var a = G(
B.flags,
8
/* IS_LIST_OWNER */
) ? [] : t;
if (n || s) {
var o = n || B.styles.isPositioned() ? r : A, Q = new gn(a);
var o = n || B.styles.isPositioned() ? r : A, Q = new gn(i);
if (B.styles.isPositioned() || B.styles.opacity < 1 || B.styles.isTransformed()) {
var c = B.styles.zIndex.order;
if (c < 0) {
......@@ -4405,14 +4405,14 @@ var x = function(e, A, r, t, B) {
o.zeroOrAutoZIndexOrTransformedOrOpacity.push(Q);
} else
B.styles.isFloating() ? o.nonPositionedFloats.push(Q) : o.nonPositionedInlineLevel.push(Q);
At(a, Q, n ? Q : r, i);
At(i, Q, n ? Q : r, a);
} else
B.styles.isInlineLevel() ? A.inlineLevel.push(a) : A.nonInlineLevel.push(a), At(a, A, r, i);
B.styles.isInlineLevel() ? A.inlineLevel.push(i) : A.nonInlineLevel.push(i), At(i, A, r, a);
G(
B.flags,
8
/* IS_LIST_OWNER */
) && ln(B, i);
) && ln(B, a);
});
}, ln = function(e, A) {
for (var r = e instanceof Zr ? e.start : 1, t = e instanceof Zr ? e.reversed : !1, B = 0; B < A.length; B++) {
......@@ -4487,19 +4487,19 @@ var x = function(e, A, r, t, B) {
}, RQ = function(e, A) {
return e === 0 ? A.bounds : e === 2 ? $e(A) : un(A);
}, br = function(e, A, r) {
var t = GQ(PA(e.styles.backgroundOrigin, A), e), B = RQ(PA(e.styles.backgroundClip, A), e), n = VQ(PA(e.styles.backgroundSize, A), r, t), s = n[0], a = n[1], i = re(PA(e.styles.backgroundPosition, A), t.width - s, t.height - a), o = NQ(PA(e.styles.backgroundRepeat, A), i, n, t, B), Q = Math.round(t.left + i[0]), c = Math.round(t.top + i[1]);
return [o, Q, c, s, a];
var t = GQ(PA(e.styles.backgroundOrigin, A), e), B = RQ(PA(e.styles.backgroundClip, A), e), n = VQ(PA(e.styles.backgroundSize, A), r, t), s = n[0], i = n[1], a = re(PA(e.styles.backgroundPosition, A), t.width - s, t.height - i), o = NQ(PA(e.styles.backgroundRepeat, A), a, n, t, B), Q = Math.round(t.left + a[0]), c = Math.round(t.top + a[1]);
return [o, Q, c, s, i];
}, VA = function(e) {
return b(e) && e.value === _A.AUTO;
}, Ge = function(e) {
return typeof e == "number";
}, VQ = function(e, A, r) {
var t = A[0], B = A[1], n = A[2], s = e[0], a = e[1];
var t = A[0], B = A[1], n = A[2], s = e[0], i = e[1];
if (!s)
return [0, 0];
if (M(s) && a && M(a))
return [D(s, r.width), D(a, r.height)];
var i = Ge(n);
if (M(s) && i && M(i))
return [D(s, r.width), D(i, r.height)];
var a = Ge(n);
if (b(s) && (s.value === _A.CONTAIN || s.value === _A.COVER)) {
if (Ge(n)) {
var o = r.width / r.height;
......@@ -4508,52 +4508,52 @@ var x = function(e, A, r, t, B) {
return [r.width, r.height];
}
var Q = Ge(t), c = Ge(B), g = Q || c;
if (VA(s) && (!a || VA(a))) {
if (VA(s) && (!i || VA(i))) {
if (Q && c)
return [t, B];
if (!i && !g)
if (!a && !g)
return [r.width, r.height];
if (g && i) {
if (g && a) {
var f = Q ? t : B * n, w = c ? B : t / n;
return [f, w];
}
var l = Q ? t : r.width, H = c ? B : r.height;
return [l, H];
}
if (i) {
if (a) {
var h = 0, F = 0;
return M(s) ? h = D(s, r.width) : M(a) && (F = D(a, r.height)), VA(s) ? h = F * n : (!a || VA(a)) && (F = h / n), [h, F];
return M(s) ? h = D(s, r.width) : M(i) && (F = D(i, r.height)), VA(s) ? h = F * n : (!i || VA(i)) && (F = h / n), [h, F];
}
var y = null, p = null;
if (M(s) ? y = D(s, r.width) : a && M(a) && (p = D(a, r.height)), y !== null && (!a || VA(a)) && (p = Q && c ? y / t * B : r.height), p !== null && VA(s) && (y = Q && c ? p / B * t : r.width), y !== null && p !== null)
if (M(s) ? y = D(s, r.width) : i && M(i) && (p = D(i, r.height)), y !== null && (!i || VA(i)) && (p = Q && c ? y / t * B : r.height), p !== null && VA(s) && (y = Q && c ? p / B * t : r.width), y !== null && p !== null)
return [y, p];
throw new Error("Unable to calculate background-size for element");
}, PA = function(e, A) {
var r = e[A];
return typeof r > "u" ? e[0] : r;
}, NQ = function(e, A, r, t, B) {
var n = A[0], s = A[1], a = r[0], i = r[1];
var n = A[0], s = A[1], i = r[0], a = r[1];
switch (e) {
case 2:
return [
new u(Math.round(t.left), Math.round(t.top + s)),
new u(Math.round(t.left + t.width), Math.round(t.top + s)),
new u(Math.round(t.left + t.width), Math.round(i + t.top + s)),
new u(Math.round(t.left), Math.round(i + t.top + s))
new u(Math.round(t.left + t.width), Math.round(a + t.top + s)),
new u(Math.round(t.left), Math.round(a + t.top + s))
];
case 3:
return [
new u(Math.round(t.left + n), Math.round(t.top)),
new u(Math.round(t.left + n + a), Math.round(t.top)),
new u(Math.round(t.left + n + a), Math.round(t.height + t.top)),
new u(Math.round(t.left + n + i), Math.round(t.top)),
new u(Math.round(t.left + n + i), Math.round(t.height + t.top)),
new u(Math.round(t.left + n), Math.round(t.height + t.top))
];
case 1:
return [
new u(Math.round(t.left + n), Math.round(t.top + s)),
new u(Math.round(t.left + n + a), Math.round(t.top + s)),
new u(Math.round(t.left + n + a), Math.round(t.top + s + i)),
new u(Math.round(t.left + n), Math.round(t.top + s + i))
new u(Math.round(t.left + n + i), Math.round(t.top + s)),
new u(Math.round(t.left + n + i), Math.round(t.top + s + a)),
new u(Math.round(t.left + n), Math.round(t.top + s + a))
];
default:
return [
......@@ -4572,10 +4572,10 @@ var x = function(e, A, r, t, B) {
return e.prototype.parseMetrics = function(A, r) {
var t = this._document.createElement("div"), B = this._document.createElement("img"), n = this._document.createElement("span"), s = this._document.body;
t.style.visibility = "hidden", t.style.fontFamily = A, t.style.fontSize = r, t.style.margin = "0", t.style.padding = "0", t.style.whiteSpace = "nowrap", s.appendChild(t), B.src = PQ, B.width = 1, B.height = 1, B.style.margin = "0", B.style.padding = "0", B.style.verticalAlign = "baseline", n.style.fontFamily = A, n.style.fontSize = r, n.style.margin = "0", n.style.padding = "0", n.appendChild(this._document.createTextNode(QB)), t.appendChild(n), t.appendChild(B);
var a = B.offsetTop - n.offsetTop + 2;
var i = B.offsetTop - n.offsetTop + 2;
t.removeChild(n), t.appendChild(this._document.createTextNode(QB)), t.style.lineHeight = "normal", B.style.verticalAlign = "super";
var i = B.offsetTop - t.offsetTop + 2;
return s.removeChild(t), { baseline: a, middle: i };
var a = B.offsetTop - t.offsetTop + 2;
return s.removeChild(t), { baseline: i, middle: a };
}, e.prototype.getMetrics = function(A, r) {
var t = A + " " + r;
return typeof this._data[t] > "u" && (this._data[t] = this.parseMetrics(A, r)), this._data[t];
......@@ -4654,8 +4654,8 @@ var x = function(e, A, r, t, B) {
this.ctx.fillText(r.text, r.bounds.left, r.bounds.top + B);
else {
var s = it(r.text);
s.reduce(function(a, i) {
return n.ctx.fillText(i, a, r.bounds.top + B), a + n.ctx.measureText(i).width;
s.reduce(function(i, a) {
return n.ctx.fillText(a, i, r.bounds.top + B), i + n.ctx.measureText(a).width;
}, r.bounds.left);
}
}, A.prototype.createFontStyle = function(r) {
......@@ -4669,9 +4669,9 @@ var x = function(e, A, r, t, B) {
];
}, A.prototype.renderTextNode = function(r, t) {
return J(this, void 0, void 0, function() {
var B, n, s, a, i, o, Q, c, g = this;
var B, n, s, i, a, o, Q, c, g = this;
return X(this, function(f) {
return B = this.createFontStyle(t), n = B[0], s = B[1], a = B[2], this.ctx.font = n, this.ctx.direction = t.direction === 1 ? "rtl" : "ltr", this.ctx.textAlign = "left", this.ctx.textBaseline = "alphabetic", i = this.fontMetrics.getMetrics(s, a), o = i.baseline, Q = i.middle, c = t.paintOrder, r.textBounds.forEach(function(w) {
return B = this.createFontStyle(t), n = B[0], s = B[1], i = B[2], this.ctx.font = n, this.ctx.direction = t.direction === 1 ? "rtl" : "ltr", this.ctx.textAlign = "left", this.ctx.textBaseline = "alphabetic", a = this.fontMetrics.getMetrics(s, i), o = a.baseline, Q = a.middle, c = t.paintOrder, r.textBounds.forEach(function(w) {
c.forEach(function(l) {
switch (l) {
case 0:
......@@ -4711,16 +4711,16 @@ var x = function(e, A, r, t, B) {
}
}, A.prototype.renderNodeContent = function(r) {
return J(this, void 0, void 0, function() {
var t, B, n, s, a, i, F, F, o, Q, c, g, p, f, w, d, l, H, h, F, y, p, d;
var t, B, n, s, i, a, F, F, o, Q, c, g, p, f, w, d, l, H, h, F, y, p, d;
return X(this, function(C) {
switch (C.label) {
case 0:
this.applyEffects(r.getEffects(
4
/* CONTENT */
)), t = r.container, B = r.curves, n = t.styles, s = 0, a = t.textNodes, C.label = 1;
)), t = r.container, B = r.curves, n = t.styles, s = 0, i = t.textNodes, C.label = 1;
case 1:
return s < a.length ? (i = a[s], [4, this.renderTextNode(i, n)]) : [3, 4];
return s < i.length ? (a = i[s], [4, this.renderTextNode(a, n)]) : [3, 4];
case 2:
C.sent(), C.label = 3;
case 3:
......@@ -4812,7 +4812,7 @@ var x = function(e, A, r, t, B) {
});
}, A.prototype.renderStackContent = function(r) {
return J(this, void 0, void 0, function() {
var t, B, h, n, s, h, a, i, h, o, Q, h, c, g, h, f, w, h, l, H, h;
var t, B, h, n, s, h, i, a, h, o, Q, h, c, g, h, f, w, h, l, H, h;
return X(this, function(F) {
switch (F.label) {
case 0:
......@@ -4842,13 +4842,13 @@ var x = function(e, A, r, t, B) {
case 9:
return n++, [3, 7];
case 10:
a = 0, i = r.nonPositionedFloats, F.label = 11;
i = 0, a = r.nonPositionedFloats, F.label = 11;
case 11:
return a < i.length ? (h = i[a], [4, this.renderStack(h)]) : [3, 14];
return i < a.length ? (h = a[i], [4, this.renderStack(h)]) : [3, 14];
case 12:
F.sent(), F.label = 13;
case 13:
return a++, [3, 11];
return i++, [3, 11];
case 14:
o = 0, Q = r.nonPositionedInlineLevel, F.label = 15;
case 15:
......@@ -4905,13 +4905,13 @@ var x = function(e, A, r, t, B) {
var n;
if (r.width === t && r.height === B)
return r;
var s = (n = this.canvas.ownerDocument) !== null && n !== void 0 ? n : document, a = s.createElement("canvas");
a.width = Math.max(1, t), a.height = Math.max(1, B);
var i = a.getContext("2d");
return i.drawImage(r, 0, 0, r.width, r.height, 0, 0, t, B), a;
var s = (n = this.canvas.ownerDocument) !== null && n !== void 0 ? n : document, i = s.createElement("canvas");
i.width = Math.max(1, t), i.height = Math.max(1, B);
var a = i.getContext("2d");
return a.drawImage(r, 0, 0, r.width, r.height, 0, 0, t, B), i;
}, A.prototype.renderBackgroundImage = function(r) {
return J(this, void 0, void 0, function() {
var t, B, n, s, a, i;
var t, B, n, s, i, a;
return X(this, function(o) {
switch (o.label) {
case 0:
......@@ -4952,9 +4952,9 @@ var x = function(e, A, r, t, B) {
];
}
});
}, n = this, s = 0, a = r.styles.backgroundImage.slice(0).reverse(), o.label = 1;
}, n = this, s = 0, i = r.styles.backgroundImage.slice(0).reverse(), o.label = 1;
case 1:
return s < a.length ? (i = a[s], [5, B(i)]) : [3, 4];
return s < i.length ? (a = i[s], [5, B(a)]) : [3, 4];
case 2:
o.sent(), o.label = 3;
case 3:
......@@ -4978,18 +4978,18 @@ var x = function(e, A, r, t, B) {
});
}, A.prototype.renderDoubleBorder = function(r, t, B, n) {
return J(this, void 0, void 0, function() {
var s, a;
return X(this, function(i) {
switch (i.label) {
var s, i;
return X(this, function(a) {
switch (a.label) {
case 0:
return t < 3 ? [4, this.renderSolidBorder(r, B, n)] : [3, 2];
case 1:
return i.sent(), [
return a.sent(), [
2
/*return*/
];
case 2:
return s = SQ(n, B), this.path(s), this.ctx.fillStyle = R(r), this.ctx.fill(), a = OQ(n, B), this.path(a), this.ctx.fill(), [
return s = SQ(n, B), this.path(s), this.ctx.fillStyle = R(r), this.ctx.fill(), i = OQ(n, B), this.path(i), this.ctx.fill(), [
2
/*return*/
];
......@@ -4998,7 +4998,7 @@ var x = function(e, A, r, t, B) {
});
}, A.prototype.renderNodeBackgroundAndBorders = function(r) {
return J(this, void 0, void 0, function() {
var t, B, n, s, a, i, o, Q, c = this;
var t, B, n, s, i, a, o, Q, c = this;
return X(this, function(g) {
switch (g.label) {
case 0:
......@@ -5018,12 +5018,12 @@ var x = function(e, A, r, t, B) {
f.inset ? (c.path(w), c.ctx.clip(), c.mask(H)) : (c.mask(w), c.ctx.clip(), c.path(H)), c.ctx.shadowOffsetX = f.offsetX.number + l, c.ctx.shadowOffsetY = f.offsetY.number, c.ctx.shadowColor = R(f.color), c.ctx.shadowBlur = f.blur.number, c.ctx.fillStyle = f.inset ? R(f.color) : "rgba(0,0,0,1)", c.ctx.fill(), c.ctx.restore();
}), g.label = 2;
case 2:
a = 0, i = 0, o = n, g.label = 3;
i = 0, a = 0, o = n, g.label = 3;
case 3:
return i < o.length ? (Q = o[i], Q.style !== 0 && !HA(Q.color) && Q.width > 0 ? Q.style !== 2 ? [3, 5] : [4, this.renderDashedDottedBorder(
return a < o.length ? (Q = o[a], Q.style !== 0 && !HA(Q.color) && Q.width > 0 ? Q.style !== 2 ? [3, 5] : [4, this.renderDashedDottedBorder(
Q.color,
Q.width,
a,
i,
r.curves,
2
/* DASHED */
......@@ -5034,7 +5034,7 @@ var x = function(e, A, r, t, B) {
return Q.style !== 3 ? [3, 7] : [4, this.renderDashedDottedBorder(
Q.color,
Q.width,
a,
i,
r.curves,
3
/* DOTTED */
......@@ -5042,17 +5042,17 @@ var x = function(e, A, r, t, B) {
case 6:
return g.sent(), [3, 11];
case 7:
return Q.style !== 4 ? [3, 9] : [4, this.renderDoubleBorder(Q.color, Q.width, a, r.curves)];
return Q.style !== 4 ? [3, 9] : [4, this.renderDoubleBorder(Q.color, Q.width, i, r.curves)];
case 8:
return g.sent(), [3, 11];
case 9:
return [4, this.renderSolidBorder(Q.color, a, r.curves)];
return [4, this.renderSolidBorder(Q.color, i, r.curves)];
case 10:
g.sent(), g.label = 11;
case 11:
a++, g.label = 12;
i++, g.label = 12;
case 12:
return i++, [3, 3];
return a++, [3, 3];
case 13:
return [
2
......@@ -5063,9 +5063,9 @@ var x = function(e, A, r, t, B) {
});
}, A.prototype.renderDashedDottedBorder = function(r, t, B, n, s) {
return J(this, void 0, void 0, function() {
var a, i, o, Q, c, g, f, w, l, H, h, F, y, p, d, C, d, C;
var i, a, o, Q, c, g, f, w, l, H, h, F, y, p, d, C, d, C;
return X(this, function(v) {
return this.ctx.save(), a = MQ(n, B), i = oB(n, B), s === 2 && (this.path(i), this.ctx.clip()), $(i[0]) ? (o = i[0].start.x, Q = i[0].start.y) : (o = i[0].x, Q = i[0].y), $(i[1]) ? (c = i[1].end.x, g = i[1].end.y) : (c = i[1].x, g = i[1].y), B === 0 || B === 2 ? f = Math.abs(o - c) : f = Math.abs(Q - g), this.ctx.beginPath(), s === 3 ? this.formatPath(a) : this.formatPath(i.slice(0, 2)), w = t < 3 ? t * 3 : t * 2, l = t < 3 ? t * 2 : t, s === 3 && (w = t, l = t), H = !0, f <= w * 2 ? H = !1 : f <= w * 2 + l ? (h = f / (2 * w + l), w *= h, l *= h) : (F = Math.floor((f + l) / (w + l)), y = (f - F * w) / (F - 1), p = (f - (F + 1) * w) / F, l = p <= 0 || Math.abs(l - y) < Math.abs(l - p) ? y : p), H && (s === 3 ? this.ctx.setLineDash([0, w + l]) : this.ctx.setLineDash([w, l])), s === 3 ? (this.ctx.lineCap = "round", this.ctx.lineWidth = t) : this.ctx.lineWidth = t * 2 + 1.1, this.ctx.strokeStyle = R(r), this.ctx.stroke(), this.ctx.setLineDash([]), s === 2 && ($(i[0]) && (d = i[3], C = i[0], this.ctx.beginPath(), this.formatPath([new u(d.end.x, d.end.y), new u(C.start.x, C.start.y)]), this.ctx.stroke()), $(i[1]) && (d = i[1], C = i[2], this.ctx.beginPath(), this.formatPath([new u(d.end.x, d.end.y), new u(C.start.x, C.start.y)]), this.ctx.stroke())), this.ctx.restore(), [
return this.ctx.save(), i = MQ(n, B), a = oB(n, B), s === 2 && (this.path(a), this.ctx.clip()), $(a[0]) ? (o = a[0].start.x, Q = a[0].start.y) : (o = a[0].x, Q = a[0].y), $(a[1]) ? (c = a[1].end.x, g = a[1].end.y) : (c = a[1].x, g = a[1].y), B === 0 || B === 2 ? f = Math.abs(o - c) : f = Math.abs(Q - g), this.ctx.beginPath(), s === 3 ? this.formatPath(i) : this.formatPath(a.slice(0, 2)), w = t < 3 ? t * 3 : t * 2, l = t < 3 ? t * 2 : t, s === 3 && (w = t, l = t), H = !0, f <= w * 2 ? H = !1 : f <= w * 2 + l ? (h = f / (2 * w + l), w *= h, l *= h) : (F = Math.floor((f + l) / (w + l)), y = (f - F * w) / (F - 1), p = (f - (F + 1) * w) / F, l = p <= 0 || Math.abs(l - y) < Math.abs(l - p) ? y : p), H && (s === 3 ? this.ctx.setLineDash([0, w + l]) : this.ctx.setLineDash([w, l])), s === 3 ? (this.ctx.lineCap = "round", this.ctx.lineWidth = t) : this.ctx.lineWidth = t * 2 + 1.1, this.ctx.strokeStyle = R(r), this.ctx.stroke(), this.ctx.setLineDash([]), s === 2 && ($(a[0]) && (d = a[3], C = a[0], this.ctx.beginPath(), this.formatPath([new u(d.end.x, d.end.y), new u(C.start.x, C.start.y)]), this.ctx.stroke()), $(a[1]) && (d = a[1], C = a[2], this.ctx.beginPath(), this.formatPath([new u(d.end.x, d.end.y), new u(C.start.x, C.start.y)]), this.ctx.stroke())), this.ctx.restore(), [
2
/*return*/
];
......@@ -5182,7 +5182,7 @@ var x = function(e, A, r, t, B) {
typeof window < "u" && Qn.setContext(window);
var rc = function(e, A) {
return J(void 0, void 0, void 0, function() {
var r, t, B, n, s, a, i, o, Q, c, g, f, w, l, H, h, F, y, p, d, v, C, v, m, E, O, k, q, L, V, lA, W, Y, IA, BA, uA, vA, mA, iA, yA;
var r, t, B, n, s, i, a, o, Q, c, g, f, w, l, H, h, F, y, p, d, v, C, v, m, E, O, k, q, L, V, lA, W, Y, IA, BA, uA, vA, mA, iA, yA;
return X(this, function(oA) {
switch (oA.label) {
case 0:
......@@ -5202,15 +5202,15 @@ var rc = function(e, A) {
windowHeight: (L = A.windowHeight) !== null && L !== void 0 ? L : t.innerHeight,
scrollX: (V = A.scrollX) !== null && V !== void 0 ? V : t.pageXOffset,
scrollY: (lA = A.scrollY) !== null && lA !== void 0 ? lA : t.pageYOffset
}, a = new wA(s.scrollX, s.scrollY, s.windowWidth, s.windowHeight), i = new Ac(n, a), o = (W = A.foreignObjectRendering) !== null && W !== void 0 ? W : !1, Q = {
}, i = new wA(s.scrollX, s.scrollY, s.windowWidth, s.windowHeight), a = new Ac(n, i), o = (W = A.foreignObjectRendering) !== null && W !== void 0 ? W : !1, Q = {
allowTaint: (Y = A.allowTaint) !== null && Y !== void 0 ? Y : !1,
onclone: A.onclone,
ignoreElements: A.ignoreElements,
inlineImages: o,
copyStyles: o
}, i.logger.debug("Starting document clone with size " + a.width + "x" + a.height + " scrolled to " + -a.left + "," + -a.top), c = new sB(i, e, Q), g = c.clonedReferenceElement, g ? [4, c.toIFrame(r, a)] : [2, Promise.reject("Unable to find element in cloned iframe")];
}, a.logger.debug("Starting document clone with size " + i.width + "x" + i.height + " scrolled to " + -i.left + "," + -i.top), c = new sB(a, e, Q), g = c.clonedReferenceElement, g ? [4, c.toIFrame(r, i)] : [2, Promise.reject("Unable to find element in cloned iframe")];
case 1:
return f = oA.sent(), w = Qt(g) || tQ(g) ? Dn(g.ownerDocument) : Ar(i, g), l = w.width, H = w.height, h = w.left, F = w.top, y = tc(i, g, A.backgroundColor), p = {
return f = oA.sent(), w = Qt(g) || tQ(g) ? Dn(g.ownerDocument) : Ar(a, g), l = w.width, H = w.height, h = w.left, F = w.top, y = tc(a, g, A.backgroundColor), p = {
canvas: A.canvas,
backgroundColor: y,
scale: (BA = (IA = A.scale) !== null && IA !== void 0 ? IA : t.devicePixelRatio) !== null && BA !== void 0 ? BA : 1,
......@@ -5218,15 +5218,15 @@ var rc = function(e, A) {
y: ((vA = A.y) !== null && vA !== void 0 ? vA : 0) + F,
width: (mA = A.width) !== null && mA !== void 0 ? mA : Math.ceil(l),
height: (iA = A.height) !== null && iA !== void 0 ? iA : Math.ceil(H)
}, o ? (i.logger.debug("Document cloned, using foreign object rendering"), v = new zQ(i, p), [4, v.render(g)]) : [3, 3];
}, o ? (a.logger.debug("Document cloned, using foreign object rendering"), v = new zQ(a, p), [4, v.render(g)]) : [3, 3];
case 2:
return d = oA.sent(), [3, 5];
case 3:
return i.logger.debug("Document cloned, element located at " + h + "," + F + " with size " + l + "x" + H + " using computed rendering"), i.logger.debug("Starting DOM parsing"), C = en(i, g), y === C.styles.backgroundColor && (C.styles.backgroundColor = gA.TRANSPARENT), i.logger.debug("Starting renderer for element at " + p.x + "," + p.y + " with size " + p.width + "x" + p.height), v = new JQ(i, p), [4, v.render(C)];
return a.logger.debug("Document cloned, element located at " + h + "," + F + " with size " + l + "x" + H + " using computed rendering"), a.logger.debug("Starting DOM parsing"), C = en(a, g), y === C.styles.backgroundColor && (C.styles.backgroundColor = gA.TRANSPARENT), a.logger.debug("Starting renderer for element at " + p.x + "," + p.y + " with size " + p.width + "x" + p.height), v = new JQ(a, p), [4, v.render(C)];
case 4:
d = oA.sent(), oA.label = 5;
case 5:
return (!((yA = A.removeContainer) !== null && yA !== void 0) || yA) && (sB.destroy(f) || i.logger.error("Cannot detach cloned iframe as it is not in the DOM anymore")), i.logger.debug("Finished rendering"), [2, d];
return (!((yA = A.removeContainer) !== null && yA !== void 0) || yA) && (sB.destroy(f) || a.logger.error("Cannot detach cloned iframe as it is not in the DOM anymore")), a.logger.debug("Finished rendering"), [2, d];
}
});
});
......@@ -5260,10 +5260,10 @@ class Bc extends Fn {
windowHeight: B * 2,
scale: window.devicePixelRatio
}).then(function(n) {
const s = n.toDataURL("image/png").replace("image/png", "image/octet-stream"), a = document.createElement("a");
a.href = s;
let i = "downLoad.png";
A && A[0] && (i = `${A[0].srfmajortext}.png`), a.download = i, a.click();
const s = n.toDataURL("image/png").replace("image/png", "image/octet-stream"), i = document.createElement("a");
i.href = s;
let a = "downLoad.png";
A && A[0] && (a = `${A[0].srfmajortext}.png`), i.download = a, i.click();
});
}
}
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册