@sv-print/hiprint 0.1.7-beta4 → 0.1.7-beta5
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 +15 -15
- package/dist/index.mjs +654 -654
- package/dist/index.umd.js +15 -15
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -10,36 +10,36 @@ var He = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : t
|
|
|
10
10
|
q.exports = g(x);
|
|
11
11
|
})(function(g) {
|
|
12
12
|
function W(a) {
|
|
13
|
-
var
|
|
14
|
-
a.removeData("minicolors-initialized").removeData("minicolors-settings").removeProp("size").removeClass("minicolors-input"),
|
|
13
|
+
var c = a.parent();
|
|
14
|
+
a.removeData("minicolors-initialized").removeData("minicolors-settings").removeProp("size").removeClass("minicolors-input"), c.before(a).remove();
|
|
15
15
|
}
|
|
16
16
|
function E(a) {
|
|
17
|
-
var
|
|
18
|
-
!a.data("minicolors-initialized") || a.prop("disabled") ||
|
|
17
|
+
var c = a.parent(), h = c.find(".minicolors-panel"), M = a.data("minicolors-settings");
|
|
18
|
+
!a.data("minicolors-initialized") || a.prop("disabled") || c.hasClass("minicolors-inline") || c.hasClass("minicolors-focus") || (b(), c.addClass("minicolors-focus"), h.animate ? h.stop(!0, !0).fadeIn(M.showSpeed, function() {
|
|
19
19
|
M.show && M.show.call(a.get(0));
|
|
20
20
|
}) : (h.show(), M.show && M.show.call(a.get(0))));
|
|
21
21
|
}
|
|
22
22
|
function b() {
|
|
23
23
|
g(".minicolors-focus").each(function() {
|
|
24
|
-
var a = g(this),
|
|
24
|
+
var a = g(this), c = a.find(".minicolors-input"), h = a.find(".minicolors-panel"), M = c.data("minicolors-settings");
|
|
25
25
|
h.animate ? h.fadeOut(M.hideSpeed, function() {
|
|
26
|
-
M.hide && M.hide.call(
|
|
27
|
-
}) : (h.hide(), M.hide && M.hide.call(
|
|
26
|
+
M.hide && M.hide.call(c.get(0)), a.removeClass("minicolors-focus");
|
|
27
|
+
}) : (h.hide(), M.hide && M.hide.call(c.get(0)), a.removeClass("minicolors-focus"));
|
|
28
28
|
});
|
|
29
29
|
}
|
|
30
|
-
function l(a,
|
|
31
|
-
var M, u, d, A, Z, L = a.parents(".minicolors").find(".minicolors-input"), J = L.data("minicolors-settings"), Y = a.find("[class$=-picker]"), R = a.offset().left, V = a.offset().top, $ = Math.round(
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
}) : (Y.css(Z),
|
|
30
|
+
function l(a, c, h) {
|
|
31
|
+
var M, u, d, A, Z, L = a.parents(".minicolors").find(".minicolors-input"), J = L.data("minicolors-settings"), Y = a.find("[class$=-picker]"), R = a.offset().left, V = a.offset().top, $ = Math.round(c.pageX - R), z = Math.round(c.pageY - V), et = h ? J.animationSpeed : 0;
|
|
32
|
+
c.originalEvent.changedTouches && ($ = c.originalEvent.changedTouches[0].pageX - R, z = c.originalEvent.changedTouches[0].pageY - V), $ < 0 && ($ = 0), z < 0 && (z = 0), $ > a.width() && ($ = a.width()), z > a.height() && (z = a.height()), a.parent().is(".minicolors-slider-wheel") && Y.parent().is(".minicolors-grid") && (M = 75 - $, u = 75 - z, d = Math.sqrt(M * M + u * u), (A = Math.atan2(u, M)) < 0 && (A += 2 * Math.PI), 75 < d && ($ = (d = 75) - 75 * Math.cos(A), z = 75 - 75 * Math.sin(A)), $ = Math.round($), z = Math.round(z)), Z = { top: z + "px" }, a.is(".minicolors-grid") && (Z.left = $ + "px"), Y.animate ? Y.stop(!0).animate(Z, et, J.animationEasing, function() {
|
|
33
|
+
I(L, a);
|
|
34
|
+
}) : (Y.css(Z), I(L, a));
|
|
35
35
|
}
|
|
36
|
-
function
|
|
36
|
+
function I(a, c) {
|
|
37
37
|
function h(lt, vt) {
|
|
38
38
|
var yt, Mt;
|
|
39
39
|
return lt.length && vt ? (yt = lt.offset().left, Mt = lt.offset().top, { x: yt - vt.offset().left + lt.outerWidth() / 2, y: Mt - vt.offset().top + lt.outerHeight() / 2 }) : null;
|
|
40
40
|
}
|
|
41
41
|
var M, u, d, A, Z, L, J, Y = a.val(), R = a.attr("data-opacity"), V = a.parent(), $ = a.data("minicolors-settings"), z = V.find(".minicolors-input-swatch"), et = V.find(".minicolors-grid"), ot = V.find(".minicolors-slider"), pt = V.find(".minicolors-opacity-slider"), st = et.find("[class$=-picker]"), ht = ot.find("[class$=-picker]"), mt = pt.find("[class$=-picker]"), ut = h(st, et), bt = h(ht, ot), dt = h(mt, pt);
|
|
42
|
-
if (
|
|
42
|
+
if (c.is(".minicolors-grid, .minicolors-slider, .minicolors-opacity-slider")) {
|
|
43
43
|
switch ($.control) {
|
|
44
44
|
case "wheel":
|
|
45
45
|
A = et.width() / 2 - ut.x, Z = et.height() / 2 - ut.y, L = Math.sqrt(A * A + Z * Z), (J = Math.atan2(Z, A)) < 0 && (J += 2 * Math.PI), 75 < L && (L = 75, ut.x = 69 - 75 * Math.cos(J), ut.y = 69 - 75 * Math.sin(J)), u = D(L / 0.75, 0, 100), Y = o({ h: M = D(180 * J / Math.PI, 0, 360), s: u, b: d = D(100 - Math.floor(bt.y * (100 / ot.height())), 0, 100) }), ot.css("backgroundColor", o({ h: M, s: u, b: 100 }));
|
|
@@ -57,11 +57,11 @@ var He = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : t
|
|
|
57
57
|
} else
|
|
58
58
|
z.find("span").css({ backgroundColor: Y, opacity: String(R) }), C(a, Y, R);
|
|
59
59
|
}
|
|
60
|
-
function s(a,
|
|
60
|
+
function s(a, c, h) {
|
|
61
61
|
var M, u = a.parent(), d = a.data("minicolors-settings"), A = u.find(".minicolors-input-swatch");
|
|
62
|
-
d.opacity && a.attr("data-opacity", h),
|
|
62
|
+
d.opacity && a.attr("data-opacity", h), c = d.format === "rgb" ? (M = H(c) ? T(c, !0) : m(r(c, !0)), h = a.attr("data-opacity") === "" ? 1 : D(parseFloat(a.attr("data-opacity")).toFixed(2), 0, 1), !isNaN(h) && d.opacity || (h = 1), a.minicolors("rgbObject").a <= 1 && M && d.opacity ? "rgba(" + M.r + ", " + M.g + ", " + M.b + ", " + parseFloat(h) + ")" : "rgb(" + M.r + ", " + M.g + ", " + M.b + ")") : (H(c) && (c = v(c)), N(c, d.letterCase)), a.val(c), A.find("span").css({ backgroundColor: c, opacity: String(h) }), C(a, c, h);
|
|
63
63
|
}
|
|
64
|
-
function w(a,
|
|
64
|
+
function w(a, c) {
|
|
65
65
|
var h, M, u, d, A, Z, L, J, Y, R, V = a.parent(), $ = a.data("minicolors-settings"), z = V.find(".minicolors-input-swatch"), et = V.find(".minicolors-grid"), ot = V.find(".minicolors-slider"), pt = V.find(".minicolors-opacity-slider"), st = et.find("[class$=-picker]"), ht = ot.find("[class$=-picker]"), mt = pt.find("[class$=-picker]");
|
|
66
66
|
switch (H(a.val()) ? (h = v(a.val()), (A = D(parseFloat(j(a.val())).toFixed(2), 0, 1)) && a.attr("data-opacity", A)) : h = N(r(a.val(), !0), $.letterCase), M = function(ut) {
|
|
67
67
|
var bt = function(dt) {
|
|
@@ -71,7 +71,7 @@ var He = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : t
|
|
|
71
71
|
return bt.s === 0 && (bt.h = 360), bt;
|
|
72
72
|
}(h = h || N(S($.defaultValue, !0), $.letterCase)), d = $.keywords ? g.map($.keywords.split(","), function(ut) {
|
|
73
73
|
return ut.toLowerCase().trim();
|
|
74
|
-
}) : [], Z = a.val() !== "" && -1 < g.inArray(a.val().toLowerCase(), d) ? N(a.val()) : H(a.val()) ? T(a.val()) : h,
|
|
74
|
+
}) : [], Z = a.val() !== "" && -1 < g.inArray(a.val().toLowerCase(), d) ? N(a.val()) : H(a.val()) ? T(a.val()) : h, c || a.val(Z), $.opacity && (u = a.attr("data-opacity") === "" ? 1 : D(parseFloat(a.attr("data-opacity")).toFixed(2), 0, 1), isNaN(u) && (u = 1), a.attr("data-opacity", u), z.find("span").css("opacity", String(u)), J = D(pt.height() - pt.height() * u, 0, pt.height()), mt.css("top", J + "px")), a.val().toLowerCase() === "transparent" && z.find("span").css("opacity", String(0)), z.find("span").css("backgroundColor", h), $.control) {
|
|
75
75
|
case "wheel":
|
|
76
76
|
Y = D(Math.ceil(0.75 * M.s), 0, et.height() / 2), R = M.h * Math.PI / 180, L = D(75 - Math.cos(R) * Y, 0, et.width()), J = D(75 - Math.sin(R) * Y, 0, et.height()), st.css({ top: J + "px", left: L + "px" }), J = 150 - M.b / (100 / et.height()), h === "" && (J = 0), ht.css("top", J + "px"), ot.css("backgroundColor", o({ h: M.h, s: M.s, b: 100 }));
|
|
77
77
|
break;
|
|
@@ -86,11 +86,11 @@ var He = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : t
|
|
|
86
86
|
}
|
|
87
87
|
a.data("minicolors-initialized") && C(a, Z, u);
|
|
88
88
|
}
|
|
89
|
-
function C(a,
|
|
89
|
+
function C(a, c, h) {
|
|
90
90
|
var M, u, d, A = a.data("minicolors-settings"), Z = a.data("minicolors-lastChange");
|
|
91
|
-
if (!Z || Z.value !==
|
|
92
|
-
if (a.data("minicolors-lastChange", { value:
|
|
93
|
-
for (M = H(
|
|
91
|
+
if (!Z || Z.value !== c || Z.opacity !== h) {
|
|
92
|
+
if (a.data("minicolors-lastChange", { value: c, opacity: h }), A.swatches && A.swatches.length !== 0) {
|
|
93
|
+
for (M = H(c) ? T(c, !0) : m(c), u = -1, d = 0; d < A.swatches.length; ++d)
|
|
94
94
|
if (M.r === A.swatches[d].r && M.g === A.swatches[d].g && M.b === A.swatches[d].b && M.a === A.swatches[d].a) {
|
|
95
95
|
u = d;
|
|
96
96
|
break;
|
|
@@ -98,29 +98,29 @@ var He = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : t
|
|
|
98
98
|
a.parent().find(".minicolors-swatches .minicolors-swatch").removeClass("selected"), u !== -1 && a.parent().find(".minicolors-swatches .minicolors-swatch").eq(d).addClass("selected");
|
|
99
99
|
}
|
|
100
100
|
A.change && (A.changeDelay ? (clearTimeout(a.data("minicolors-changeTimeout")), a.data("minicolors-changeTimeout", setTimeout(function() {
|
|
101
|
-
A.change.call(a.get(0),
|
|
102
|
-
}, A.changeDelay))) : A.change.call(a.get(0),
|
|
101
|
+
A.change.call(a.get(0), c, h);
|
|
102
|
+
}, A.changeDelay))) : A.change.call(a.get(0), c, h)), a.trigger("change").trigger("input");
|
|
103
103
|
}
|
|
104
104
|
}
|
|
105
|
-
function N(a,
|
|
106
|
-
return
|
|
105
|
+
function N(a, c) {
|
|
106
|
+
return c === "uppercase" ? a.toUpperCase() : a.toLowerCase();
|
|
107
107
|
}
|
|
108
|
-
function r(a,
|
|
109
|
-
return !(a = a.replace(/^#/g, "")).match(/^[A-F0-9]{3,6}/gi) || a.length !== 3 && a.length !== 6 ? "" : (a.length === 3 &&
|
|
108
|
+
function r(a, c) {
|
|
109
|
+
return !(a = a.replace(/^#/g, "")).match(/^[A-F0-9]{3,6}/gi) || a.length !== 3 && a.length !== 6 ? "" : (a.length === 3 && c && (a = a[0] + a[0] + a[1] + a[1] + a[2] + a[2]), "#" + a);
|
|
110
110
|
}
|
|
111
|
-
function T(a,
|
|
111
|
+
function T(a, c) {
|
|
112
112
|
var h = a.replace(/[^\d,.]/g, "").split(",");
|
|
113
|
-
return h[0] = D(parseInt(h[0], 10), 0, 255), h[1] = D(parseInt(h[1], 10), 0, 255), h[2] = D(parseInt(h[2], 10), 0, 255), h[3] !== void 0 && (h[3] = D(parseFloat(h[3], 10), 0, 1)),
|
|
113
|
+
return h[0] = D(parseInt(h[0], 10), 0, 255), h[1] = D(parseInt(h[1], 10), 0, 255), h[2] = D(parseInt(h[2], 10), 0, 255), h[3] !== void 0 && (h[3] = D(parseFloat(h[3], 10), 0, 1)), c ? h[3] !== void 0 ? { r: h[0], g: h[1], b: h[2], a: h[3] } : { r: h[0], g: h[1], b: h[2] } : h[3] !== void 0 && h[3] <= 1 ? "rgba(" + h[0] + ", " + h[1] + ", " + h[2] + ", " + h[3] + ")" : "rgb(" + h[0] + ", " + h[1] + ", " + h[2] + ")";
|
|
114
114
|
}
|
|
115
|
-
function S(a,
|
|
116
|
-
return H(a) ? T(a) : r(a,
|
|
115
|
+
function S(a, c) {
|
|
116
|
+
return H(a) ? T(a) : r(a, c);
|
|
117
117
|
}
|
|
118
|
-
function D(a,
|
|
119
|
-
return a <
|
|
118
|
+
function D(a, c, h) {
|
|
119
|
+
return a < c && (a = c), h < a && (a = h), a;
|
|
120
120
|
}
|
|
121
121
|
function H(a) {
|
|
122
|
-
var
|
|
123
|
-
return !(!
|
|
122
|
+
var c = a.match(/^rgba?[\s+]?\([\s+]?(\d+)[\s+]?,[\s+]?(\d+)[\s+]?,[\s+]?(\d+)[\s+]?/i);
|
|
123
|
+
return !(!c || c.length !== 4);
|
|
124
124
|
}
|
|
125
125
|
function j(a) {
|
|
126
126
|
return (a = a.match(/^rgba?[\s+]?\([\s+]?(\d+)[\s+]?,[\s+]?(\d+)[\s+]?,[\s+]?(\d+)[\s+]?,[\s+]?(\d+(\.\d{1,2})?|\.\d{1,2})[\s+]?/i)) && a.length === 6 ? a[4] : "1";
|
|
@@ -129,19 +129,19 @@ var He = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : t
|
|
|
129
129
|
return (a = a.match(/^rgba?[\s+]?\([\s+]?(\d+)[\s+]?,[\s+]?(\d+)[\s+]?,[\s+]?(\d+)[\s+]?/i)) && a.length === 4 ? "#" + ("0" + parseInt(a[1], 10).toString(16)).slice(-2) + ("0" + parseInt(a[2], 10).toString(16)).slice(-2) + ("0" + parseInt(a[3], 10).toString(16)).slice(-2) : "";
|
|
130
130
|
}
|
|
131
131
|
function P(a) {
|
|
132
|
-
var
|
|
133
|
-
return g.each(
|
|
134
|
-
M.length === 1 && (
|
|
135
|
-
}), "#" +
|
|
132
|
+
var c = [a.r.toString(16), a.g.toString(16), a.b.toString(16)];
|
|
133
|
+
return g.each(c, function(h, M) {
|
|
134
|
+
M.length === 1 && (c[h] = "0" + M);
|
|
135
|
+
}), "#" + c.join("");
|
|
136
136
|
}
|
|
137
137
|
function o(a) {
|
|
138
|
-
return P((
|
|
139
|
-
var
|
|
138
|
+
return P((c = a, d = {}, A = Math.round(c.h), Z = Math.round(255 * c.s / 100), L = Math.round(255 * c.b / 100), Z === 0 ? d.r = d.g = d.b = L : (u = A % 60 * ((h = L) - (M = (255 - Z) * L / 255)) / 60, A === 360 && (A = 0), A < 60 ? (d.r = h, d.b = M, d.g = M + u) : A < 120 ? (d.g = h, d.b = M, d.r = h - u) : A < 180 ? (d.g = h, d.r = M, d.b = M + u) : A < 240 ? (d.b = h, d.r = M, d.g = h - u) : A < 300 ? (d.b = h, d.g = M, d.r = M + u) : A < 360 ? (d.r = h, d.g = M, d.b = h - u) : (d.r = 0, d.g = 0, d.b = 0)), { r: Math.round(d.r), g: Math.round(d.g), b: Math.round(d.b) }));
|
|
139
|
+
var c, h, M, u, d, A, Z, L;
|
|
140
140
|
}
|
|
141
141
|
function m(a) {
|
|
142
142
|
return { r: (a = parseInt(-1 < a.indexOf("#") ? a.substring(1) : a, 16)) >> 16, g: (65280 & a) >> 8, b: 255 & a };
|
|
143
143
|
}
|
|
144
|
-
g.minicolors = { defaults: { animationSpeed: 50, animationEasing: "swing", change: null, changeDelay: 0, control: "hue", defaultValue: "", format: "hex", hide: null, hideSpeed: 100, inline: !1, keywords: "", letterCase: "lowercase", opacity: !1, position: "bottom", show: null, showSpeed: 100, theme: "default", swatches: [] } }, g.extend(g.fn, { minicolors: function(a,
|
|
144
|
+
g.minicolors = { defaults: { animationSpeed: 50, animationEasing: "swing", change: null, changeDelay: 0, control: "hue", defaultValue: "", format: "hex", hide: null, hideSpeed: 100, inline: !1, keywords: "", letterCase: "lowercase", opacity: !1, position: "bottom", show: null, showSpeed: 100, theme: "default", swatches: [] } }, g.extend(g.fn, { minicolors: function(a, c) {
|
|
145
145
|
switch (a) {
|
|
146
146
|
case "destroy":
|
|
147
147
|
return g(this).each(function() {
|
|
@@ -150,8 +150,8 @@ var He = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : t
|
|
|
150
150
|
case "hide":
|
|
151
151
|
return b(), g(this);
|
|
152
152
|
case "opacity":
|
|
153
|
-
return
|
|
154
|
-
w(g(this).attr("data-opacity",
|
|
153
|
+
return c === void 0 ? g(this).attr("data-opacity") : (g(this).each(function() {
|
|
154
|
+
w(g(this).attr("data-opacity", c));
|
|
155
155
|
}), g(this));
|
|
156
156
|
case "rgbObject":
|
|
157
157
|
return function(h) {
|
|
@@ -173,18 +173,18 @@ var He = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : t
|
|
|
173
173
|
return u ? (d === void 0 && (d = 1), M ? "rgba(" + u.r + ", " + u.g + ", " + u.b + ", " + parseFloat(d) + ")" : "rgb(" + u.r + ", " + u.g + ", " + u.b + ")") : null;
|
|
174
174
|
}(g(this), a === "rgbaString");
|
|
175
175
|
case "settings":
|
|
176
|
-
return
|
|
176
|
+
return c === void 0 ? g(this).data("minicolors-settings") : (g(this).each(function() {
|
|
177
177
|
var h = g(this).data("minicolors-settings") || {};
|
|
178
|
-
W(g(this)), g(this).minicolors(g.extend(!0, h,
|
|
178
|
+
W(g(this)), g(this).minicolors(g.extend(!0, h, c));
|
|
179
179
|
}), g(this));
|
|
180
180
|
case "show":
|
|
181
181
|
return E(g(this).eq(0)), g(this);
|
|
182
182
|
case "value":
|
|
183
|
-
return
|
|
184
|
-
typeof
|
|
183
|
+
return c === void 0 ? g(this).val() : (g(this).each(function() {
|
|
184
|
+
typeof c == "object" && c !== null ? (c.opacity !== void 0 && g(this).attr("data-opacity", D(c.opacity, 0, 1)), c.color && g(this).val(c.color)) : g(this).val(c), w(g(this));
|
|
185
185
|
}), g(this));
|
|
186
186
|
default:
|
|
187
|
-
return a !== "create" && (
|
|
187
|
+
return a !== "create" && (c = a), g(this).each(function() {
|
|
188
188
|
(function(h, M) {
|
|
189
189
|
var u, d, A, Z, L, J, Y, R = g('<div class="minicolors" />'), V = g.minicolors.defaults;
|
|
190
190
|
if (!h.data("minicolors-initialized")) {
|
|
@@ -199,44 +199,44 @@ var He = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : t
|
|
|
199
199
|
Z = typeof M.swatches[Y] == "object" ? (u = M.swatches[Y].name, M.swatches[Y].color) : (u = "", M.swatches[Y]), Z = H(L = Z) ? T(Z, !0) : m(r(Z, !0)), g('<li class="minicolors-swatch minicolors-sprite"><span class="minicolors-swatch-color"></span></li>').attr("title", u).appendTo(A).data("swatch-color", L).find(".minicolors-swatch-color").css({ backgroundColor: L !== "transparent" ? P(Z) : "transparent", opacity: String(Z.a) }), M.swatches[Y] = Z;
|
|
200
200
|
M.inline && h.parent().addClass("minicolors-inline"), w(h, !1), h.data("minicolors-initialized", !0);
|
|
201
201
|
}
|
|
202
|
-
})(g(this),
|
|
202
|
+
})(g(this), c);
|
|
203
203
|
}), g(this);
|
|
204
204
|
}
|
|
205
205
|
} }), g([document]).on("mousedown.minicolors touchstart.minicolors", function(a) {
|
|
206
206
|
g(a.target).parents().add(a.target).hasClass("minicolors") || b();
|
|
207
207
|
}).on("mousedown.minicolors touchstart.minicolors", ".minicolors-grid, .minicolors-slider, .minicolors-opacity-slider", function(a) {
|
|
208
|
-
var
|
|
209
|
-
a.preventDefault(), g(a.delegateTarget).data("minicolors-target",
|
|
208
|
+
var c = g(this);
|
|
209
|
+
a.preventDefault(), g(a.delegateTarget).data("minicolors-target", c), l(c, a, !0);
|
|
210
210
|
}).on("mousemove.minicolors touchmove.minicolors", function(a) {
|
|
211
|
-
var
|
|
212
|
-
|
|
211
|
+
var c = g(a.delegateTarget).data("minicolors-target");
|
|
212
|
+
c && l(c, a);
|
|
213
213
|
}).on("mouseup.minicolors touchend.minicolors", function() {
|
|
214
214
|
g(this).removeData("minicolors-target");
|
|
215
215
|
}).on("click.minicolors", ".minicolors-swatches li", function(a) {
|
|
216
216
|
a.preventDefault();
|
|
217
|
-
var
|
|
217
|
+
var c = g(this), h = c.parents(".minicolors").find(".minicolors-input"), M = c.data("swatch-color");
|
|
218
218
|
s(h, M, j(M)), w(h);
|
|
219
219
|
}).on("mousedown.minicolors touchstart.minicolors", ".minicolors-input-swatch", function(a) {
|
|
220
|
-
var
|
|
221
|
-
a.preventDefault(), E(
|
|
220
|
+
var c = g(this).parent().find(".minicolors-input");
|
|
221
|
+
a.preventDefault(), E(c);
|
|
222
222
|
}).on("focus.minicolors", ".minicolors-input", function() {
|
|
223
223
|
var a = g(this);
|
|
224
224
|
a.data("minicolors-initialized") && E(a);
|
|
225
225
|
}).on("blur.minicolors", ".minicolors-input", function() {
|
|
226
|
-
var a,
|
|
226
|
+
var a, c, h, M, u, d = g(this), A = d.data("minicolors-settings");
|
|
227
227
|
d.data("minicolors-initialized") && (a = A.keywords ? g.map(A.keywords.split(","), function(Z) {
|
|
228
228
|
return Z.toLowerCase().trim();
|
|
229
|
-
}) : [], u = d.val() !== "" && -1 < g.inArray(d.val().toLowerCase(), a) ? d.val() : (h = H(d.val()) ? T(d.val(), !0) : (
|
|
229
|
+
}) : [], u = d.val() !== "" && -1 < g.inArray(d.val().toLowerCase(), a) ? d.val() : (h = H(d.val()) ? T(d.val(), !0) : (c = r(d.val(), !0)) ? m(c) : null) === null ? A.defaultValue : A.format === "rgb" ? A.opacity ? T("rgba(" + h.r + "," + h.g + "," + h.b + "," + d.attr("data-opacity") + ")") : T("rgb(" + h.r + "," + h.g + "," + h.b + ")") : P(h), M = A.opacity ? d.attr("data-opacity") : 1, u.toLowerCase() === "transparent" && (M = 0), d.closest(".minicolors").find(".minicolors-input-swatch > span").css("opacity", String(M)), d.val(u), d.val() === "" && d.val(S(A.defaultValue, !0)), d.val(N(d.val(), A.letterCase)));
|
|
230
230
|
}).on("keydown.minicolors", ".minicolors-input", function(a) {
|
|
231
|
-
var
|
|
232
|
-
if (
|
|
231
|
+
var c = g(this);
|
|
232
|
+
if (c.data("minicolors-initialized"))
|
|
233
233
|
switch (a.which) {
|
|
234
234
|
case 9:
|
|
235
235
|
b();
|
|
236
236
|
break;
|
|
237
237
|
case 13:
|
|
238
238
|
case 27:
|
|
239
|
-
b(),
|
|
239
|
+
b(), c.blur();
|
|
240
240
|
}
|
|
241
241
|
}).on("keyup.minicolors", ".minicolors-input", function() {
|
|
242
242
|
var a = g(this);
|
|
@@ -253,8 +253,8 @@ var He = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : t
|
|
|
253
253
|
function q(o) {
|
|
254
254
|
this.mode = g.MODE_8BIT_BYTE, this.data = o, this.parsedData = [];
|
|
255
255
|
for (var m = 0, a = this.data.length; m < a; m++) {
|
|
256
|
-
var
|
|
257
|
-
h > 65536 ? (
|
|
256
|
+
var c = [], h = this.data.charCodeAt(m);
|
|
257
|
+
h > 65536 ? (c[0] = 240 | (h & 1835008) >>> 18, c[1] = 128 | (h & 258048) >>> 12, c[2] = 128 | (h & 4032) >>> 6, c[3] = 128 | h & 63) : h > 2048 ? (c[0] = 224 | (h & 61440) >>> 12, c[1] = 128 | (h & 4032) >>> 6, c[2] = 128 | h & 63) : h > 128 ? (c[0] = 192 | (h & 1984) >>> 6, c[1] = 128 | h & 63) : c[0] = h, this.parsedData.push(c);
|
|
258
258
|
}
|
|
259
259
|
this.parsedData = Array.prototype.concat.apply([], this.parsedData), this.parsedData.length != this.data.length && (this.parsedData.unshift(191), this.parsedData.unshift(187), this.parsedData.unshift(239));
|
|
260
260
|
}
|
|
@@ -290,34 +290,34 @@ var He = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : t
|
|
|
290
290
|
this.moduleCount = this.typeNumber * 4 + 17, this.modules = new Array(this.moduleCount);
|
|
291
291
|
for (var a = 0; a < this.moduleCount; a++) {
|
|
292
292
|
this.modules[a] = new Array(this.moduleCount);
|
|
293
|
-
for (var
|
|
294
|
-
this.modules[a][
|
|
293
|
+
for (var c = 0; c < this.moduleCount; c++)
|
|
294
|
+
this.modules[a][c] = null;
|
|
295
295
|
}
|
|
296
296
|
this.setupPositionProbePattern(0, 0), this.setupPositionProbePattern(this.moduleCount - 7, 0), this.setupPositionProbePattern(0, this.moduleCount - 7), this.setupPositionAdjustPattern(), this.setupTimingPattern(), this.setupTypeInfo(o, m), this.typeNumber >= 7 && this.setupTypeNumber(o), this.dataCache == null && (this.dataCache = F.createData(this.typeNumber, this.errorCorrectLevel, this.dataList)), this.mapData(this.dataCache, m);
|
|
297
297
|
},
|
|
298
298
|
setupPositionProbePattern: function(o, m) {
|
|
299
299
|
for (var a = -1; a <= 7; a++)
|
|
300
300
|
if (!(o + a <= -1 || this.moduleCount <= o + a))
|
|
301
|
-
for (var
|
|
302
|
-
m +
|
|
301
|
+
for (var c = -1; c <= 7; c++)
|
|
302
|
+
m + c <= -1 || this.moduleCount <= m + c || (0 <= a && a <= 6 && (c == 0 || c == 6) || 0 <= c && c <= 6 && (a == 0 || a == 6) || 2 <= a && a <= 4 && 2 <= c && c <= 4 ? this.modules[o + a][m + c] = !0 : this.modules[o + a][m + c] = !1);
|
|
303
303
|
},
|
|
304
304
|
getBestMaskPattern: function() {
|
|
305
305
|
for (var o = 0, m = 0, a = 0; a < 8; a++) {
|
|
306
306
|
this.makeImpl(!0, a);
|
|
307
|
-
var
|
|
308
|
-
(a == 0 || o >
|
|
307
|
+
var c = b.getLostPoint(this);
|
|
308
|
+
(a == 0 || o > c) && (o = c, m = a);
|
|
309
309
|
}
|
|
310
310
|
return m;
|
|
311
311
|
},
|
|
312
312
|
createMovieClip: function(o, m, a) {
|
|
313
|
-
var
|
|
313
|
+
var c = o.createEmptyMovieClip(m, a), h = 1;
|
|
314
314
|
this.make();
|
|
315
315
|
for (var M = 0; M < this.modules.length; M++)
|
|
316
316
|
for (var u = M * h, d = 0; d < this.modules[M].length; d++) {
|
|
317
317
|
var A = d * h, Z = this.modules[M][d];
|
|
318
|
-
Z && (
|
|
318
|
+
Z && (c.beginFill(0, 100), c.moveTo(A, u), c.lineTo(A + h, u), c.lineTo(A + h, u + h), c.lineTo(A, u + h), c.endFill());
|
|
319
319
|
}
|
|
320
|
-
return
|
|
320
|
+
return c;
|
|
321
321
|
},
|
|
322
322
|
setupTimingPattern: function() {
|
|
323
323
|
for (var o = 8; o < this.moduleCount - 8; o++)
|
|
@@ -328,68 +328,68 @@ var He = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : t
|
|
|
328
328
|
setupPositionAdjustPattern: function() {
|
|
329
329
|
for (var o = b.getPatternPosition(this.typeNumber), m = 0; m < o.length; m++)
|
|
330
330
|
for (var a = 0; a < o.length; a++) {
|
|
331
|
-
var
|
|
332
|
-
if (this.modules[
|
|
331
|
+
var c = o[m], h = o[a];
|
|
332
|
+
if (this.modules[c][h] == null)
|
|
333
333
|
for (var M = -2; M <= 2; M++)
|
|
334
334
|
for (var u = -2; u <= 2; u++)
|
|
335
|
-
M == -2 || M == 2 || u == -2 || u == 2 || M == 0 && u == 0 ? this.modules[
|
|
335
|
+
M == -2 || M == 2 || u == -2 || u == 2 || M == 0 && u == 0 ? this.modules[c + M][h + u] = !0 : this.modules[c + M][h + u] = !1;
|
|
336
336
|
}
|
|
337
337
|
},
|
|
338
338
|
setupTypeNumber: function(o) {
|
|
339
339
|
for (var m = b.getBCHTypeNumber(this.typeNumber), a = 0; a < 18; a++) {
|
|
340
|
-
var
|
|
341
|
-
this.modules[Math.floor(a / 3)][a % 3 + this.moduleCount - 8 - 3] =
|
|
340
|
+
var c = !o && (m >> a & 1) == 1;
|
|
341
|
+
this.modules[Math.floor(a / 3)][a % 3 + this.moduleCount - 8 - 3] = c;
|
|
342
342
|
}
|
|
343
343
|
for (var a = 0; a < 18; a++) {
|
|
344
|
-
var
|
|
345
|
-
this.modules[a % 3 + this.moduleCount - 8 - 3][Math.floor(a / 3)] =
|
|
344
|
+
var c = !o && (m >> a & 1) == 1;
|
|
345
|
+
this.modules[a % 3 + this.moduleCount - 8 - 3][Math.floor(a / 3)] = c;
|
|
346
346
|
}
|
|
347
347
|
},
|
|
348
348
|
setupTypeInfo: function(o, m) {
|
|
349
|
-
for (var a = this.errorCorrectLevel << 3 | m,
|
|
350
|
-
var M = !o && (
|
|
349
|
+
for (var a = this.errorCorrectLevel << 3 | m, c = b.getBCHTypeInfo(a), h = 0; h < 15; h++) {
|
|
350
|
+
var M = !o && (c >> h & 1) == 1;
|
|
351
351
|
h < 6 ? this.modules[h][8] = M : h < 8 ? this.modules[h + 1][8] = M : this.modules[this.moduleCount - 15 + h][8] = M;
|
|
352
352
|
}
|
|
353
353
|
for (var h = 0; h < 15; h++) {
|
|
354
|
-
var M = !o && (
|
|
354
|
+
var M = !o && (c >> h & 1) == 1;
|
|
355
355
|
h < 8 ? this.modules[8][this.moduleCount - h - 1] = M : h < 9 ? this.modules[8][15 - h - 1 + 1] = M : this.modules[8][15 - h - 1] = M;
|
|
356
356
|
}
|
|
357
357
|
this.modules[this.moduleCount - 8][8] = !o;
|
|
358
358
|
},
|
|
359
359
|
mapData: function(o, m) {
|
|
360
|
-
for (var a = -1,
|
|
360
|
+
for (var a = -1, c = this.moduleCount - 1, h = 7, M = 0, u = this.moduleCount - 1; u > 0; u -= 2)
|
|
361
361
|
for (u == 6 && u--; ; ) {
|
|
362
362
|
for (var d = 0; d < 2; d++)
|
|
363
|
-
if (this.modules[
|
|
363
|
+
if (this.modules[c][u - d] == null) {
|
|
364
364
|
var A = !1;
|
|
365
365
|
M < o.length && (A = (o[M] >>> h & 1) == 1);
|
|
366
|
-
var Z = b.getMask(m,
|
|
367
|
-
Z && (A = !A), this.modules[
|
|
366
|
+
var Z = b.getMask(m, c, u - d);
|
|
367
|
+
Z && (A = !A), this.modules[c][u - d] = A, h--, h == -1 && (M++, h = 7);
|
|
368
368
|
}
|
|
369
|
-
if (
|
|
370
|
-
|
|
369
|
+
if (c += a, c < 0 || this.moduleCount <= c) {
|
|
370
|
+
c -= a, a = -a;
|
|
371
371
|
break;
|
|
372
372
|
}
|
|
373
373
|
}
|
|
374
374
|
}
|
|
375
375
|
}, F.PAD0 = 236, F.PAD1 = 17, F.createData = function(o, m, a) {
|
|
376
|
-
for (var
|
|
376
|
+
for (var c = w.getRSBlocks(o, m), h = new C(), M = 0; M < a.length; M++) {
|
|
377
377
|
var u = a[M];
|
|
378
378
|
h.put(u.mode, 4), h.put(u.getLength(), b.getLengthInBits(u.mode, o)), u.write(h);
|
|
379
379
|
}
|
|
380
|
-
for (var d = 0, M = 0; M <
|
|
381
|
-
d +=
|
|
380
|
+
for (var d = 0, M = 0; M < c.length; M++)
|
|
381
|
+
d += c[M].dataCount;
|
|
382
382
|
if (h.getLengthInBits() > d * 8)
|
|
383
383
|
throw new Error("code length overflow. (" + h.getLengthInBits() + ">" + d * 8 + ")");
|
|
384
384
|
for (h.getLengthInBits() + 4 <= d * 8 && h.put(0, 4); h.getLengthInBits() % 8 != 0; )
|
|
385
385
|
h.putBit(!1);
|
|
386
386
|
for (; !(h.getLengthInBits() >= d * 8 || (h.put(F.PAD0, 8), h.getLengthInBits() >= d * 8)); )
|
|
387
387
|
h.put(F.PAD1, 8);
|
|
388
|
-
return F.createBytes(h,
|
|
388
|
+
return F.createBytes(h, c);
|
|
389
389
|
}, F.createBytes = function(o, m) {
|
|
390
|
-
for (var a = 0,
|
|
390
|
+
for (var a = 0, c = 0, h = 0, M = new Array(m.length), u = new Array(m.length), d = 0; d < m.length; d++) {
|
|
391
391
|
var A = m[d].dataCount, Z = m[d].totalCount - A;
|
|
392
|
-
|
|
392
|
+
c = Math.max(c, A), h = Math.max(h, Z), M[d] = new Array(A);
|
|
393
393
|
for (var L = 0; L < M[d].length; L++)
|
|
394
394
|
M[d][L] = 255 & o.buffer[L + a];
|
|
395
395
|
a += A;
|
|
@@ -402,7 +402,7 @@ var He = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : t
|
|
|
402
402
|
}
|
|
403
403
|
for (var $ = 0, L = 0; L < m.length; L++)
|
|
404
404
|
$ += m[L].totalCount;
|
|
405
|
-
for (var z = new Array($), et = 0, L = 0; L <
|
|
405
|
+
for (var z = new Array($), et = 0, L = 0; L < c; L++)
|
|
406
406
|
for (var d = 0; d < m.length; d++)
|
|
407
407
|
L < M[d].length && (z[et++] = M[d][L]);
|
|
408
408
|
for (var L = 0; L < h; L++)
|
|
@@ -564,28 +564,28 @@ var He = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : t
|
|
|
564
564
|
throw new Error("type:" + m);
|
|
565
565
|
},
|
|
566
566
|
getLostPoint: function(o) {
|
|
567
|
-
for (var m = o.getModuleCount(), a = 0,
|
|
567
|
+
for (var m = o.getModuleCount(), a = 0, c = 0; c < m; c++)
|
|
568
568
|
for (var h = 0; h < m; h++) {
|
|
569
|
-
for (var M = 0, u = o.isDark(
|
|
570
|
-
if (!(
|
|
569
|
+
for (var M = 0, u = o.isDark(c, h), d = -1; d <= 1; d++)
|
|
570
|
+
if (!(c + d < 0 || m <= c + d))
|
|
571
571
|
for (var A = -1; A <= 1; A++)
|
|
572
|
-
h + A < 0 || m <= h + A || d == 0 && A == 0 || u == o.isDark(
|
|
572
|
+
h + A < 0 || m <= h + A || d == 0 && A == 0 || u == o.isDark(c + d, h + A) && M++;
|
|
573
573
|
M > 5 && (a += 3 + M - 5);
|
|
574
574
|
}
|
|
575
|
-
for (var
|
|
575
|
+
for (var c = 0; c < m - 1; c++)
|
|
576
576
|
for (var h = 0; h < m - 1; h++) {
|
|
577
577
|
var Z = 0;
|
|
578
|
-
o.isDark(
|
|
578
|
+
o.isDark(c, h) && Z++, o.isDark(c + 1, h) && Z++, o.isDark(c, h + 1) && Z++, o.isDark(c + 1, h + 1) && Z++, (Z == 0 || Z == 4) && (a += 3);
|
|
579
579
|
}
|
|
580
|
-
for (var
|
|
580
|
+
for (var c = 0; c < m; c++)
|
|
581
581
|
for (var h = 0; h < m - 6; h++)
|
|
582
|
-
o.isDark(
|
|
582
|
+
o.isDark(c, h) && !o.isDark(c, h + 1) && o.isDark(c, h + 2) && o.isDark(c, h + 3) && o.isDark(c, h + 4) && !o.isDark(c, h + 5) && o.isDark(c, h + 6) && (a += 40);
|
|
583
583
|
for (var h = 0; h < m; h++)
|
|
584
|
-
for (var
|
|
585
|
-
o.isDark(
|
|
584
|
+
for (var c = 0; c < m - 6; c++)
|
|
585
|
+
o.isDark(c, h) && !o.isDark(c + 1, h) && o.isDark(c + 2, h) && o.isDark(c + 3, h) && o.isDark(c + 4, h) && !o.isDark(c + 5, h) && o.isDark(c + 6, h) && (a += 40);
|
|
586
586
|
for (var L = 0, h = 0; h < m; h++)
|
|
587
|
-
for (var
|
|
588
|
-
o.isDark(
|
|
587
|
+
for (var c = 0; c < m; c++)
|
|
588
|
+
o.isDark(c, h) && L++;
|
|
589
589
|
var J = Math.abs(100 * L / m / m - 50) / 5;
|
|
590
590
|
return a += J * 10, a;
|
|
591
591
|
}
|
|
@@ -604,20 +604,20 @@ var He = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : t
|
|
|
604
604
|
},
|
|
605
605
|
EXP_TABLE: new Array(256),
|
|
606
606
|
LOG_TABLE: new Array(256)
|
|
607
|
-
},
|
|
608
|
-
l.EXP_TABLE[
|
|
609
|
-
for (var
|
|
610
|
-
l.EXP_TABLE[
|
|
611
|
-
for (var
|
|
612
|
-
l.LOG_TABLE[l.EXP_TABLE[
|
|
607
|
+
}, I = 0; I < 8; I++)
|
|
608
|
+
l.EXP_TABLE[I] = 1 << I;
|
|
609
|
+
for (var I = 8; I < 256; I++)
|
|
610
|
+
l.EXP_TABLE[I] = l.EXP_TABLE[I - 4] ^ l.EXP_TABLE[I - 5] ^ l.EXP_TABLE[I - 6] ^ l.EXP_TABLE[I - 8];
|
|
611
|
+
for (var I = 0; I < 255; I++)
|
|
612
|
+
l.LOG_TABLE[l.EXP_TABLE[I]] = I;
|
|
613
613
|
function s(o, m) {
|
|
614
614
|
if (o.length == null)
|
|
615
615
|
throw new Error(o.length + "/" + m);
|
|
616
616
|
for (var a = 0; a < o.length && o[a] == 0; )
|
|
617
617
|
a++;
|
|
618
618
|
this.num = new Array(o.length - a + m);
|
|
619
|
-
for (var
|
|
620
|
-
this.num[
|
|
619
|
+
for (var c = 0; c < o.length - a; c++)
|
|
620
|
+
this.num[c] = o[c + a];
|
|
621
621
|
}
|
|
622
622
|
s.prototype = {
|
|
623
623
|
get: function(o) {
|
|
@@ -628,17 +628,17 @@ var He = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : t
|
|
|
628
628
|
},
|
|
629
629
|
multiply: function(o) {
|
|
630
630
|
for (var m = new Array(this.getLength() + o.getLength() - 1), a = 0; a < this.getLength(); a++)
|
|
631
|
-
for (var
|
|
632
|
-
m[a +
|
|
631
|
+
for (var c = 0; c < o.getLength(); c++)
|
|
632
|
+
m[a + c] ^= l.gexp(l.glog(this.get(a)) + l.glog(o.get(c)));
|
|
633
633
|
return new s(m, 0);
|
|
634
634
|
},
|
|
635
635
|
mod: function(o) {
|
|
636
636
|
if (this.getLength() - o.getLength() < 0)
|
|
637
637
|
return this;
|
|
638
|
-
for (var m = l.glog(this.get(0)) - l.glog(o.get(0)), a = new Array(this.getLength()),
|
|
639
|
-
a[
|
|
640
|
-
for (var
|
|
641
|
-
a[
|
|
638
|
+
for (var m = l.glog(this.get(0)) - l.glog(o.get(0)), a = new Array(this.getLength()), c = 0; c < this.getLength(); c++)
|
|
639
|
+
a[c] = this.get(c);
|
|
640
|
+
for (var c = 0; c < o.getLength(); c++)
|
|
641
|
+
a[c] ^= l.gexp(l.glog(o.get(c)) + m);
|
|
642
642
|
return new s(a, 0).mod(o);
|
|
643
643
|
}
|
|
644
644
|
};
|
|
@@ -810,7 +810,7 @@ var He = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : t
|
|
|
810
810
|
var a = w.getRsBlockTable(o, m);
|
|
811
811
|
if (a == null)
|
|
812
812
|
throw new Error("bad rs block @ typeNumber:" + o + "/errorCorrectLevel:" + m);
|
|
813
|
-
for (var
|
|
813
|
+
for (var c = a.length / 3, h = [], M = 0; M < c; M++)
|
|
814
814
|
for (var u = a[M * 3 + 0], d = a[M * 3 + 1], A = a[M * 3 + 2], Z = 0; Z < u; Z++)
|
|
815
815
|
h.push(new w(d, A));
|
|
816
816
|
return h;
|
|
@@ -907,7 +907,7 @@ var He = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : t
|
|
|
907
907
|
this._el = m, this._htOption = a;
|
|
908
908
|
};
|
|
909
909
|
return o.prototype.draw = function(m) {
|
|
910
|
-
var a = this._htOption,
|
|
910
|
+
var a = this._htOption, c = this._el, h = m.getModuleCount();
|
|
911
911
|
Math.floor(a.width / h), Math.floor(a.height / h), this.clear();
|
|
912
912
|
function M(L, J) {
|
|
913
913
|
var Y = document.createElementNS("http://www.w3.org/2000/svg", L);
|
|
@@ -921,7 +921,7 @@ var He = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : t
|
|
|
921
921
|
height: "100%",
|
|
922
922
|
fill: a.colorLight
|
|
923
923
|
});
|
|
924
|
-
u.setAttributeNS("http://www.w3.org/2000/xmlns/", "xmlns:xlink", "http://www.w3.org/1999/xlink"),
|
|
924
|
+
u.setAttributeNS("http://www.w3.org/2000/xmlns/", "xmlns:xlink", "http://www.w3.org/1999/xlink"), c.appendChild(u), u.appendChild(
|
|
925
925
|
M("rect", {
|
|
926
926
|
fill: a.colorLight,
|
|
927
927
|
width: "100%",
|
|
@@ -963,7 +963,7 @@ var He = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : t
|
|
|
963
963
|
a.apply(this, arguments);
|
|
964
964
|
};
|
|
965
965
|
}
|
|
966
|
-
function
|
|
966
|
+
function c(M, u) {
|
|
967
967
|
var d = this;
|
|
968
968
|
if (d._fFail = u, d._fSuccess = M, d._bSupportDataURI === null) {
|
|
969
969
|
var A = document.createElement("img"), Z = function() {
|
|
@@ -989,7 +989,7 @@ var He = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : t
|
|
|
989
989
|
}
|
|
990
990
|
this._bIsPainted = !0;
|
|
991
991
|
}, h.prototype.makeImage = function() {
|
|
992
|
-
this._bIsPainted &&
|
|
992
|
+
this._bIsPainted && c.call(this, o);
|
|
993
993
|
}, h.prototype.isPainted = function() {
|
|
994
994
|
return this._bIsPainted;
|
|
995
995
|
}, h.prototype.clear = function() {
|
|
@@ -1002,7 +1002,7 @@ var He = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : t
|
|
|
1002
1002
|
this._el = m, this._htOption = a;
|
|
1003
1003
|
};
|
|
1004
1004
|
return o.prototype.draw = function(m) {
|
|
1005
|
-
for (var a = this._htOption,
|
|
1005
|
+
for (var a = this._htOption, c = this._el, h = m.getModuleCount(), M = Math.floor(a.width / h), u = Math.floor(a.height / h), d = ['<table style="border:0;border-collapse:collapse;">'], A = 0; A < h; A++) {
|
|
1006
1006
|
d.push("<tr>");
|
|
1007
1007
|
for (var Z = 0; Z < h; Z++)
|
|
1008
1008
|
d.push(
|
|
@@ -1010,15 +1010,15 @@ var He = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : t
|
|
|
1010
1010
|
);
|
|
1011
1011
|
d.push("</tr>");
|
|
1012
1012
|
}
|
|
1013
|
-
d.push("</table>"),
|
|
1014
|
-
var L =
|
|
1013
|
+
d.push("</table>"), c.innerHTML = d.join("");
|
|
1014
|
+
var L = c.childNodes[0], J = (a.width - L.offsetWidth) / 2, Y = (a.height - L.offsetHeight) / 2;
|
|
1015
1015
|
J > 0 && Y > 0 && (L.style.margin = Y + "px " + J + "px");
|
|
1016
1016
|
}, o.prototype.clear = function() {
|
|
1017
1017
|
this._el.innerHTML = "";
|
|
1018
1018
|
}, o;
|
|
1019
1019
|
}();
|
|
1020
1020
|
function j(o, m) {
|
|
1021
|
-
for (var a = 1,
|
|
1021
|
+
for (var a = 1, c = v(o), h = 0, M = N.length; h <= M; h++) {
|
|
1022
1022
|
var u = 0;
|
|
1023
1023
|
switch (m) {
|
|
1024
1024
|
case W.L:
|
|
@@ -1034,7 +1034,7 @@ var He = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : t
|
|
|
1034
1034
|
u = N[h][3];
|
|
1035
1035
|
break;
|
|
1036
1036
|
}
|
|
1037
|
-
if (
|
|
1037
|
+
if (c <= u)
|
|
1038
1038
|
break;
|
|
1039
1039
|
a++;
|
|
1040
1040
|
}
|
|
@@ -1073,7 +1073,7 @@ function Ne(q, F = "YYYY-MM-DD") {
|
|
|
1073
1073
|
if (!q)
|
|
1074
1074
|
return null;
|
|
1075
1075
|
typeof q == "number" && (q = new Date(q));
|
|
1076
|
-
const g = q.getFullYear(), W = q.getMonth(), E = q.getDate(), b = q.getHours(), l = b % 12 === 0 ? 12 : b % 12,
|
|
1076
|
+
const g = q.getFullYear(), W = q.getMonth(), E = q.getDate(), b = q.getHours(), l = b % 12 === 0 ? 12 : b % 12, I = q.getMinutes(), s = q.getSeconds(), w = (N) => `0${N}`.slice(-2), C = {
|
|
1077
1077
|
YYYY: g,
|
|
1078
1078
|
MM: w(W + 1),
|
|
1079
1079
|
MMMM: `${W + 1}\u6708`,
|
|
@@ -1084,8 +1084,8 @@ function Ne(q, F = "YYYY-MM-DD") {
|
|
|
1084
1084
|
H: b,
|
|
1085
1085
|
hh: w(l),
|
|
1086
1086
|
h: l,
|
|
1087
|
-
mm: w(
|
|
1088
|
-
m:
|
|
1087
|
+
mm: w(I),
|
|
1088
|
+
m: I,
|
|
1089
1089
|
ss: w(s),
|
|
1090
1090
|
s
|
|
1091
1091
|
};
|
|
@@ -1117,7 +1117,7 @@ function Qt(q) {
|
|
|
1117
1117
|
container: E,
|
|
1118
1118
|
width: b,
|
|
1119
1119
|
height: l,
|
|
1120
|
-
textAlign:
|
|
1120
|
+
textAlign: I,
|
|
1121
1121
|
textBaseline: s,
|
|
1122
1122
|
fontSize: w,
|
|
1123
1123
|
fontFamily: C,
|
|
@@ -1135,12 +1135,12 @@ function Qt(q) {
|
|
|
1135
1135
|
H.setAttribute("width", `${b}px`), H.setAttribute("height", `${l}px`);
|
|
1136
1136
|
let j = typeof E == "string" ? document.querySelector(E) : E;
|
|
1137
1137
|
const v = H.getContext("2d");
|
|
1138
|
-
v.textAlign =
|
|
1138
|
+
v.textAlign = I, v.textBaseline = s, v.font = `${w} ${C}`, v.fillStyle = N, v.translate(b / 2, l / 2), v.rotate(-(Math.PI / 180) * r), v.fillText(`${W}`, 0, 0), T && v.fillText(`${Ne(new Date(), S)}`, 0, parseInt(w) + 5);
|
|
1139
1139
|
let P = j.querySelector(".__vm__" + F);
|
|
1140
1140
|
const o = P || document.createElement("div"), a = `position:absolute;user-select:none;top:0;left:0;${j.getAttribute("style")};z-index:${D};pointer-events:none !important;background-repeat:repeat;background-image:url('${H.toDataURL()}')`;
|
|
1141
1141
|
if (o.setAttribute("style", a), o.classList.add("__vm__" + F), P || j.insertBefore(o, j.firstChild), g) {
|
|
1142
|
-
const
|
|
1143
|
-
|
|
1142
|
+
const c = window.MutationObserver || window.WebKitMutationObserver;
|
|
1143
|
+
c && (St[F].wmMo = new c((h) => {
|
|
1144
1144
|
let M = h.some((u) => u.target.className == j.className && u.type == "attributes");
|
|
1145
1145
|
P = j.querySelector(".__vm__" + F), (P && P.getAttribute("style") !== a || !P || M) && (St[F].wmMo.disconnect(), St[F].wmMo = null, delete St[F].wmMo, Qt(q));
|
|
1146
1146
|
}), St[F].wmMo.observe(j, {
|
|
@@ -1150,10 +1150,10 @@ function Qt(q) {
|
|
|
1150
1150
|
}));
|
|
1151
1151
|
}
|
|
1152
1152
|
if (S) {
|
|
1153
|
-
let
|
|
1154
|
-
S.includes("s") ?
|
|
1153
|
+
let c = 864e5;
|
|
1154
|
+
S.includes("s") ? c = 1e3 : S.includes("m") ? c = 1e3 * 60 : (S.includes("h") || S.includes("H")) && (c = 1e3 * 60 * 60), St[F].wmTimer = window.setTimeout(() => {
|
|
1155
1155
|
o.style.bottom = "0";
|
|
1156
|
-
},
|
|
1156
|
+
}, c);
|
|
1157
1157
|
}
|
|
1158
1158
|
}
|
|
1159
1159
|
const Xt = function(q) {
|
|
@@ -1189,12 +1189,12 @@ var _t = { exports: {} };
|
|
|
1189
1189
|
return v = { exports: {} }, j(v, v.exports), v.exports;
|
|
1190
1190
|
}
|
|
1191
1191
|
function W(j, v) {
|
|
1192
|
-
var P =
|
|
1192
|
+
var P = I.getNumbResult(j);
|
|
1193
1193
|
if (!P)
|
|
1194
1194
|
return j;
|
|
1195
1195
|
v = v || {};
|
|
1196
|
-
var o = this.ch, m = this.ch_u, a = this.ch_f || "",
|
|
1197
|
-
et =
|
|
1196
|
+
var o = this.ch, m = this.ch_u, a = this.ch_f || "", c = this.ch_d || ".", h = o.charAt(0), M = P.int, u = P.decimal, d = P.minus, A = "", Z = "", L = d ? a : "", J = function z(et, ot, pt) {
|
|
1197
|
+
et = I.getNumbResult(et).int;
|
|
1198
1198
|
var st = "", ht = arguments.length > 1 ? arguments[1] : v.tenMin, mt = et.length;
|
|
1199
1199
|
if (mt == 1)
|
|
1200
1200
|
return o.charAt(+et);
|
|
@@ -1209,13 +1209,13 @@ var _t = { exports: {} };
|
|
|
1209
1209
|
var yt = et.substr(0, vt), Mt = et.substr(vt);
|
|
1210
1210
|
st = z(yt, ht) + m.charAt(3 + lt) + (Mt.charAt(0) == "0" ? h : "") + z(Mt, Mt.length > 4 && ht);
|
|
1211
1211
|
}
|
|
1212
|
-
return st =
|
|
1212
|
+
return st = I.clearZero(st, h);
|
|
1213
1213
|
};
|
|
1214
1214
|
if (u) {
|
|
1215
|
-
u =
|
|
1215
|
+
u = I.clearZero(u, "0", "$");
|
|
1216
1216
|
for (var Y = 0; Y < u.length; Y++)
|
|
1217
1217
|
Z += o.charAt(+u.charAt(Y));
|
|
1218
|
-
Z = Z ?
|
|
1218
|
+
Z = Z ? c + Z : "";
|
|
1219
1219
|
}
|
|
1220
1220
|
if (A = J(M), v.ww && m.length > 5) {
|
|
1221
1221
|
var R = m.charAt(4), V = m.charAt(5), $ = A.lastIndexOf(V);
|
|
@@ -1225,18 +1225,18 @@ var _t = { exports: {} };
|
|
|
1225
1225
|
}
|
|
1226
1226
|
function E(j) {
|
|
1227
1227
|
j = j.toString();
|
|
1228
|
-
var v = j.split(this.ch_d), P = v[0].replace(this.ch_f, ""), o = v[1], m = !!~v[0].indexOf(this.ch_f), a = this.ch_u.charAt(1),
|
|
1229
|
-
P = P.replace(new RegExp(
|
|
1228
|
+
var v = j.split(this.ch_d), P = v[0].replace(this.ch_f, ""), o = v[1], m = !!~v[0].indexOf(this.ch_f), a = this.ch_u.charAt(1), c = this.ch_u.charAt(4), h = this.ch_u.charAt(5);
|
|
1229
|
+
P = P.replace(new RegExp(c + "{2}", "g"), h);
|
|
1230
1230
|
for (var M = P.split(""), u = 0, d = 0, A = [], Z = [], L = [], J = 0; J < M.length; J++) {
|
|
1231
1231
|
var Y = M[J], R = 0, V = 0;
|
|
1232
1232
|
if (~(R = this.ch.indexOf(Y)))
|
|
1233
1233
|
R > 0 && L.unshift(R);
|
|
1234
1234
|
else if (~(V = this.ch_u.indexOf(Y))) {
|
|
1235
|
-
var $ =
|
|
1236
|
-
u > V ? (
|
|
1235
|
+
var $ = I.getDigit(V);
|
|
1236
|
+
u > V ? (I.unshiftZero(L, $), I.centerArray(Z, L)) : V >= d ? (J == 0 && (L = [1]), I.centerArray(A, Z, L), A.length > 0 && I.unshiftZero(A, $), d = V) : (L.length == 0 && a == Y && (L = [1]), I.centerArray(Z, L), I.unshiftZero(Z, I.getDigit(V)), u = V);
|
|
1237
1237
|
}
|
|
1238
1238
|
}
|
|
1239
|
-
|
|
1239
|
+
I.centerArray(A, Z, L).reverse(), A.length == 0 && A.push(0);
|
|
1240
1240
|
var z = 0;
|
|
1241
1241
|
if (o) {
|
|
1242
1242
|
A.push("."), z = "0.";
|
|
@@ -1247,41 +1247,41 @@ var _t = { exports: {} };
|
|
|
1247
1247
|
return m && A.unshift("-"), parseFloat(A.join(""));
|
|
1248
1248
|
}
|
|
1249
1249
|
function b(j, v) {
|
|
1250
|
-
var P = { ww: !0, complete: !1, outSymbol: !0 }, o =
|
|
1250
|
+
var P = { ww: !0, complete: !1, outSymbol: !0 }, o = I.getNumbResult(j), m = this.ch.charAt(0);
|
|
1251
1251
|
if (v = typeof v == "object" ? v : {}, !o)
|
|
1252
1252
|
return j;
|
|
1253
|
-
v =
|
|
1254
|
-
var a = o.num,
|
|
1253
|
+
v = I.extend(P, v);
|
|
1254
|
+
var a = o.num, c = o.decimal || "", h = v.outSymbol ? this.m_t : "", M = c ? "" : this.m_z, u = "";
|
|
1255
1255
|
if (v.complete) {
|
|
1256
1256
|
for (var d = 1; d < this.m_u.length; d++)
|
|
1257
|
-
u += W.call(this,
|
|
1257
|
+
u += W.call(this, c.charAt(d - 1) || "0") + this.m_u.charAt(d);
|
|
1258
1258
|
M = W.call(this, a, v) + this.m_u.charAt(0);
|
|
1259
1259
|
} else {
|
|
1260
|
-
if (
|
|
1260
|
+
if (c = c.substr(0, this.m_u.length - 1), c = I.clearZero(c, "0", "$"))
|
|
1261
1261
|
for (var A, d = 0; d < this.m_u.length - 1; d++)
|
|
1262
|
-
|
|
1262
|
+
c.charAt(d) && c.charAt(d) != "0" && (u += W.call(this, c.charAt(d)) + this.m_u.charAt(d + 1), A = !1), c.charAt(d) !== "0" || A || (d == 0 && a == "0" || (u += m), A = !0);
|
|
1263
1263
|
a == "0" && !M && u || (M = W.call(this, a, v) + this.m_u.charAt(0) + M);
|
|
1264
1264
|
}
|
|
1265
1265
|
return h + M + u;
|
|
1266
1266
|
}
|
|
1267
1267
|
function l(j, v) {
|
|
1268
1268
|
return { encodeS: function(P, o) {
|
|
1269
|
-
return o =
|
|
1269
|
+
return o = I.extend({ ww: !0, tenMin: !0 }, o), s.CL.call(j, P, o);
|
|
1270
1270
|
}, encodeB: function(P, o) {
|
|
1271
|
-
return o =
|
|
1271
|
+
return o = I.extend({ ww: !0 }, o), s.CL.call(v, P, o);
|
|
1272
1272
|
}, decodeS: function() {
|
|
1273
1273
|
return s.unCL.apply(j, arguments);
|
|
1274
1274
|
}, decodeB: function() {
|
|
1275
1275
|
return s.unCL.apply(v, arguments);
|
|
1276
1276
|
}, toMoney: function(P, o) {
|
|
1277
|
-
return o =
|
|
1277
|
+
return o = I.extend({ ww: !0 }, o), s.toMoney.call(v, P, o);
|
|
1278
1278
|
} };
|
|
1279
1279
|
}
|
|
1280
|
-
var
|
|
1281
|
-
var P = /^([+-])?0*(\d+)(\.(\d+))?$/, o = /^([+-])?0*(\d+)(\.(\d+))?e(([+-])?(\d+))$/i, m = v.e2ten = function(
|
|
1282
|
-
var h = o.exec(
|
|
1280
|
+
var I = g(function(j, v) {
|
|
1281
|
+
var P = /^([+-])?0*(\d+)(\.(\d+))?$/, o = /^([+-])?0*(\d+)(\.(\d+))?e(([+-])?(\d+))$/i, m = v.e2ten = function(c) {
|
|
1282
|
+
var h = o.exec(c.toString());
|
|
1283
1283
|
if (!h)
|
|
1284
|
-
return
|
|
1284
|
+
return c;
|
|
1285
1285
|
var M = h[2], u = h[4] || "", d = h[5] ? +h[5] : 0;
|
|
1286
1286
|
if (d > 0) {
|
|
1287
1287
|
var A = u.substr(0, d);
|
|
@@ -1295,40 +1295,40 @@ var _t = { exports: {} };
|
|
|
1295
1295
|
}
|
|
1296
1296
|
return M = M == "" ? "0" : M, (h[1] == "-" ? "-" : "") + M + (u ? "." + u : "");
|
|
1297
1297
|
};
|
|
1298
|
-
v.getNumbResult = function(
|
|
1299
|
-
var h = P.exec(
|
|
1300
|
-
if (!h && o.test(
|
|
1298
|
+
v.getNumbResult = function(c) {
|
|
1299
|
+
var h = P.exec(c.toString());
|
|
1300
|
+
if (!h && o.test(c.toString()) && (h = P.exec(m(c.toString()))), h)
|
|
1301
1301
|
return { int: h[2], decimal: h[4], minus: h[1] == "-", num: h.slice(1, 3).join("") };
|
|
1302
|
-
}, v.centerArray = function
|
|
1302
|
+
}, v.centerArray = function c(h, M) {
|
|
1303
1303
|
if (h.splice.apply(h, [0, M.length].concat(M.splice(0, M.length))), arguments.length > 2) {
|
|
1304
1304
|
var u = [].slice.call(arguments, 2);
|
|
1305
|
-
u.unshift(h),
|
|
1305
|
+
u.unshift(h), c.apply(null, u);
|
|
1306
1306
|
}
|
|
1307
1307
|
return h;
|
|
1308
1308
|
};
|
|
1309
|
-
var a = v.hasAttr = function(
|
|
1310
|
-
return Object.prototype.hasOwnProperty.call(
|
|
1309
|
+
var a = v.hasAttr = function(c, h) {
|
|
1310
|
+
return Object.prototype.hasOwnProperty.call(c, h);
|
|
1311
1311
|
};
|
|
1312
|
-
v.extend = function(
|
|
1312
|
+
v.extend = function(c) {
|
|
1313
1313
|
for (var h, M = arguments[0] || {}, u = Array.prototype.slice.call(arguments, 1), d = 0; d < u.length; d++) {
|
|
1314
1314
|
var A = u[d];
|
|
1315
1315
|
for (h in A)
|
|
1316
1316
|
a(A, h) && (M[h] = A[h]);
|
|
1317
1317
|
}
|
|
1318
1318
|
return M;
|
|
1319
|
-
}, v.getDigit = function(
|
|
1320
|
-
return
|
|
1321
|
-
}, v.unshiftZero = function(
|
|
1319
|
+
}, v.getDigit = function(c) {
|
|
1320
|
+
return c >= 5 ? 4 * (c - 4) + 4 : c;
|
|
1321
|
+
}, v.unshiftZero = function(c, h) {
|
|
1322
1322
|
if (h == null && (h = 1), !(h <= 0))
|
|
1323
1323
|
for (; h--; )
|
|
1324
|
-
|
|
1325
|
-
}, v.clearZero = function(
|
|
1326
|
-
if (
|
|
1324
|
+
c.unshift(0);
|
|
1325
|
+
}, v.clearZero = function(c, h, M) {
|
|
1326
|
+
if (c == null)
|
|
1327
1327
|
return "";
|
|
1328
1328
|
var u = ~"*.?+$^[](){}|\\/".indexOf(h) ? "\\" + h : h, d = new RegExp("^" + u + "+"), A = new RegExp(u + "+$"), Z = new RegExp(u + "{2}", "g");
|
|
1329
|
-
return
|
|
1329
|
+
return c = c.toString(), M == "^" && (c = c.replace(d, "")), M && M != "$" || (c = c.replace(A, "")), M && M != "nto1" || (c = c.replace(Z, h)), c;
|
|
1330
1330
|
};
|
|
1331
|
-
}), s = (
|
|
1331
|
+
}), s = (I.e2ten, I.getNumbResult, I.centerArray, I.hasAttr, I.extend, I.getDigit, I.unshiftZero, I.clearZero, { CL: W, unCL: E, toMoney: b }), w = l, C = { ch: "\u96F6\u4E00\u4E8C\u4E09\u56DB\u4E94\u516D\u4E03\u516B\u4E5D", ch_u: "\u4E2A\u5341\u767E\u5343\u4E07\u4EBF", ch_f: "\u8D1F", ch_d: "\u70B9" }, N = { ch: "\u96F6\u58F9\u8D30\u53C1\u8086\u4F0D\u9646\u67D2\u634C\u7396", ch_u: "\u4E2A\u62FE\u4F70\u4EDF\u4E07\u4EBF", ch_f: "\u8D1F", ch_d: "\u70B9", m_t: "\u4EBA\u6C11\u5E01", m_z: "\u6574", m_u: "\u5143\u89D2\u5206" }, r = { ch: "\u96F6\u4E00\u4E8C\u4E09\u56DB\u4E94\u516D\u4E03\u516B\u4E5D", ch_u: "\u500B\u5341\u767E\u5343\u842C\u5104", ch_f: "\u8CA0", ch_d: "\u9EDE" }, T = { ch: "\u96F6\u58F9\u8CB3\u53C3\u8086\u4F0D\u9678\u67D2\u634C\u7396", ch_u: "\u500B\u62FE\u4F70\u4EDF\u842C\u5104", ch_f: "\u8CA0", ch_d: "\u9EDE", m_t: "$", m_z: "\u6574", m_u: "\u5713\u89D2\u5206" }, S = { s: C, b: N, hk_s: r, hk_b: T }, D = function(j) {
|
|
1332
1332
|
this.lang = j, this.encode = function() {
|
|
1333
1333
|
return s.CL.apply(j, arguments);
|
|
1334
1334
|
}, this.decode = function() {
|
|
@@ -1508,13 +1508,13 @@ var At = function(q) {
|
|
|
1508
1508
|
enumerable: !0,
|
|
1509
1509
|
value: E
|
|
1510
1510
|
}), 2 & b && typeof E != "string")
|
|
1511
|
-
for (var
|
|
1511
|
+
for (var I in E)
|
|
1512
1512
|
g.d(
|
|
1513
1513
|
l,
|
|
1514
|
-
|
|
1514
|
+
I,
|
|
1515
1515
|
function(s) {
|
|
1516
1516
|
return E[s];
|
|
1517
|
-
}.bind(null,
|
|
1517
|
+
}.bind(null, I)
|
|
1518
1518
|
);
|
|
1519
1519
|
return l;
|
|
1520
1520
|
}, g.n = function(E) {
|
|
@@ -1539,10 +1539,10 @@ var At = function(q) {
|
|
|
1539
1539
|
},
|
|
1540
1540
|
id: 0,
|
|
1541
1541
|
off: function(b, l) {
|
|
1542
|
-
var
|
|
1543
|
-
if (
|
|
1544
|
-
for (var s = -1, w = 0; w <
|
|
1545
|
-
if (
|
|
1542
|
+
var I = W[b];
|
|
1543
|
+
if (I) {
|
|
1544
|
+
for (var s = -1, w = 0; w < I.length; w++)
|
|
1545
|
+
if (I[w] === l) {
|
|
1546
1546
|
s = w;
|
|
1547
1547
|
break;
|
|
1548
1548
|
}
|
|
@@ -1552,8 +1552,8 @@ var At = function(q) {
|
|
|
1552
1552
|
trigger: function(b) {
|
|
1553
1553
|
var l = W[b];
|
|
1554
1554
|
if (l && l.length)
|
|
1555
|
-
for (var
|
|
1556
|
-
l[s].apply(this,
|
|
1555
|
+
for (var I = Array.prototype.slice.call(arguments, 1), s = 0; s < l.length; s++)
|
|
1556
|
+
l[s].apply(this, I);
|
|
1557
1557
|
},
|
|
1558
1558
|
clear: function(b) {
|
|
1559
1559
|
W[b] = [];
|
|
@@ -1566,10 +1566,10 @@ var At = function(q) {
|
|
|
1566
1566
|
}
|
|
1567
1567
|
}), hinnn.form = {
|
|
1568
1568
|
serialize: function(b) {
|
|
1569
|
-
var l = x(b).serializeArray(),
|
|
1569
|
+
var l = x(b).serializeArray(), I = {};
|
|
1570
1570
|
return x.each(l, function() {
|
|
1571
|
-
|
|
1572
|
-
}),
|
|
1571
|
+
I[this.name] ? Object.prototype.toString.call(I[this.name]) == "[object Array]" ? I[this.name].push(this.value) : I[this.name] = [I[this.name], this.value] : I[this.name] = this.value;
|
|
1572
|
+
}), I;
|
|
1573
1573
|
}
|
|
1574
1574
|
}, hinnn.pt = {
|
|
1575
1575
|
toPx: function(b) {
|
|
@@ -1609,52 +1609,52 @@ var At = function(q) {
|
|
|
1609
1609
|
return hinnn.pt.toPx(hinnn.mm.toPt(b));
|
|
1610
1610
|
}
|
|
1611
1611
|
}, hinnn.throttle = function(E, b, l) {
|
|
1612
|
-
var
|
|
1612
|
+
var I, s, w, C = null, N = 0;
|
|
1613
1613
|
l || (l = {});
|
|
1614
1614
|
var r = function() {
|
|
1615
|
-
N = l.leading === !1 ? 0 : _.now(), C = null, w = E.apply(
|
|
1615
|
+
N = l.leading === !1 ? 0 : _.now(), C = null, w = E.apply(I, s), C || (I = s = null);
|
|
1616
1616
|
};
|
|
1617
1617
|
return function() {
|
|
1618
1618
|
var T = _.now();
|
|
1619
1619
|
N || l.leading !== !1 || (N = T);
|
|
1620
1620
|
var S = b - (T - N);
|
|
1621
|
-
return
|
|
1621
|
+
return I = this, s = arguments, S <= 0 || S > b ? (C && (clearTimeout(C), C = null), N = T, w = E.apply(I, s), C || (I = s = null)) : C || l.trailing === !1 || (C = setTimeout(r, S)), w;
|
|
1622
1622
|
};
|
|
1623
1623
|
}, hinnn.debounce = function(E, b, l) {
|
|
1624
|
-
var
|
|
1624
|
+
var I, s, w, C, N, r = function T() {
|
|
1625
1625
|
var S = _.now() - C;
|
|
1626
|
-
S < b && S >= 0 ?
|
|
1626
|
+
S < b && S >= 0 ? I = setTimeout(T, b - S) : (I = null, l || (N = E.apply(w, s), I || (w = s = null)));
|
|
1627
1627
|
};
|
|
1628
1628
|
return function() {
|
|
1629
1629
|
w = this, s = arguments, C = _.now();
|
|
1630
|
-
var T = l && !
|
|
1631
|
-
return
|
|
1630
|
+
var T = l && !I;
|
|
1631
|
+
return I || (I = setTimeout(r, b)), T && (N = E.apply(w, s), w = s = null), N;
|
|
1632
1632
|
};
|
|
1633
1633
|
}, hinnn.toUtf8 = function(E) {
|
|
1634
|
-
var b, l,
|
|
1635
|
-
for (b = "",
|
|
1634
|
+
var b, l, I, s;
|
|
1635
|
+
for (b = "", I = E.length, l = 0; l < I; l++)
|
|
1636
1636
|
(s = E.charCodeAt(l)) >= 1 && s <= 127 ? b += E.charAt(l) : s > 2047 ? (b += String.fromCharCode(224 | s >> 12 & 15), b += String.fromCharCode(128 | s >> 6 & 63), b += String.fromCharCode(128 | s >> 0 & 63)) : (b += String.fromCharCode(192 | s >> 6 & 31), b += String.fromCharCode(128 | s >> 0 & 63));
|
|
1637
1637
|
return b;
|
|
1638
1638
|
}, hinnn.groupBy = function(E, b, l) {
|
|
1639
|
-
var
|
|
1639
|
+
var I = {};
|
|
1640
1640
|
return E.forEach(function(s) {
|
|
1641
1641
|
var w = JSON.stringify(l(s));
|
|
1642
|
-
|
|
1642
|
+
I[w] || (I[w] = {
|
|
1643
1643
|
rows: []
|
|
1644
1644
|
}, b.forEach(function(C) {
|
|
1645
|
-
|
|
1646
|
-
})),
|
|
1647
|
-
}), Object.keys(
|
|
1648
|
-
return
|
|
1645
|
+
I[w][C] = s[C];
|
|
1646
|
+
})), I[w].rows.push(s);
|
|
1647
|
+
}), Object.keys(I).map(function(s) {
|
|
1648
|
+
return I[s];
|
|
1649
1649
|
});
|
|
1650
1650
|
}, hinnn.orderBy = function(E, b) {
|
|
1651
1651
|
if (E.length <= 1)
|
|
1652
1652
|
return E;
|
|
1653
|
-
var l = Math.floor(E.length / 2),
|
|
1653
|
+
var l = Math.floor(E.length / 2), I = E.splice(l, 1)[0], s = [], w = [], C = !0, N = !1, r = void 0;
|
|
1654
1654
|
try {
|
|
1655
1655
|
for (var T = E[Symbol.iterator](), S; !(C = (S = T.next()).done); C = !0) {
|
|
1656
1656
|
var D = S.value;
|
|
1657
|
-
b(D) < b(
|
|
1657
|
+
b(D) < b(I) ? s.push(D) : w.push(D);
|
|
1658
1658
|
}
|
|
1659
1659
|
} catch (H) {
|
|
1660
1660
|
N = !0, r = H;
|
|
@@ -1666,11 +1666,11 @@ var At = function(q) {
|
|
|
1666
1666
|
throw r;
|
|
1667
1667
|
}
|
|
1668
1668
|
}
|
|
1669
|
-
return this.orderBy(s, b).concat([
|
|
1669
|
+
return this.orderBy(s, b).concat([I], this.orderBy(w, b));
|
|
1670
1670
|
}, hinnn.dateFormat = function(E, b) {
|
|
1671
1671
|
if (E)
|
|
1672
1672
|
try {
|
|
1673
|
-
var l = typeof E == "string" ? new Date(E) : E,
|
|
1673
|
+
var l = typeof E == "string" ? new Date(E) : E, I = {
|
|
1674
1674
|
"M+": l.getMonth() + 1,
|
|
1675
1675
|
"d+": l.getDate(),
|
|
1676
1676
|
"H+": l.getHours(),
|
|
@@ -1679,8 +1679,8 @@ var At = function(q) {
|
|
|
1679
1679
|
"q+": Math.floor((l.getMonth() + 3) / 3),
|
|
1680
1680
|
S: l.getMilliseconds()
|
|
1681
1681
|
};
|
|
1682
|
-
for (var s in /(y+)/.test(b) && (b = b.replace(RegExp.$1, (l.getFullYear() + "").substr(4 - RegExp.$1.length))),
|
|
1683
|
-
new RegExp("(" + s + ")").test(b) && (b = b.replace(RegExp.$1, RegExp.$1.length == 1 ?
|
|
1682
|
+
for (var s in /(y+)/.test(b) && (b = b.replace(RegExp.$1, (l.getFullYear() + "").substr(4 - RegExp.$1.length))), I)
|
|
1683
|
+
new RegExp("(" + s + ")").test(b) && (b = b.replace(RegExp.$1, RegExp.$1.length == 1 ? I[s] : ("00" + I[s]).substr(("" + I[s]).length)));
|
|
1684
1684
|
return b;
|
|
1685
1685
|
} catch (w) {
|
|
1686
1686
|
return console.log(w), "";
|
|
@@ -1689,8 +1689,8 @@ var At = function(q) {
|
|
|
1689
1689
|
}, hinnn.numFormat = function(E, b) {
|
|
1690
1690
|
if (E != null)
|
|
1691
1691
|
try {
|
|
1692
|
-
var l = typeof E == "string" ? parseFloat(E) : E,
|
|
1693
|
-
return
|
|
1692
|
+
var l = typeof E == "string" ? parseFloat(E) : E, I = parseInt(b);
|
|
1693
|
+
return I > 0 ? l.toFixed(I) : parseInt(l.toString());
|
|
1694
1694
|
} catch (s) {
|
|
1695
1695
|
return console.log(s), "";
|
|
1696
1696
|
}
|
|
@@ -1739,10 +1739,10 @@ var At = function(q) {
|
|
|
1739
1739
|
l && x.extend(this, l);
|
|
1740
1740
|
}, b.prototype.register = function(l) {
|
|
1741
1741
|
this.init(l);
|
|
1742
|
-
var
|
|
1742
|
+
var I = this, s = I.getHooks("init");
|
|
1743
1743
|
s && s.forEach((w) => {
|
|
1744
1744
|
w.run({
|
|
1745
|
-
Config:
|
|
1745
|
+
Config: I,
|
|
1746
1746
|
OptionItems: W,
|
|
1747
1747
|
ElementTypes: At.ElementTypes,
|
|
1748
1748
|
hinnn,
|
|
@@ -1750,29 +1750,29 @@ var At = function(q) {
|
|
|
1750
1750
|
});
|
|
1751
1751
|
});
|
|
1752
1752
|
}, b.prototype.getHooks = function(l) {
|
|
1753
|
-
return this.pluginsList().reduce((
|
|
1753
|
+
return this.pluginsList().reduce((I, s) => I.concat(s.hooks.filter((w) => w.hook === l)), []);
|
|
1754
1754
|
}, b.prototype.pluginsList = function() {
|
|
1755
1755
|
var l = this;
|
|
1756
|
-
return this.plugins ? this.plugins.filter((
|
|
1756
|
+
return this.plugins ? this.plugins.filter((I) => l.versionCheck(I)) : [];
|
|
1757
1757
|
}, b.prototype.versionCheck = function(l) {
|
|
1758
1758
|
l.leastHiprintVersion.split(".").length !== 3 && console.error(`[${l.name}] has a malformed leastHiprintVersion of ${l.leastHiprintVersion}. Please tell the developer to update.`);
|
|
1759
|
-
const
|
|
1759
|
+
const I = b.instance.version.split("."), s = parseInt(I[0]), w = parseInt(I[1]), C = parseInt(I[2]), N = l.leastHiprintVersion.split("."), r = parseInt(N[0]), T = parseInt(N[1]), S = parseInt(N[2]);
|
|
1760
1760
|
let D = !1;
|
|
1761
1761
|
return s > r && (D = !0), s === r && w > T && (D = !0), s === r && w === T && C >= S && (D = !0), D || console.error(
|
|
1762
1762
|
`Plugin [${l.name}] requires "@svelte-hiprint/hiprint" version ${l.leastHiprintVersion} and you are using ${b.instance.version}. Disabling plugin. If you want to use this plugin, please update to the required version.`
|
|
1763
1763
|
), D;
|
|
1764
|
-
}, b.prototype.on = function(l,
|
|
1765
|
-
hinnn.event.on(l,
|
|
1764
|
+
}, b.prototype.on = function(l, I) {
|
|
1765
|
+
hinnn.event.on(l, I);
|
|
1766
1766
|
}, b.prototype.clear = function(l) {
|
|
1767
1767
|
hinnn.event.clear(l);
|
|
1768
1768
|
}, b.prototype.registerItems = function(l) {
|
|
1769
|
-
l.forEach(function(
|
|
1770
|
-
W.a.registerItem(new
|
|
1769
|
+
l.forEach(function(I) {
|
|
1770
|
+
W.a.registerItem(new I());
|
|
1771
1771
|
});
|
|
1772
1772
|
}, Object.defineProperty(b, "instance", {
|
|
1773
1773
|
get: function() {
|
|
1774
|
-
return b._instance || (b._instance = new b(), window.HIPRINT_CONFIG && x.extend(b._instance, HIPRINT_CONFIG), b._instance.optionItems && b._instance.optionItems.forEach(function(
|
|
1775
|
-
W.a.registerItem(new
|
|
1774
|
+
return b._instance || (b._instance = new b(), window.HIPRINT_CONFIG && x.extend(b._instance, HIPRINT_CONFIG), b._instance.optionItems && b._instance.optionItems.forEach(function(I) {
|
|
1775
|
+
W.a.registerItem(new I());
|
|
1776
1776
|
})), b._instance;
|
|
1777
1777
|
},
|
|
1778
1778
|
enumerable: !0,
|
|
@@ -1785,8 +1785,8 @@ var At = function(q) {
|
|
|
1785
1785
|
function b(l) {
|
|
1786
1786
|
this.printElement = l;
|
|
1787
1787
|
}
|
|
1788
|
-
return b.prototype.updatePosition = function(l,
|
|
1789
|
-
this.left = l, this.top =
|
|
1788
|
+
return b.prototype.updatePosition = function(l, I) {
|
|
1789
|
+
this.left = l, this.top = I;
|
|
1790
1790
|
}, b;
|
|
1791
1791
|
}();
|
|
1792
1792
|
g.d(F, "a", function() {
|
|
@@ -1842,9 +1842,9 @@ var At = function(q) {
|
|
|
1842
1842
|
}, this.B8 = {
|
|
1843
1843
|
width: 62,
|
|
1844
1844
|
height: 88
|
|
1845
|
-
}, this.dragLengthCNum = function(l,
|
|
1845
|
+
}, this.dragLengthCNum = function(l, I) {
|
|
1846
1846
|
var s = 0.75 * l;
|
|
1847
|
-
return
|
|
1847
|
+
return I && (I = I), Math.round(s / I) * I;
|
|
1848
1848
|
};
|
|
1849
1849
|
}
|
|
1850
1850
|
return Object.defineProperty(b, "instance", {
|
|
@@ -1859,14 +1859,14 @@ var At = function(q) {
|
|
|
1859
1859
|
b.instance.dragingPrintElement = new W(l);
|
|
1860
1860
|
}, b.prototype.guid = function() {
|
|
1861
1861
|
return "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g, function(l) {
|
|
1862
|
-
var
|
|
1863
|
-
return (l == "x" ?
|
|
1862
|
+
var I = 16 * Math.random() | 0;
|
|
1863
|
+
return (l == "x" ? I : 3 & I | 8).toString(16);
|
|
1864
1864
|
});
|
|
1865
1865
|
}, b.prototype.imageToBase64 = function(l) {
|
|
1866
1866
|
if (x(l).attr("src").indexOf("base64") == -1)
|
|
1867
1867
|
try {
|
|
1868
|
-
var
|
|
1869
|
-
s.src = l.attr("src"),
|
|
1868
|
+
var I = document.createElement("canvas"), s = new Image();
|
|
1869
|
+
s.src = l.attr("src"), I.width = s.width, I.height = s.height, I.getContext("2d").drawImage(s, 0, 0), l.attr("src", I.toDataURL("image/png"));
|
|
1870
1870
|
} catch {
|
|
1871
1871
|
try {
|
|
1872
1872
|
this.xhrLoadImage(l);
|
|
@@ -1876,14 +1876,14 @@ var At = function(q) {
|
|
|
1876
1876
|
}
|
|
1877
1877
|
}, b.prototype.xhrLoadImage = function(l) {
|
|
1878
1878
|
}, b.prototype.transformImg = function(l) {
|
|
1879
|
-
var
|
|
1879
|
+
var I = this;
|
|
1880
1880
|
l.map(function(s, w) {
|
|
1881
|
-
|
|
1881
|
+
I.imageToBase64(x(w));
|
|
1882
1882
|
});
|
|
1883
1883
|
}, b.prototype.getPrintTemplateById = function(l) {
|
|
1884
1884
|
return b.instance.printTemplateContainer[l];
|
|
1885
|
-
}, b.prototype.setPrintTemplateById = function(l,
|
|
1886
|
-
return b.instance.printTemplateContainer[l] =
|
|
1885
|
+
}, b.prototype.setPrintTemplateById = function(l, I) {
|
|
1886
|
+
return b.instance.printTemplateContainer[l] = I;
|
|
1887
1887
|
}, b;
|
|
1888
1888
|
}();
|
|
1889
1889
|
},
|
|
@@ -1903,12 +1903,12 @@ var At = function(q) {
|
|
|
1903
1903
|
this.defaultOptions = l, this.initSize();
|
|
1904
1904
|
}, b.prototype.initSize = function() {
|
|
1905
1905
|
this.width || this.setWidth(this.defaultOptions.width), this.height || this.setHeight(this.defaultOptions.height);
|
|
1906
|
-
}, b.prototype.initSizeByHtml = function(l,
|
|
1907
|
-
this.width || this.setWidth(l), this.height || this.setHeight(
|
|
1906
|
+
}, b.prototype.initSizeByHtml = function(l, I) {
|
|
1907
|
+
this.width || this.setWidth(l), this.height || this.setHeight(I);
|
|
1908
1908
|
}, b.prototype.getRectInfo = function() {
|
|
1909
1909
|
var l = { w: 0, h: 0, diffW: 0, diffH: 0 };
|
|
1910
1910
|
if (this.transform) {
|
|
1911
|
-
var
|
|
1911
|
+
var I = this.transform * Math.PI / 180, s = this.width, w = this.height, C = Math.sin(I), N = Math.cos(I), r = Math.abs(s * N) + Math.abs(w * C), T = Math.abs(s * C) + Math.abs(w * N), S = (s - r) / 2, D = (w - T) / 2;
|
|
1912
1912
|
l.w = r, l.h = T, l.diffW = S, l.diffH = D;
|
|
1913
1913
|
}
|
|
1914
1914
|
return l;
|
|
@@ -1959,22 +1959,22 @@ var At = function(q) {
|
|
|
1959
1959
|
}, b.prototype.getValueFromOptionsOrDefault = function(l) {
|
|
1960
1960
|
return this[l] == null ? this.defaultOptions[l] : this[l];
|
|
1961
1961
|
}, b.prototype.getPrintElementOptionEntity = function() {
|
|
1962
|
-
var l = new W(),
|
|
1962
|
+
var l = new W(), I = this;
|
|
1963
1963
|
return Object.keys(this).filter(function(s) {
|
|
1964
1964
|
return s != "topInDesign";
|
|
1965
1965
|
}).forEach(function(s) {
|
|
1966
|
-
if (typeof
|
|
1966
|
+
if (typeof I[s] != "number" && typeof I[s] != "string" && !["fields"].includes(s) && jt(I[s]) != jt(!0) || (l[s] = I[s]), s == "style") {
|
|
1967
1967
|
l.style = {};
|
|
1968
|
-
var w =
|
|
1968
|
+
var w = I[s];
|
|
1969
1969
|
w && Object.keys(w).forEach(function(C) {
|
|
1970
1970
|
typeof w[C] != "number" && typeof w[C] != "string" || (l.style[C] = w[C]);
|
|
1971
1971
|
});
|
|
1972
1972
|
}
|
|
1973
1973
|
}), l;
|
|
1974
1974
|
}, b.prototype.init = function(l) {
|
|
1975
|
-
var
|
|
1975
|
+
var I = this;
|
|
1976
1976
|
l && Object.keys(l).forEach(function(s) {
|
|
1977
|
-
|
|
1977
|
+
I[s] = l[s];
|
|
1978
1978
|
});
|
|
1979
1979
|
}, b;
|
|
1980
1980
|
}();
|
|
@@ -1983,7 +1983,7 @@ var At = function(q) {
|
|
|
1983
1983
|
g.d(F, "a", function() {
|
|
1984
1984
|
return C;
|
|
1985
1985
|
});
|
|
1986
|
-
var W = g(17), E = g(1), b = g(9), l = g(6),
|
|
1986
|
+
var W = g(17), E = g(1), b = g(9), l = g(6), I = g(0), s = g(8), w = g(2), C = function() {
|
|
1987
1987
|
function N(r) {
|
|
1988
1988
|
this.printElementType = r, this.id = w.a.instance.guid();
|
|
1989
1989
|
}
|
|
@@ -2025,8 +2025,8 @@ var At = function(q) {
|
|
|
2025
2025
|
this.createTempContainer();
|
|
2026
2026
|
var T = r.clone();
|
|
2027
2027
|
this.getTempContainer().append(T), this.options.initSizeByHtml(
|
|
2028
|
-
parseInt(
|
|
2029
|
-
parseInt(
|
|
2028
|
+
parseInt(I.a.px.toPt(T.width()).toString()),
|
|
2029
|
+
parseInt(I.a.px.toPt(T.height()).toString())
|
|
2030
2030
|
), this.removeTempContainer();
|
|
2031
2031
|
}
|
|
2032
2032
|
}, N.prototype.updateTargetSize = function(r) {
|
|
@@ -2036,7 +2036,7 @@ var At = function(q) {
|
|
|
2036
2036
|
}, N.prototype.getDesignTarget = function(r) {
|
|
2037
2037
|
var T = this, S = 0;
|
|
2038
2038
|
return this.designTarget = this.getHtml(r)[0].target, this.designPaper = r, this.designTarget.click(function(D) {
|
|
2039
|
-
D.timeStamp - S > 500 &&
|
|
2039
|
+
D.timeStamp - S > 500 && I.a.event.trigger(T.getPrintElementSelectEventKey(), {
|
|
2040
2040
|
printElement: T
|
|
2041
2041
|
}), S = D.timeStamp;
|
|
2042
2042
|
}), this.designTarget.dblclick(function(D) {
|
|
@@ -2063,9 +2063,9 @@ var At = function(q) {
|
|
|
2063
2063
|
if (T._editing) {
|
|
2064
2064
|
S && S.css("cursor", "") && S.removeClass("editing") && S.removeAttr("contenteditable"), T.designTarget.removeClass("editing");
|
|
2065
2065
|
var D = S.text(), H = T.options.title + "\uFF1A";
|
|
2066
|
-
D.startsWith(H) && T.options.field ? D.length > H.length ? T.options.testData = D.split("\uFF1A")[1] : (T.options.title = D, T.options.testData = "") : T.options.title = D, r ||
|
|
2066
|
+
D.startsWith(H) && T.options.field ? D.length > H.length ? T.options.testData = D.split("\uFF1A")[1] : (T.options.title = D, T.options.testData = "") : T.options.title = D, r || I.a.event.trigger(T.getPrintElementSelectEventKey(), {
|
|
2067
2067
|
printElement: T
|
|
2068
|
-
}), T.updateDesignViewFromOptions(),
|
|
2068
|
+
}), T.updateDesignViewFromOptions(), I.a.event.trigger("hiprintTemplateDataChanged_" + T.templateId, "\u7F16\u8F91\u4FEE\u6539"), T._editing = !1;
|
|
2069
2069
|
var j = T.options.draggable == null || T.options.draggable == !0;
|
|
2070
2070
|
T.designTarget.hidraggable("update", { draggable: j });
|
|
2071
2071
|
}
|
|
@@ -2082,9 +2082,9 @@ var At = function(q) {
|
|
|
2082
2082
|
return h.designTarget.children().last().css("display") == "block" && h.designTarget.children().last().hasClass("selected") && !h.printElementType.type.includes("table");
|
|
2083
2083
|
}), o = P.length > 1, m = !S.designTarget.children().last().hasClass("selected");
|
|
2084
2084
|
if (o) {
|
|
2085
|
-
var a = j - S.options.left,
|
|
2085
|
+
var a = j - S.options.left, c = v - S.options.top;
|
|
2086
2086
|
P.forEach(function(h) {
|
|
2087
|
-
h.updateSizeAndPositionOptions(a + h.options.getLeft(),
|
|
2087
|
+
h.updateSizeAndPositionOptions(a + h.options.getLeft(), c + h.options.getTop()), h.designTarget.css("left", h.options.displayLeft()), h.designTarget.css("top", h.options.displayTop()), h.createLineOfPosition(T);
|
|
2088
2088
|
}), m && (S.updateSizeAndPositionOptions(j, v), S.createLineOfPosition(T));
|
|
2089
2089
|
} else
|
|
2090
2090
|
S.updateSizeAndPositionOptions(j, v), S.createLineOfPosition(T);
|
|
@@ -2099,7 +2099,7 @@ var At = function(q) {
|
|
|
2099
2099
|
return S.designPaper.scale || 1;
|
|
2100
2100
|
},
|
|
2101
2101
|
onStopDrag: function(H) {
|
|
2102
|
-
w.a.instance.changed &&
|
|
2102
|
+
w.a.instance.changed && I.a.event.trigger("hiprintTemplateDataChanged_" + S.templateId, "\u79FB\u52A8"), w.a.instance.draging = !1, w.a.instance.changed = !1;
|
|
2103
2103
|
var j = S.panel.printElements.filter(function(v) {
|
|
2104
2104
|
return v.designTarget.children().last().css("display") == "block" && !v.printElementType.type.includes("table");
|
|
2105
2105
|
});
|
|
@@ -2109,7 +2109,7 @@ var At = function(q) {
|
|
|
2109
2109
|
}
|
|
2110
2110
|
}), this.designTarget.on("mouseup", function() {
|
|
2111
2111
|
setTimeout(function() {
|
|
2112
|
-
S.removeLineOfPosition(),
|
|
2112
|
+
S.removeLineOfPosition(), I.a.event.trigger("hiprintTemplateMouseUp_" + T.templateId);
|
|
2113
2113
|
}, 300);
|
|
2114
2114
|
}), this.designTarget.hicontextMenu(S.panel.getContextMenuList()), this.setResizePanel(), this.bingCopyEvent(this.designTarget), this.bingKeyboardMoveEvent(this.designTarget, T);
|
|
2115
2115
|
}, N.prototype.getPrintElementEntity = function(r) {
|
|
@@ -2128,7 +2128,7 @@ var At = function(q) {
|
|
|
2128
2128
|
D && jt(D) == "object" ? Object.keys(D).forEach(function(P) {
|
|
2129
2129
|
r.options[P] = D[P];
|
|
2130
2130
|
}) : r.options[S.name] = D, H && r.setResizePanel(), j && r.designTarget.hidraggable("update", { axis: D }), v && r.designTarget.hidraggable("update", { draggable: D });
|
|
2131
|
-
}), this.updateDesignViewFromOptions(),
|
|
2131
|
+
}), this.updateDesignViewFromOptions(), I.a.event.trigger("hiprintTemplateDataChanged_" + this.templateId, "\u5143\u7D20\u4FEE\u6539");
|
|
2132
2132
|
}, N.prototype.updateOption = function(r, T, S) {
|
|
2133
2133
|
try {
|
|
2134
2134
|
var D = this, H = this.getConfigOptions(), j = ["draggable"];
|
|
@@ -2138,7 +2138,7 @@ var At = function(q) {
|
|
|
2138
2138
|
});
|
|
2139
2139
|
}) : j = H.supportOptions.map(function(v) {
|
|
2140
2140
|
return v.name;
|
|
2141
|
-
}), j && j.includes(r) && (this.options[r] = T, r == "draggable" && D.designTarget.hidraggable("update", { draggable: T }), r == "widthHeight" && (T.width && (this.options.width = T.width), T.height && (this.options.height = T.height), T.widthHeightSync && (this.options.widthHeightSync = T.widthHeightSync)), r == "coordinate" && (T.left && (this.options.left = T.left), T.top && (this.options.top = T.top), T.coordinateSync && (this.options.coordinateSync = T.coordinateSync)), this.updateDesignViewFromOptions(), S || (
|
|
2141
|
+
}), j && j.includes(r) && (this.options[r] = T, r == "draggable" && D.designTarget.hidraggable("update", { draggable: T }), r == "widthHeight" && (T.width && (this.options.width = T.width), T.height && (this.options.height = T.height), T.widthHeightSync && (this.options.widthHeightSync = T.widthHeightSync)), r == "coordinate" && (T.left && (this.options.left = T.left), T.top && (this.options.top = T.top), T.coordinateSync && (this.options.coordinateSync = T.coordinateSync)), this.updateDesignViewFromOptions(), S || (I.a.event.trigger("hiprintTemplateDataChanged_" + this.templateId, "\u53C2\u6570\u4FEE\u6539"), I.a.event.trigger(D.getPrintElementSelectEventKey(), {
|
|
2142
2142
|
printElement: D
|
|
2143
2143
|
})));
|
|
2144
2144
|
} catch (v) {
|
|
@@ -2162,7 +2162,7 @@ var At = function(q) {
|
|
|
2162
2162
|
o != null ? r.onRotate(D, o) : r.onResize(D, H, j, v, P), r.createLineOfPosition(T);
|
|
2163
2163
|
},
|
|
2164
2164
|
onStopResize: function(D) {
|
|
2165
|
-
|
|
2165
|
+
I.a.event.trigger("hiprintTemplateDataChanged_" + r.templateId, D ? "\u65CB\u8F6C" : "\u5927\u5C0F"), w.a.instance.draging = !1, r.removeLineOfPosition();
|
|
2166
2166
|
}
|
|
2167
2167
|
}), this.options.draggable == !1 && x('<i style="position:absolute;font-size:12px;right:-14px;bottom:-14px;z-index:10" class="svicon sv-lock"></i>').insertBefore(this.designTarget.find(".resize-panel"));
|
|
2168
2168
|
}, N.prototype.onRotate = function(r, T) {
|
|
@@ -2258,7 +2258,7 @@ var At = function(q) {
|
|
|
2258
2258
|
)), H;
|
|
2259
2259
|
}, N.prototype.updatePanelHeight = function(r, T) {
|
|
2260
2260
|
if (this.panel.panelPageRule == "none") {
|
|
2261
|
-
var S =
|
|
2261
|
+
var S = I.a.pt.toMm(r);
|
|
2262
2262
|
T.paperFooter = r, T.target.css("height", S + "mm"), T.target.attr("original-height", S);
|
|
2263
2263
|
}
|
|
2264
2264
|
}, N.prototype.getBeginPrintTopInPaperByReferenceElement = function(r) {
|
|
@@ -2465,7 +2465,7 @@ var At = function(q) {
|
|
|
2465
2465
|
var m = S.panel;
|
|
2466
2466
|
P ? v.forEach(function(a) {
|
|
2467
2467
|
m.deletePrintElement(a);
|
|
2468
|
-
}) : m.deletePrintElement(S),
|
|
2468
|
+
}) : m.deletePrintElement(S), I.a.event.trigger("clearSettingContainer");
|
|
2469
2469
|
break;
|
|
2470
2470
|
case 37:
|
|
2471
2471
|
D = S.options.getLeft(), P ? v.forEach(function(a) {
|
|
@@ -2487,11 +2487,11 @@ var At = function(q) {
|
|
|
2487
2487
|
a.updatePositionByMultipleSelect(0, o);
|
|
2488
2488
|
}) : (S.updateSizeAndPositionOptions(void 0, H + o), r.css("top", S.options.displayTop())), j.preventDefault();
|
|
2489
2489
|
}
|
|
2490
|
-
[37, 38, 39, 40].includes(j.keyCode) &&
|
|
2490
|
+
[37, 38, 39, 40].includes(j.keyCode) && I.a.event.trigger("hiprintTemplateDataChanged_" + S.templateId, "\u952E\u76D8\u79FB\u52A8");
|
|
2491
2491
|
}
|
|
2492
2492
|
});
|
|
2493
2493
|
}, N.prototype.inRect = function(r) {
|
|
2494
|
-
var T = this.designPaper.scale || 1, S = this.designTarget[0].offsetLeft, D = this.designTarget[0].offsetTop, H = this.designTarget[0].offsetHeight, j = this.designTarget[0].offsetWidth, v = S + j, P = D + H, o = x(r.target[0]).position().left / T, m = x(r.target[0]).position().top / T, a = r.target[0].offsetHeight,
|
|
2494
|
+
var T = this.designPaper.scale || 1, S = this.designTarget[0].offsetLeft, D = this.designTarget[0].offsetTop, H = this.designTarget[0].offsetHeight, j = this.designTarget[0].offsetWidth, v = S + j, P = D + H, o = x(r.target[0]).position().left / T, m = x(r.target[0]).position().top / T, a = r.target[0].offsetHeight, c = r.target[0].offsetWidth, h = o + c, M = m + a;
|
|
2495
2495
|
return o < v && h > S && D < M && P > m;
|
|
2496
2496
|
}, N.prototype.multipleSelect = function(r) {
|
|
2497
2497
|
r ? this.designTarget.addClass("multipleSelect") : this.designTarget.removeClass("multipleSelect");
|
|
@@ -2552,7 +2552,7 @@ var At = function(q) {
|
|
|
2552
2552
|
enumerable: !0,
|
|
2553
2553
|
configurable: !0
|
|
2554
2554
|
}), j;
|
|
2555
|
-
}(),
|
|
2555
|
+
}(), I = function() {
|
|
2556
2556
|
function j() {
|
|
2557
2557
|
}
|
|
2558
2558
|
return Object.defineProperty(j, "Instance", {
|
|
@@ -2578,13 +2578,13 @@ var At = function(q) {
|
|
|
2578
2578
|
return this.title;
|
|
2579
2579
|
}, j.prototype.beginEdit = function(v) {
|
|
2580
2580
|
var P = this;
|
|
2581
|
-
P.tableOptions.options.fields && P.tableOptions.options.fields.length ? (this.editor =
|
|
2581
|
+
P.tableOptions.options.fields && P.tableOptions.options.fields.length ? (this.editor = I.Instance.createSelect("select"), v.getTarget().html(""), this.editor.init(P.tableOptions.options.fields, v), this.editor.setValue(this.field || ""), x(this.editor.target).keydown(function(o) {
|
|
2582
2582
|
o.keyCode == 13 && P.endEdit(v);
|
|
2583
2583
|
}), x(this.editor.target).change(function(o) {
|
|
2584
2584
|
P.endEdit(v);
|
|
2585
2585
|
}), x(this.editor.target).blur(function(o) {
|
|
2586
2586
|
P.endEdit(v);
|
|
2587
|
-
})) : (this.editor =
|
|
2587
|
+
})) : (this.editor = I.Instance.createEditor("text"), v.getTarget().html(""), this.editor.init(v), (this.title || this.field) && (this.tableOptions.options.isEnableEditField ? this.editor.setValue((this.title || "") + "#" + (this.field || "")) : this.editor.setValue(this.title || "")), x(this.editor.target).keydown(function(o) {
|
|
2588
2588
|
o.keyCode == 13 && P.endEdit(v);
|
|
2589
2589
|
}), x(this.editor.target).blur(function(o) {
|
|
2590
2590
|
P.endEdit(v);
|
|
@@ -2614,14 +2614,14 @@ var At = function(q) {
|
|
|
2614
2614
|
this.isHead = m, this.rowId = o, this.isEditing = !1;
|
|
2615
2615
|
var a = /^[0-9]*$/;
|
|
2616
2616
|
this.target = v, this.tableOptions = P;
|
|
2617
|
-
var
|
|
2618
|
-
this.colspan = a.test(
|
|
2617
|
+
var c = this.target.attr("colspan");
|
|
2618
|
+
this.colspan = a.test(c) ? parseInt(c) : 1;
|
|
2619
2619
|
var h = this.target.attr("rowspan");
|
|
2620
2620
|
this.rowspan = a.test(h) ? parseInt(h) : 1, this.initEvent(), this.isHead && this.initInnerEelement();
|
|
2621
2621
|
}, j.prototype.beginEdit = function() {
|
|
2622
2622
|
if (!this.isEditing && this.tableOptions.isEnableEdit && this.tableOptions.onBeforEdit(this)) {
|
|
2623
2623
|
var v = this.getValue();
|
|
2624
|
-
this.editor =
|
|
2624
|
+
this.editor = I.Instance.createEditor("text"), this.isEditing = !0, this.tableOptions.editingCell = this, this.target.html(""), this.editor.init(this), this.editor.setValue(v);
|
|
2625
2625
|
}
|
|
2626
2626
|
}, j.prototype.endEdit = function() {
|
|
2627
2627
|
this.isEditing = !1;
|
|
@@ -2720,8 +2720,8 @@ var At = function(q) {
|
|
|
2720
2720
|
var W = g(19), E = g(0), b = function() {
|
|
2721
2721
|
function l() {
|
|
2722
2722
|
}
|
|
2723
|
-
return l.createTableHead = function(
|
|
2724
|
-
for (var w = l.reconsitutionTableColumnTree(
|
|
2723
|
+
return l.createTableHead = function(I, s) {
|
|
2724
|
+
for (var w = l.reconsitutionTableColumnTree(I), C = x("<thead></thead>"), N = l.getColumnsWidth(w, s), r = function(D) {
|
|
2725
2725
|
var H = x("<tr></tr>");
|
|
2726
2726
|
w[D].filter(function(j) {
|
|
2727
2727
|
return j.checked;
|
|
@@ -2739,8 +2739,8 @@ var At = function(q) {
|
|
|
2739
2739
|
}), C.append(H);
|
|
2740
2740
|
}, T = 0; T < w.totalLayer; T++)
|
|
2741
2741
|
r(T);
|
|
2742
|
-
return l.syncTargetWidthToOption(
|
|
2743
|
-
}, l.createTableFooter = function(
|
|
2742
|
+
return l.syncTargetWidthToOption(I), C;
|
|
2743
|
+
}, l.createTableFooter = function(I, s, w, C, N, r) {
|
|
2744
2744
|
var T = x("<tfoot></tfoot>"), S = this.getFooterFormatter(w, C), D = this.tableSummaryTitle;
|
|
2745
2745
|
let H = w.tableFooterRepeat == "last" ? s : r, j = w.columns.length - 1;
|
|
2746
2746
|
var v = this.rowColumns || w.columns[j].columns;
|
|
@@ -2755,7 +2755,7 @@ var At = function(q) {
|
|
|
2755
2755
|
return R && R[o.field];
|
|
2756
2756
|
}).map(function(R) {
|
|
2757
2757
|
return new RegExp("^-?(0|[1-9]\\d*)(\\.\\d+)?").test(R[o.field]) ? Number(R[o.field]) : 0;
|
|
2758
|
-
}), a = o.tableSummaryText,
|
|
2758
|
+
}), a = o.tableSummaryText, c = o.tableSummaryNumFormat || 2, h = o.upperCase;
|
|
2759
2759
|
let { toUpperCase: M, numFormat: u } = E.a;
|
|
2760
2760
|
switch (o.tableSummary) {
|
|
2761
2761
|
case "count":
|
|
@@ -2770,7 +2770,7 @@ var At = function(q) {
|
|
|
2770
2770
|
}, 0)
|
|
2771
2771
|
)
|
|
2772
2772
|
);
|
|
2773
|
-
A = M(h, u(A,
|
|
2773
|
+
A = M(h, u(A, c));
|
|
2774
2774
|
var Y = D(o, a || "\u5408\u8BA1:", N);
|
|
2775
2775
|
P.append(`<td style="text-align: ${o.tableSummaryAlign || "center"}">${Y}${A}</td>`);
|
|
2776
2776
|
break;
|
|
@@ -2782,19 +2782,19 @@ var At = function(q) {
|
|
|
2782
2782
|
}, 0)
|
|
2783
2783
|
)
|
|
2784
2784
|
), Z = parseFloat(Number(A / (m.length || 1)));
|
|
2785
|
-
Z = M(h, u(Z,
|
|
2785
|
+
Z = M(h, u(Z, c));
|
|
2786
2786
|
var Y = D(o, a || "\u5E73\u5747\u503C:", N);
|
|
2787
2787
|
P.append(`<td style="text-align: ${o.tableSummaryAlign || "center"}">${Y}${Z}</td>`);
|
|
2788
2788
|
break;
|
|
2789
2789
|
case "min":
|
|
2790
2790
|
var L = Math.min(...m);
|
|
2791
|
-
L = M(h, u(L,
|
|
2791
|
+
L = M(h, u(L, c));
|
|
2792
2792
|
var Y = D(o, a || "\u6700\u5C0F\u503C:", N);
|
|
2793
2793
|
P.append(`<td style="text-align: ${o.tableSummaryAlign || "center"}">${Y}${L || 0}</td>`);
|
|
2794
2794
|
break;
|
|
2795
2795
|
case "max":
|
|
2796
2796
|
var J = Math.max(...m), Y = D(o, a || "\u6700\u5927\u503C:", N);
|
|
2797
|
-
J = M(h, u(J,
|
|
2797
|
+
J = M(h, u(J, c)), P.append(`<td style="text-align: ${o.tableSummaryAlign || "center"}">${Y}${J || 0}</td>`);
|
|
2798
2798
|
break;
|
|
2799
2799
|
case "text":
|
|
2800
2800
|
P.append(`<td style="text-align: ${o.tableSummaryAlign || "center"}">${a || ""}</td>`);
|
|
@@ -2806,11 +2806,11 @@ var At = function(q) {
|
|
|
2806
2806
|
}), T.append(P);
|
|
2807
2807
|
}
|
|
2808
2808
|
return S && T.append(S(w, s, N, r)), T;
|
|
2809
|
-
}, l.tableSummaryTitle = function(
|
|
2810
|
-
var C =
|
|
2809
|
+
}, l.tableSummaryTitle = function(I, s, w) {
|
|
2810
|
+
var C = I.tableSummaryTitle == null || I.tableSummaryTitle == !0;
|
|
2811
2811
|
return C ? `${s}` : w ? "" : `<span style="color:firebrick">${s}</span>`;
|
|
2812
|
-
}, l.createTableRow = function(
|
|
2813
|
-
var N = this, r = l.reconsitutionTableColumnTree(
|
|
2812
|
+
}, l.createTableRow = function(I, s, w, C) {
|
|
2813
|
+
var N = this, r = l.reconsitutionTableColumnTree(I), T = x("<tbody></tbody>"), S = N.getGroupFieldsFormatter(w, C), D = S ? w.groupFields = S(C, w, s) : C.groupFields ? C.groupFields : [];
|
|
2814
2814
|
return s || (s = []), D.length ? E.a.groupBy(s, D, function(H) {
|
|
2815
2815
|
var j = {};
|
|
2816
2816
|
return D.forEach(function(v) {
|
|
@@ -2824,8 +2824,8 @@ var At = function(q) {
|
|
|
2824
2824
|
}
|
|
2825
2825
|
var P = N.getGroupFooterFormatter(w, C);
|
|
2826
2826
|
if (H.rows.forEach(function(m, a) {
|
|
2827
|
-
var
|
|
2828
|
-
T.append(
|
|
2827
|
+
var c = l.createRowTarget(r, m, w, C, a);
|
|
2828
|
+
T.append(c);
|
|
2829
2829
|
}), P) {
|
|
2830
2830
|
var o = x("<tr><td colspan=" + r.colspan + "></td></tr>");
|
|
2831
2831
|
o.find("td").append(P(H, w)), T.append(o);
|
|
@@ -2834,11 +2834,11 @@ var At = function(q) {
|
|
|
2834
2834
|
var v = l.createRowTarget(r, H, w, C, j);
|
|
2835
2835
|
T.append(v);
|
|
2836
2836
|
}), T;
|
|
2837
|
-
}, l.createRowTarget = function(
|
|
2838
|
-
var r = x("<tr></tr>"), T =
|
|
2837
|
+
}, l.createRowTarget = function(I, s, w, C, N) {
|
|
2838
|
+
var r = x("<tr></tr>"), T = I.rowColumns.filter(function(H) {
|
|
2839
2839
|
return H.checked;
|
|
2840
2840
|
});
|
|
2841
|
-
r.data("rowData", s),
|
|
2841
|
+
r.data("rowData", s), I.rowColumns.filter(function(H) {
|
|
2842
2842
|
return H.checked;
|
|
2843
2843
|
}).forEach(function(H, j) {
|
|
2844
2844
|
if (!!H.checked) {
|
|
@@ -2858,16 +2858,16 @@ var At = function(q) {
|
|
|
2858
2858
|
o.css("width", (m || H.width) + "pt");
|
|
2859
2859
|
} else
|
|
2860
2860
|
H.field && o.attr("field", H.field), H.align && o.css("text-align", H.align), H.vAlign && o.css("vertical-align", H.vAlign);
|
|
2861
|
-
var a = l.getColumnFormatter(H),
|
|
2861
|
+
var a = l.getColumnFormatter(H), c = a ? a(s[H.field], s, j, w) : s[H.field], h = l.getColumnRenderFormatter(H);
|
|
2862
2862
|
if (h)
|
|
2863
2863
|
o.html(h(s[H.field], s, j, w));
|
|
2864
2864
|
else if (H.tableTextType == "text" || H.tableTextType == null)
|
|
2865
|
-
o.html(
|
|
2865
|
+
o.html(c);
|
|
2866
2866
|
else {
|
|
2867
2867
|
if (H.tableTextType == "barcode") {
|
|
2868
2868
|
o.html('<svg width="100%" display="block" height="100%" class="hibarcode_imgcode" preserveAspectRatio="none slice"></svg ><div class="hibarcode_displayValue"></div>');
|
|
2869
2869
|
try {
|
|
2870
|
-
|
|
2870
|
+
c ? (Ot(o.find(".hibarcode_imgcode")[0], c, {
|
|
2871
2871
|
format: H.tableBarcodeMode || "CODE128A",
|
|
2872
2872
|
width: 1,
|
|
2873
2873
|
textMargin: -1,
|
|
@@ -2880,15 +2880,15 @@ var At = function(q) {
|
|
|
2880
2880
|
console.log(L), o.html("\u6B64\u683C\u5F0F\u4E0D\u652F\u6301\u8BE5\u6587\u672C");
|
|
2881
2881
|
}
|
|
2882
2882
|
}
|
|
2883
|
-
if (H.tableTextType == "image" && (o.html(""),
|
|
2883
|
+
if (H.tableTextType == "image" && (o.html(""), c)) {
|
|
2884
2884
|
var M = x('<div><img style = "max-width:100%;max-height:100%"/></div>');
|
|
2885
|
-
M.find("img").attr("src",
|
|
2885
|
+
M.find("img").attr("src", c), console.log(M.find("img").css("width")), o.html(M);
|
|
2886
2886
|
}
|
|
2887
2887
|
if (H.tableTextType == "qrcode") {
|
|
2888
2888
|
o.html("");
|
|
2889
2889
|
try {
|
|
2890
2890
|
var u = x("<div></div>");
|
|
2891
|
-
if (
|
|
2891
|
+
if (c) {
|
|
2892
2892
|
var d = parseInt(H.width || H.targetWidth || 20), A = parseInt(H.tableColumnHeight || 20);
|
|
2893
2893
|
u.css("height", (d > A ? A : d) + "pt"), new QRCode(u[0], {
|
|
2894
2894
|
width: d > A ? A : d,
|
|
@@ -2896,7 +2896,7 @@ var At = function(q) {
|
|
|
2896
2896
|
colorDark: "#000000",
|
|
2897
2897
|
useSVG: !0,
|
|
2898
2898
|
correctLevel: H.tableQRCodeLevel || 0
|
|
2899
|
-
}).makeCode(
|
|
2899
|
+
}).makeCode(c), o.html(u);
|
|
2900
2900
|
}
|
|
2901
2901
|
} catch (L) {
|
|
2902
2902
|
console.log(L), o.html("\u4E8C\u7EF4\u7801\u751F\u6210\u5931\u8D25");
|
|
@@ -2922,17 +2922,17 @@ var At = function(q) {
|
|
|
2922
2922
|
});
|
|
2923
2923
|
}
|
|
2924
2924
|
return r;
|
|
2925
|
-
}, l.createEmptyRowTarget = function(
|
|
2926
|
-
var w = l.reconsitutionTableColumnTree(
|
|
2925
|
+
}, l.createEmptyRowTarget = function(I, s) {
|
|
2926
|
+
var w = l.reconsitutionTableColumnTree(I), C = x("<tr></tr>");
|
|
2927
2927
|
return w.rowColumns.filter(function(N) {
|
|
2928
2928
|
return N.checked;
|
|
2929
2929
|
}).forEach(function(N, r) {
|
|
2930
2930
|
var T = x("<td></td>");
|
|
2931
2931
|
N.field && T.attr("field", N.field), N.align && T.css("text-align", N.align), N.vAlign && T.css("vertical-align", N.vAlign), C.append(T);
|
|
2932
2932
|
}), s && s.options.tableBodyRowHeight && C.find("td:not([rowspan])").css("height", s.options.tableBodyRowHeight + "pt"), C;
|
|
2933
|
-
}, l.getColumnsWidth = function(
|
|
2934
|
-
var w = {}, C = l.allAutoWidth(
|
|
2935
|
-
return
|
|
2933
|
+
}, l.getColumnsWidth = function(I, s) {
|
|
2934
|
+
var w = {}, C = l.allAutoWidth(I), N = l.allFixedWidth(I);
|
|
2935
|
+
return I.rowColumns.filter(function(r) {
|
|
2936
2936
|
return r.checked;
|
|
2937
2937
|
}).forEach(function(r) {
|
|
2938
2938
|
if (r.fixed)
|
|
@@ -2942,155 +2942,155 @@ var At = function(q) {
|
|
|
2942
2942
|
w[r.id] = S;
|
|
2943
2943
|
}
|
|
2944
2944
|
}), w;
|
|
2945
|
-
}, l.resizeTableCellWidth = function(
|
|
2945
|
+
}, l.resizeTableCellWidth = function(I, s, w) {
|
|
2946
2946
|
var C = l.reconsitutionTableColumnTree(s), N = l.getColumnsWidth(C, w);
|
|
2947
|
-
|
|
2947
|
+
I.find("thead tr td[haswidth]").map(function(r, T) {
|
|
2948
2948
|
var S = x(T).attr("id"), D = N[S];
|
|
2949
2949
|
x(T).css("width", D + "pt");
|
|
2950
2950
|
});
|
|
2951
|
-
}, l.allAutoWidth = function(
|
|
2951
|
+
}, l.allAutoWidth = function(I) {
|
|
2952
2952
|
var s = 0, w = {};
|
|
2953
|
-
return
|
|
2953
|
+
return I.rowColumns.filter(function(C) {
|
|
2954
2954
|
return C.checked;
|
|
2955
2955
|
}).forEach(function(C) {
|
|
2956
2956
|
w[C.id] ? w[C.id] = 0 : w[C.id] = C.width, s += C.fixed ? 0 : w[C.id];
|
|
2957
2957
|
}), s;
|
|
2958
|
-
}, l.allFixedWidth = function(
|
|
2958
|
+
}, l.allFixedWidth = function(I) {
|
|
2959
2959
|
var s = 0, w = {};
|
|
2960
|
-
return
|
|
2960
|
+
return I.rowColumns.filter(function(C) {
|
|
2961
2961
|
return C.checked;
|
|
2962
2962
|
}).forEach(function(C) {
|
|
2963
2963
|
w[C.id] ? w[C.id] = 0 : w[C.id] = C.width, s += C.fixed ? w[C.id] : 0;
|
|
2964
2964
|
}), s;
|
|
2965
|
-
}, l.reconsitutionTableColumnTree = function(
|
|
2965
|
+
}, l.reconsitutionTableColumnTree = function(I, s, w) {
|
|
2966
2966
|
var C = s || new W.a();
|
|
2967
2967
|
C.colspan = 0;
|
|
2968
2968
|
for (var N = function(S) {
|
|
2969
|
-
C.totalLayer = S + 1, C[S] =
|
|
2969
|
+
C.totalLayer = S + 1, C[S] = I[S].columns, S == 0 && I[S].columns.forEach(function(D) {
|
|
2970
2970
|
S == 0 && (C.colspan += D.colspan);
|
|
2971
2971
|
});
|
|
2972
|
-
}, r = 0; r <
|
|
2972
|
+
}, r = 0; r < I.length; r++)
|
|
2973
2973
|
N(r);
|
|
2974
2974
|
return C.rowColumns = l.getOrderdColumns(C), C;
|
|
2975
|
-
}, l.syncTargetWidthToOption = function(
|
|
2976
|
-
|
|
2975
|
+
}, l.syncTargetWidthToOption = function(I) {
|
|
2976
|
+
I.forEach(function(s) {
|
|
2977
2977
|
s.columns.forEach(function(w) {
|
|
2978
2978
|
w.hasWidth && (w.width = w.targetWidth);
|
|
2979
2979
|
});
|
|
2980
2980
|
});
|
|
2981
|
-
}, l.getGroupFieldsFormatter = function(
|
|
2981
|
+
}, l.getGroupFieldsFormatter = function(I, s) {
|
|
2982
2982
|
var w = void 0;
|
|
2983
2983
|
if (s.groupFields && s.groupFields.length) {
|
|
2984
2984
|
var C = typeof s.groupFields == "string" ? s.groupFields : JSON.stringify(s.groupFields);
|
|
2985
|
-
|
|
2985
|
+
I.groupFieldsFormatter = "function(groupData,options){ return " + C + " }";
|
|
2986
2986
|
}
|
|
2987
|
-
if (s.groupFieldsFormatter && (w = s.groupFieldsFormatter),
|
|
2987
|
+
if (s.groupFieldsFormatter && (w = s.groupFieldsFormatter), I.groupFieldsFormatter)
|
|
2988
2988
|
try {
|
|
2989
|
-
var N = "groupFieldsFormatter=" +
|
|
2989
|
+
var N = "groupFieldsFormatter=" + I.groupFieldsFormatter;
|
|
2990
2990
|
w = eval2(N);
|
|
2991
2991
|
} catch (r) {
|
|
2992
2992
|
console.log(r);
|
|
2993
2993
|
}
|
|
2994
2994
|
return w;
|
|
2995
|
-
}, l.getGroupFormatter = function(
|
|
2995
|
+
}, l.getGroupFormatter = function(I, s) {
|
|
2996
2996
|
var w = void 0;
|
|
2997
|
-
if (s.groupFormatter && (w = s.groupFormatter),
|
|
2997
|
+
if (s.groupFormatter && (w = s.groupFormatter), I.groupFormatter)
|
|
2998
2998
|
try {
|
|
2999
|
-
var C = "groupFormatter=" +
|
|
2999
|
+
var C = "groupFormatter=" + I.groupFormatter;
|
|
3000
3000
|
w = eval2(C);
|
|
3001
3001
|
} catch (N) {
|
|
3002
3002
|
console.log(N);
|
|
3003
3003
|
}
|
|
3004
3004
|
return w;
|
|
3005
|
-
}, l.getGroupFooterFormatter = function(
|
|
3005
|
+
}, l.getGroupFooterFormatter = function(I, s) {
|
|
3006
3006
|
var w = void 0;
|
|
3007
|
-
if (s.groupFooterFormatter && (w = s.groupFooterFormatter),
|
|
3007
|
+
if (s.groupFooterFormatter && (w = s.groupFooterFormatter), I.groupFooterFormatter)
|
|
3008
3008
|
try {
|
|
3009
|
-
var C = "groupFooterFormatter=" +
|
|
3009
|
+
var C = "groupFooterFormatter=" + I.groupFooterFormatter;
|
|
3010
3010
|
w = eval2(C);
|
|
3011
3011
|
} catch (N) {
|
|
3012
3012
|
console.log(N);
|
|
3013
3013
|
}
|
|
3014
3014
|
return w;
|
|
3015
|
-
}, l.getFooterFormatter = function(
|
|
3015
|
+
}, l.getFooterFormatter = function(I, s) {
|
|
3016
3016
|
var w = void 0;
|
|
3017
|
-
if (s.footerFormatter && (w = s.footerFormatter),
|
|
3017
|
+
if (s.footerFormatter && (w = s.footerFormatter), I.footerFormatter)
|
|
3018
3018
|
try {
|
|
3019
|
-
var C = "footerFormatter=" +
|
|
3019
|
+
var C = "footerFormatter=" + I.footerFormatter;
|
|
3020
3020
|
w = eval2(C);
|
|
3021
3021
|
} catch (N) {
|
|
3022
3022
|
console.log(N);
|
|
3023
3023
|
}
|
|
3024
3024
|
return w;
|
|
3025
|
-
}, l.getRowStyler = function(
|
|
3025
|
+
}, l.getRowStyler = function(I, s) {
|
|
3026
3026
|
var w = void 0;
|
|
3027
|
-
if (s.rowStyler && (w = s.rowStyler),
|
|
3027
|
+
if (s.rowStyler && (w = s.rowStyler), I.rowStyler)
|
|
3028
3028
|
try {
|
|
3029
|
-
var C = "rowStyler=" +
|
|
3029
|
+
var C = "rowStyler=" + I.rowStyler;
|
|
3030
3030
|
w = eval2(C);
|
|
3031
3031
|
} catch (N) {
|
|
3032
3032
|
console.log(N);
|
|
3033
3033
|
}
|
|
3034
3034
|
return w;
|
|
3035
|
-
}, l.getColumnStyler = function(
|
|
3035
|
+
}, l.getColumnStyler = function(I) {
|
|
3036
3036
|
var s = void 0;
|
|
3037
|
-
if (
|
|
3037
|
+
if (I.styler && (s = I.styler), I.styler2)
|
|
3038
3038
|
try {
|
|
3039
|
-
var w = "styler=" +
|
|
3039
|
+
var w = "styler=" + I.styler2;
|
|
3040
3040
|
s = eval2(w);
|
|
3041
3041
|
} catch (C) {
|
|
3042
3042
|
console.log(C);
|
|
3043
3043
|
}
|
|
3044
3044
|
return s;
|
|
3045
|
-
}, l.getHeaderStyler = function(
|
|
3045
|
+
}, l.getHeaderStyler = function(I) {
|
|
3046
3046
|
var s = void 0;
|
|
3047
|
-
if (
|
|
3047
|
+
if (I.stylerHeader && (s = I.stylerHeader), I.stylerHeader)
|
|
3048
3048
|
try {
|
|
3049
|
-
var w = "stylerHeader=" +
|
|
3049
|
+
var w = "stylerHeader=" + I.stylerHeader;
|
|
3050
3050
|
s = eval2(w);
|
|
3051
3051
|
} catch (C) {
|
|
3052
3052
|
console.log(C);
|
|
3053
3053
|
}
|
|
3054
3054
|
return s;
|
|
3055
|
-
}, l.getColumnRenderFormatter = function(
|
|
3055
|
+
}, l.getColumnRenderFormatter = function(I) {
|
|
3056
3056
|
var s = void 0;
|
|
3057
|
-
if (
|
|
3057
|
+
if (I.renderFormatter && (s = I.renderFormatter), I.renderFormatter)
|
|
3058
3058
|
try {
|
|
3059
|
-
var w = "renderFormatter=" +
|
|
3059
|
+
var w = "renderFormatter=" + I.renderFormatter;
|
|
3060
3060
|
s = eval2(w);
|
|
3061
3061
|
} catch (C) {
|
|
3062
3062
|
console.log(C);
|
|
3063
3063
|
}
|
|
3064
3064
|
return s;
|
|
3065
|
-
}, l.getColumnFormatter = function(
|
|
3065
|
+
}, l.getColumnFormatter = function(I) {
|
|
3066
3066
|
var s = void 0;
|
|
3067
|
-
if (
|
|
3067
|
+
if (I.formatter && (s = I.formatter), I.formatter2)
|
|
3068
3068
|
try {
|
|
3069
|
-
var w = "formatter=" +
|
|
3069
|
+
var w = "formatter=" + I.formatter2;
|
|
3070
3070
|
s = eval2(w);
|
|
3071
3071
|
} catch (C) {
|
|
3072
3072
|
console.log(C);
|
|
3073
3073
|
}
|
|
3074
3074
|
return s;
|
|
3075
|
-
}, l.getOrderdColumns = function(
|
|
3075
|
+
}, l.getOrderdColumns = function(I) {
|
|
3076
3076
|
let s = {};
|
|
3077
|
-
for (let C = 0; C <
|
|
3078
|
-
s[C] = [],
|
|
3077
|
+
for (let C = 0; C < I.totalLayer; C++)
|
|
3078
|
+
s[C] = [], I[C].forEach((N, r) => {
|
|
3079
3079
|
s[C].push(...new Array(N.colspan).fill({ ...N, colspan: 1 }));
|
|
3080
3080
|
});
|
|
3081
|
-
for (let C = 0; C <
|
|
3081
|
+
for (let C = 0; C < I.totalLayer; C++)
|
|
3082
3082
|
s[C].forEach((N, r) => {
|
|
3083
3083
|
for (let T = 1; T < N.rowspan; T++)
|
|
3084
3084
|
s[C + T].splice(r, 0, { ...N, rowspan: 1 });
|
|
3085
3085
|
});
|
|
3086
3086
|
let w = [];
|
|
3087
|
-
for (let C = 0; C <
|
|
3088
|
-
C >=
|
|
3087
|
+
for (let C = 0; C < I.totalLayer; C++)
|
|
3088
|
+
C >= I.totalLayer - 1 ? s[C].forEach((N, r) => {
|
|
3089
3089
|
N.field || (N.field = w[r]);
|
|
3090
3090
|
}) : s[C].forEach((N, r) => {
|
|
3091
3091
|
C == 0 ? w.push(N.field || "") : N.field && (w[r] = N.field);
|
|
3092
3092
|
});
|
|
3093
|
-
return this.rowColumns = s[
|
|
3093
|
+
return this.rowColumns = s[I.totalLayer - 1], s[I.totalLayer - 1];
|
|
3094
3094
|
}, l;
|
|
3095
3095
|
}();
|
|
3096
3096
|
},
|
|
@@ -3333,7 +3333,7 @@ var At = function(q) {
|
|
|
3333
3333
|
}, n.prototype.destroy = function() {
|
|
3334
3334
|
this.target.remove();
|
|
3335
3335
|
}, n;
|
|
3336
|
-
}(),
|
|
3336
|
+
}(), I = function() {
|
|
3337
3337
|
function n() {
|
|
3338
3338
|
this.name = "letterSpacing";
|
|
3339
3339
|
}
|
|
@@ -4052,7 +4052,7 @@ var At = function(q) {
|
|
|
4052
4052
|
}, n.prototype.destroy = function() {
|
|
4053
4053
|
this.target.remove();
|
|
4054
4054
|
}, n;
|
|
4055
|
-
}(),
|
|
4055
|
+
}(), c = function() {
|
|
4056
4056
|
function n() {
|
|
4057
4057
|
this.name = "qrCodeLevel";
|
|
4058
4058
|
}
|
|
@@ -6868,7 +6868,7 @@ var At = function(q) {
|
|
|
6868
6868
|
new E(),
|
|
6869
6869
|
new b(),
|
|
6870
6870
|
new l(),
|
|
6871
|
-
new
|
|
6871
|
+
new I(),
|
|
6872
6872
|
new W(),
|
|
6873
6873
|
new s(),
|
|
6874
6874
|
new w(),
|
|
@@ -6886,7 +6886,7 @@ var At = function(q) {
|
|
|
6886
6886
|
new o(),
|
|
6887
6887
|
new m(),
|
|
6888
6888
|
new a(),
|
|
6889
|
-
new
|
|
6889
|
+
new c(),
|
|
6890
6890
|
new h(),
|
|
6891
6891
|
new M(),
|
|
6892
6892
|
new u(),
|
|
@@ -7011,7 +7011,7 @@ var At = function(q) {
|
|
|
7011
7011
|
this.rows.forEach(function(N, r) {
|
|
7012
7012
|
var T = [];
|
|
7013
7013
|
N.columns.forEach(function(S) {
|
|
7014
|
-
S.isInRect(w) && (T.push(new
|
|
7014
|
+
S.isInRect(w) && (T.push(new I(r, S)), S.select());
|
|
7015
7015
|
}), T.length && C.push(T);
|
|
7016
7016
|
}), w.changed && (w.changed = !1, C.splice(0, C.length), this.selectByRect(w, C));
|
|
7017
7017
|
}, s.prototype.getSelectedCells = function() {
|
|
@@ -7024,7 +7024,7 @@ var At = function(q) {
|
|
|
7024
7024
|
}).filter(function(D) {
|
|
7025
7025
|
return D.isXYinCell(w, C);
|
|
7026
7026
|
});
|
|
7027
|
-
S.length && (N = new
|
|
7027
|
+
S.length && (N = new I(T, S[0]));
|
|
7028
7028
|
}), N;
|
|
7029
7029
|
}, s;
|
|
7030
7030
|
}(), b = function() {
|
|
@@ -7035,7 +7035,7 @@ var At = function(q) {
|
|
|
7035
7035
|
return function(s) {
|
|
7036
7036
|
this.rect = s;
|
|
7037
7037
|
};
|
|
7038
|
-
}(),
|
|
7038
|
+
}(), I = function() {
|
|
7039
7039
|
return function(s, w) {
|
|
7040
7040
|
this.rowIndex = s, this.cell = w;
|
|
7041
7041
|
};
|
|
@@ -7055,7 +7055,7 @@ var At = function(q) {
|
|
|
7055
7055
|
},
|
|
7056
7056
|
function(q, F, g) {
|
|
7057
7057
|
g.d(F, "a", function() {
|
|
7058
|
-
return
|
|
7058
|
+
return I;
|
|
7059
7059
|
});
|
|
7060
7060
|
var W, E = g(5), b = g(13), l = (W = function(w, C) {
|
|
7061
7061
|
return (W = Object.setPrototypeOf || Dt(
|
|
@@ -7074,7 +7074,7 @@ var At = function(q) {
|
|
|
7074
7074
|
this.constructor = s;
|
|
7075
7075
|
}
|
|
7076
7076
|
W(s, w), s.prototype = w === null ? Object.create(w) : (C.prototype = w.prototype, new C());
|
|
7077
|
-
}),
|
|
7077
|
+
}), I = function(s) {
|
|
7078
7078
|
function w(C) {
|
|
7079
7079
|
var N = s.call(this) || this;
|
|
7080
7080
|
return N.columns = [], C && C.constructor === Array ? (C || []).forEach(function(r) {
|
|
@@ -7101,48 +7101,48 @@ var At = function(q) {
|
|
|
7101
7101
|
function l() {
|
|
7102
7102
|
this.id = W.a.createId();
|
|
7103
7103
|
}
|
|
7104
|
-
return l.prototype.init = function(
|
|
7105
|
-
this.isHead = w, this.target = s || x("<tr></tr>"), this.tableOptions =
|
|
7104
|
+
return l.prototype.init = function(I, s, w) {
|
|
7105
|
+
this.isHead = w, this.target = s || x("<tr></tr>"), this.tableOptions = I, this.allColumns = this.columns || [], this.initCells(
|
|
7106
7106
|
(this.columns || []).filter(function(C) {
|
|
7107
7107
|
return C.checked;
|
|
7108
7108
|
})
|
|
7109
7109
|
);
|
|
7110
7110
|
}, l.prototype.getTarget = function() {
|
|
7111
7111
|
return this.target;
|
|
7112
|
-
}, l.prototype.initCells = function(
|
|
7112
|
+
}, l.prototype.initCells = function(I) {
|
|
7113
7113
|
var s = this;
|
|
7114
|
-
|
|
7114
|
+
I ? (this.columns = I, I.forEach(function(w, C) {
|
|
7115
7115
|
w.init(s.target.find("td:eq(" + C + ")"), s.tableOptions, s.id, s.isHead);
|
|
7116
7116
|
})) : (this.columns = [], this.target.find("td").map(function(w, C) {
|
|
7117
7117
|
var N = new E.a();
|
|
7118
7118
|
N.init(x(C), s.tableOptions, s.id, s.isHead), s.columns.push(N);
|
|
7119
7119
|
}));
|
|
7120
|
-
}, l.prototype.removeCell = function(
|
|
7121
|
-
var s = this.columns.indexOf(
|
|
7120
|
+
}, l.prototype.removeCell = function(I) {
|
|
7121
|
+
var s = this.columns.indexOf(I);
|
|
7122
7122
|
this.columns[s].getTarget().remove(), this.columns.splice(s, 1);
|
|
7123
|
-
}, l.prototype.createTableCell = function(
|
|
7123
|
+
}, l.prototype.createTableCell = function(I, s) {
|
|
7124
7124
|
var w = new E.a();
|
|
7125
|
-
return w.init(x("<td></td>"), this.tableOptions, this.id, this.isHead),
|
|
7126
|
-
}, l.prototype.insertToTargetCellLeft = function(
|
|
7127
|
-
var w = this.columns.indexOf(
|
|
7128
|
-
|
|
7129
|
-
}, l.prototype.insertToTargetCellRight = function(
|
|
7130
|
-
var w = this.columns.indexOf(
|
|
7125
|
+
return w.init(x("<td></td>"), this.tableOptions, this.id, this.isHead), I > 1 && (w.getTarget().attr("rowspan", I), w.rowspan = I), s > 1 && (w.getTarget().attr("colspan", s), w.colspan = s), w;
|
|
7126
|
+
}, l.prototype.insertToTargetCellLeft = function(I, s) {
|
|
7127
|
+
var w = this.columns.indexOf(I);
|
|
7128
|
+
I.getTarget().before(s.getTarget()), this.columns.splice(w, 0, s);
|
|
7129
|
+
}, l.prototype.insertToTargetCellRight = function(I, s) {
|
|
7130
|
+
var w = this.columns.indexOf(I);
|
|
7131
7131
|
this.columns[w].getTarget().after(s.getTarget()), this.columns.splice(w + 1, 0, s);
|
|
7132
|
-
}, l.prototype.insertCellToFirst = function(
|
|
7133
|
-
this.target.prepend(
|
|
7134
|
-
}, l.prototype.insertCellToLast = function(
|
|
7135
|
-
this.columns.push(
|
|
7132
|
+
}, l.prototype.insertCellToFirst = function(I) {
|
|
7133
|
+
this.target.prepend(I.getTarget()), this.columns.splice(0, 0, I);
|
|
7134
|
+
}, l.prototype.insertCellToLast = function(I) {
|
|
7135
|
+
this.columns.push(I), this.target.append(I.getTarget());
|
|
7136
7136
|
}, l.prototype.getPrintElementOptionEntity = function() {
|
|
7137
|
-
var
|
|
7137
|
+
var I = [];
|
|
7138
7138
|
return [
|
|
7139
7139
|
...this.columns,
|
|
7140
7140
|
...this.allColumns.filter(function(s) {
|
|
7141
7141
|
return !s.checked;
|
|
7142
7142
|
})
|
|
7143
7143
|
].forEach(function(s) {
|
|
7144
|
-
|
|
7145
|
-
}),
|
|
7144
|
+
I.push(s.getEntity());
|
|
7145
|
+
}), I;
|
|
7146
7146
|
}, l;
|
|
7147
7147
|
}();
|
|
7148
7148
|
},
|
|
@@ -7153,20 +7153,20 @@ var At = function(q) {
|
|
|
7153
7153
|
var W = g(10), E = function() {
|
|
7154
7154
|
function b() {
|
|
7155
7155
|
}
|
|
7156
|
-
return b.mergeRect = function(l,
|
|
7157
|
-
var s = Math.min(l.x,
|
|
7156
|
+
return b.mergeRect = function(l, I) {
|
|
7157
|
+
var s = Math.min(l.x, I.x), w = Math.min(l.y, I.y);
|
|
7158
7158
|
return new W.b({
|
|
7159
7159
|
x: s,
|
|
7160
7160
|
y: w,
|
|
7161
|
-
height: Math.max(l.y + l.height,
|
|
7162
|
-
width: Math.max(l.x + l.width,
|
|
7161
|
+
height: Math.max(l.y + l.height, I.y + I.height) - w,
|
|
7162
|
+
width: Math.max(l.x + l.width, I.x + I.width) - s
|
|
7163
7163
|
});
|
|
7164
|
-
}, b.Rect = function(l,
|
|
7164
|
+
}, b.Rect = function(l, I, s, w) {
|
|
7165
7165
|
return {
|
|
7166
7166
|
minX: l < s ? l : s,
|
|
7167
|
-
minY:
|
|
7167
|
+
minY: I < w ? I : w,
|
|
7168
7168
|
maxX: l < s ? s : l,
|
|
7169
|
-
maxY:
|
|
7169
|
+
maxY: I < w ? w : I
|
|
7170
7170
|
};
|
|
7171
7171
|
}, b;
|
|
7172
7172
|
}();
|
|
@@ -7175,7 +7175,7 @@ var At = function(q) {
|
|
|
7175
7175
|
g.d(F, "a", function() {
|
|
7176
7176
|
return D;
|
|
7177
7177
|
});
|
|
7178
|
-
var W = g(4), E = g(1), b = g(6), l = g(0),
|
|
7178
|
+
var W = g(4), E = g(1), b = g(6), l = g(0), I = g(8), s = g(18), w = g(7), C = g(16), N = g(20), r = g(2), T = (S = function(j, v) {
|
|
7179
7179
|
return (S = Object.setPrototypeOf || Dt(
|
|
7180
7180
|
{
|
|
7181
7181
|
__proto__: []
|
|
@@ -7228,8 +7228,8 @@ var At = function(q) {
|
|
|
7228
7228
|
}, j.prototype.createTarget = function(v, P, o) {
|
|
7229
7229
|
for (var m = x(
|
|
7230
7230
|
'<div class="hiprint-printElement hiprint-printElement-table" style="position: absolute;"><div class="hiprint-printElement-table-handle"></div><div class="hiprint-printElement-table-content" style="height:100%;width:100%"></span></div>'
|
|
7231
|
-
), a = this.createGridColumnsStructure(o),
|
|
7232
|
-
a.getByIndex(
|
|
7231
|
+
), a = this.createGridColumnsStructure(o), c = 0; c < a.gridColumns; c++)
|
|
7232
|
+
a.getByIndex(c).append(this.getTableHtml(P, o));
|
|
7233
7233
|
return m.find(".hiprint-printElement-table-content").append(a.target), m;
|
|
7234
7234
|
}, j.prototype.createGridColumnsStructure = function(v) {
|
|
7235
7235
|
for (var P = x('<div class="hi-grid-row table-grid-row"></div>'), o = 0; o < this.options.getGridColumns(); o++) {
|
|
@@ -7238,8 +7238,8 @@ var At = function(q) {
|
|
|
7238
7238
|
}
|
|
7239
7239
|
var a = this.getGridColumnsFooterFormatter();
|
|
7240
7240
|
if (a) {
|
|
7241
|
-
var
|
|
7242
|
-
|
|
7241
|
+
var c = x('<div class="hiprint-gridColumnsFooter"></div>');
|
|
7242
|
+
c.append(a(this.options, this.getData(v), v, [])), P.append(c);
|
|
7243
7243
|
}
|
|
7244
7244
|
return new N.a(this.options.getGridColumns(), P);
|
|
7245
7245
|
}, j.prototype.createtempEmptyRowsTargetStructure = function(v) {
|
|
@@ -7262,10 +7262,10 @@ var At = function(q) {
|
|
|
7262
7262
|
var o = this.getPaperHtmlResult(v, P);
|
|
7263
7263
|
return this.removeTempContainer(), o;
|
|
7264
7264
|
}, j.prototype.getPaperHtmlResult = function(v, P) {
|
|
7265
|
-
var o = [], m = this.getData(P), a = this.getTableHtml(m, P),
|
|
7266
|
-
P ? this.updateTargetWidth(
|
|
7267
|
-
var h =
|
|
7268
|
-
|
|
7265
|
+
var o = [], m = this.getData(P), a = this.getTableHtml(m, P), c = this.createtempEmptyRowsTargetStructure(P);
|
|
7266
|
+
P ? this.updateTargetWidth(c) : this.updateTargetSize(c), this.css(c, m), this.css(a, m), this.getTempContainer().html(""), this.getTempContainer().append(c);
|
|
7267
|
+
var h = c.find("tfoot").outerHeight() || 0;
|
|
7268
|
+
c.find("tfoot").remove();
|
|
7269
7269
|
for (var M, u = this.getBeginPrintTopInPaperByReferenceElement(v), d = 0, A = !1; !A; ) {
|
|
7270
7270
|
var Z = 0, L = v.getPaperFooter(d);
|
|
7271
7271
|
d == 0 && u > L && v.panelPageRule != "none" && (u = u - L + v.paperHeader, o.push(
|
|
@@ -7274,10 +7274,10 @@ var At = function(q) {
|
|
|
7274
7274
|
printLine: void 0
|
|
7275
7275
|
})
|
|
7276
7276
|
), Z = v.getContentHeight(d) - (u - v.paperHeader), d++, L = v.getPaperFooter(d));
|
|
7277
|
-
var J = o.length > 0 ? o[o.length - 1].target : void 0, Y = this.getRowsInSpecificHeight(P, Z > 0 ? Z : d == 0 ? L - u : v.getContentHeight(d),
|
|
7277
|
+
var J = o.length > 0 ? o[o.length - 1].target : void 0, Y = this.getRowsInSpecificHeight(P, Z > 0 ? Z : d == 0 ? L - u : v.getContentHeight(d), c, a, d, J, h);
|
|
7278
7278
|
if (A = Y.isEnd, Z < 0) {
|
|
7279
7279
|
var R = this.options.top;
|
|
7280
|
-
o[0].target = x('<div style="position:absolute;background:red;color:white;padding:0px 4px;">\u6CA1\u6709\u8DB3\u591F\u7A7A\u95F4\u8FDB\u884C\u8868\u683C\u5206\u9875\uFF0C\u8BF7\u8C03\u6574\u9875\u7709/\u9875\u811A\u7EBF\u7EBF\u6216\u8C03\u6574\u7EB8\u5F20\u5927\u5C0F</div>'), o[0].printLine = u, o[0].referenceElement = new
|
|
7280
|
+
o[0].target = x('<div style="position:absolute;background:red;color:white;padding:0px 4px;">\u6CA1\u6709\u8DB3\u591F\u7A7A\u95F4\u8FDB\u884C\u8868\u683C\u5206\u9875\uFF0C\u8BF7\u8C03\u6574\u9875\u7709/\u9875\u811A\u7EBF\u7EBF\u6216\u8C03\u6574\u7EB8\u5F20\u5927\u5C0F</div>'), o[0].printLine = u, o[0].referenceElement = new I.a({
|
|
7281
7281
|
top: this.options.getTop(),
|
|
7282
7282
|
left: this.options.getLeft(),
|
|
7283
7283
|
height: this.options.getHeight(),
|
|
@@ -7293,7 +7293,7 @@ var At = function(q) {
|
|
|
7293
7293
|
new b.a({
|
|
7294
7294
|
target: Y.target,
|
|
7295
7295
|
printLine: V,
|
|
7296
|
-
referenceElement: new
|
|
7296
|
+
referenceElement: new I.a({
|
|
7297
7297
|
top: this.options.getTop(),
|
|
7298
7298
|
left: this.options.getLeft(),
|
|
7299
7299
|
height: this.options.getHeight(),
|
|
@@ -7306,7 +7306,7 @@ var At = function(q) {
|
|
|
7306
7306
|
), d++, P && this.updatePanelHeight(V + this.options.getHeight(), v);
|
|
7307
7307
|
}
|
|
7308
7308
|
return o;
|
|
7309
|
-
}, j.prototype.getRowsInSpecificHeight = function(v, P, o, m, a,
|
|
7309
|
+
}, j.prototype.getRowsInSpecificHeight = function(v, P, o, m, a, c, h) {
|
|
7310
7310
|
var M = this, u = m.find("tbody"), d = l.a.pt.toPx(P);
|
|
7311
7311
|
o.find(".hiprint-printElement-tableTarget tbody").html(""), this.options.tableFooterRepeat != "last" && o.find(".hiprint-printElement-tableTarget tfoot").remove(), this.options.tableHeaderRepeat == "first" && a > 0 ? o.find(".hiprint-printElement-tableTarget thead").remove() : this.options.tableHeaderRepeat == "none" && (v ? o.find(".hiprint-printElement-tableTarget thead").remove() : (o.find(".hiprint-printElement-tableTarget thead").css("background", "firebrick"), o.find(".hiprint-printElement-tableTarget thead tr").css("background", "firebrick")));
|
|
7312
7312
|
var A = this.panel.panelPageRule == "none", Z = o.outerHeight();
|
|
@@ -7359,7 +7359,7 @@ var At = function(q) {
|
|
|
7359
7359
|
}
|
|
7360
7360
|
var pt = o.find(".hiprint-printElement-tableTarget tbody tr").length, st = this.getGridColumnsFooterFormatter();
|
|
7361
7361
|
st && o.find(this.gridColumnsFooterCss).html(st(this.options, this.getData(v), v, J)), Z = o.outerHeight();
|
|
7362
|
-
var ht = u.find("tr").length == 0 ? pt == 0 &&
|
|
7362
|
+
var ht = u.find("tr").length == 0 ? pt == 0 && c ? {
|
|
7363
7363
|
target: void 0,
|
|
7364
7364
|
length: 0,
|
|
7365
7365
|
height: 0,
|
|
@@ -7378,14 +7378,14 @@ var At = function(q) {
|
|
|
7378
7378
|
return ht;
|
|
7379
7379
|
}, j.prototype.fixMergeSpan = function(v, P) {
|
|
7380
7380
|
var o = this;
|
|
7381
|
-
let m = 1, a = !1,
|
|
7381
|
+
let m = 1, a = !1, c = 1, h = !1;
|
|
7382
7382
|
return v.nextAll().each(function(M) {
|
|
7383
|
-
x(this).children().filter("td[rowspan=0]").length > 0 && !a ? m += 1 : a = !0, x(this).children().filter("td[colspan=0]").length > 0 && !h ?
|
|
7383
|
+
x(this).children().filter("td[rowspan=0]").length > 0 && !a ? m += 1 : a = !0, x(this).children().filter("td[colspan=0]").length > 0 && !h ? c += 1 : h = !0;
|
|
7384
7384
|
}), v.children().each(function(M, u) {
|
|
7385
|
-
x(u).attr("rowspan") < 1 && (x(u).attr("rowspan", m), x(u).css("display", ""), o.options.rowsColumnsMergeClean && x(u).text("")), x(u).attr("colspan") < 1 && (x(u).attr("colspan",
|
|
7385
|
+
x(u).attr("rowspan") < 1 && (x(u).attr("rowspan", m), x(u).css("display", ""), o.options.rowsColumnsMergeClean && x(u).text("")), x(u).attr("colspan") < 1 && (x(u).attr("colspan", c), x(u).css("display", ""), o.options.rowsColumnsMergeClean && x(u).text(""));
|
|
7386
7386
|
}), v;
|
|
7387
7387
|
}, j.prototype.autoCompletion = function(v, P) {
|
|
7388
|
-
for (var o = this, m, a = this.getEmptyRowTarget(),
|
|
7388
|
+
for (var o = this, m, a = this.getEmptyRowTarget(), c = P.outerHeight() + tfh; v > c && (m = a.clone(), P.find("tbody").append(m), c = P.outerHeight() + tfh, !(o.options.maxRows && P.find("tbody").children().length > o.options.maxRows)); )
|
|
7389
7389
|
;
|
|
7390
7390
|
m && m.remove();
|
|
7391
7391
|
}, j.prototype.getData = function(v) {
|
|
@@ -7403,8 +7403,8 @@ var At = function(q) {
|
|
|
7403
7403
|
handle: this.designTarget.find(".hiprint-printElement-table-handle"),
|
|
7404
7404
|
axis: o.options.axis ? o.options.axis : void 0,
|
|
7405
7405
|
designTarget: o,
|
|
7406
|
-
onDrag: function(a,
|
|
7407
|
-
o.updateSizeAndPositionOptions(
|
|
7406
|
+
onDrag: function(a, c, h) {
|
|
7407
|
+
o.updateSizeAndPositionOptions(c, h), o.createLineOfPosition(P), r.a.instance.changed = !0;
|
|
7408
7408
|
},
|
|
7409
7409
|
moveUnit: "pt",
|
|
7410
7410
|
minMove: E.a.instance.movingDistance,
|
|
@@ -7427,8 +7427,8 @@ var At = function(q) {
|
|
|
7427
7427
|
getScale: function() {
|
|
7428
7428
|
return o.designPaper.scale || 1;
|
|
7429
7429
|
},
|
|
7430
|
-
onResize: function(a,
|
|
7431
|
-
o.onResize(a,
|
|
7430
|
+
onResize: function(a, c, h, M, u) {
|
|
7431
|
+
o.onResize(a, c, h, M, u), o.hitable && o.hitable.updateColumnGrips(), o.createLineOfPosition(P);
|
|
7432
7432
|
},
|
|
7433
7433
|
onStopResize: function(a) {
|
|
7434
7434
|
l.a.event.trigger("hiprintTemplateDataChanged_" + o.templateId, a ? "\u65CB\u8F6C" : "\u5927\u5C0F"), r.a.instance.draging = !1, o.removeLineOfPosition();
|
|
@@ -7541,18 +7541,18 @@ var At = function(q) {
|
|
|
7541
7541
|
return function(P) {
|
|
7542
7542
|
this.cell = P.cell, this.link = P.link, this.linkType = P.linkType, this.bottom = P.bottom, this.rightMost = P.rightMost, this.rowLevel = P.rowLevel, this.columnLevel = P.columnLevel, this.indexInTableGridRow = P.indexInTableGridRow, this.indexInTableGridColumn = P.indexInTableGridColumn;
|
|
7543
7543
|
};
|
|
7544
|
-
}(),
|
|
7544
|
+
}(), I = g(10), s = function() {
|
|
7545
7545
|
function P() {
|
|
7546
7546
|
}
|
|
7547
7547
|
return P.getLeftTableCell = function(o, m) {
|
|
7548
7548
|
var a;
|
|
7549
|
-
return o.forEach(function(
|
|
7550
|
-
|
|
7549
|
+
return o.forEach(function(c, h) {
|
|
7550
|
+
c.cell && h < m && (a = c.cell);
|
|
7551
7551
|
}), a;
|
|
7552
7552
|
}, P.getIndex = function(o, m) {
|
|
7553
7553
|
var a;
|
|
7554
|
-
return o.forEach(function(
|
|
7555
|
-
|
|
7554
|
+
return o.forEach(function(c, h) {
|
|
7555
|
+
c.cell && c.cell.id == m && (a = h);
|
|
7556
7556
|
}), a;
|
|
7557
7557
|
}, P;
|
|
7558
7558
|
}(), w = g(13), C = g(11), N = function() {
|
|
@@ -7571,9 +7571,9 @@ var At = function(q) {
|
|
|
7571
7571
|
function P() {
|
|
7572
7572
|
}
|
|
7573
7573
|
return P.getColumnsWidth = function(o, m) {
|
|
7574
|
-
var a = {},
|
|
7574
|
+
var a = {}, c = P.allAutoWidth(o);
|
|
7575
7575
|
return o.rowColumns.forEach(function(h) {
|
|
7576
|
-
var M = m - 0, u = h.width /
|
|
7576
|
+
var M = m - 0, u = h.width / c * (M > 0 ? M : 0);
|
|
7577
7577
|
a[h.id] = u;
|
|
7578
7578
|
}), a;
|
|
7579
7579
|
}, P.resizeTableCellWeight = function(o) {
|
|
@@ -7588,15 +7588,15 @@ var At = function(q) {
|
|
|
7588
7588
|
m += a.width;
|
|
7589
7589
|
}), m;
|
|
7590
7590
|
}, P.reconsitutionTableColumnTree = function(o, m, a) {
|
|
7591
|
-
for (var
|
|
7592
|
-
|
|
7593
|
-
|
|
7591
|
+
for (var c = m || new T(), h = function(d) {
|
|
7592
|
+
c.totalLayer = d + 1, c[d] = o[d].columns, c.rowColumns = c.rowColumns.concat(
|
|
7593
|
+
c[d].filter(function(A) {
|
|
7594
7594
|
return A.rowspan == o.length - d;
|
|
7595
7595
|
})
|
|
7596
7596
|
);
|
|
7597
7597
|
}, M = 0; M < o.length; M++)
|
|
7598
7598
|
h(M);
|
|
7599
|
-
return
|
|
7599
|
+
return c;
|
|
7600
7600
|
}, P;
|
|
7601
7601
|
}(), D = g(2), H = function() {
|
|
7602
7602
|
function P(o) {
|
|
@@ -7608,14 +7608,14 @@ var At = function(q) {
|
|
|
7608
7608
|
S.resizeTableCellWeight(this.rows);
|
|
7609
7609
|
}, P.prototype.addResizeRowAndColumn = function() {
|
|
7610
7610
|
}, P.prototype.createColumnGrips = function() {
|
|
7611
|
-
var o = this, m = this, a = [],
|
|
7612
|
-
|
|
7611
|
+
var o = this, m = this, a = [], c = x('<div class="columngrips"/>');
|
|
7612
|
+
c.width(this.target.width()), this.rows.forEach(function(h) {
|
|
7613
7613
|
(h.columns || []).filter(function(M) {
|
|
7614
7614
|
return M.checked;
|
|
7615
7615
|
}).forEach(function(M, u) {
|
|
7616
7616
|
if (M.getTarget().attr("haswidth")) {
|
|
7617
7617
|
var d = x('<div class="columngrip"><div class="gripResizer"></div></div>');
|
|
7618
|
-
|
|
7618
|
+
c.append(d);
|
|
7619
7619
|
var A = new r(d);
|
|
7620
7620
|
a.length > 0 && (a[a.length - 1].nextGrip = A), a.push(A), o.syncGrips(M, A), x(d).hidraggable({
|
|
7621
7621
|
axis: "h",
|
|
@@ -7639,16 +7639,16 @@ var At = function(q) {
|
|
|
7639
7639
|
});
|
|
7640
7640
|
}
|
|
7641
7641
|
});
|
|
7642
|
-
}), this.target.before(
|
|
7642
|
+
}), this.target.before(c), this.cgripContariner = new N(c, a);
|
|
7643
7643
|
}, P.prototype.updateColumnGrips = function() {
|
|
7644
7644
|
this.cgripContariner && (this.cgripContariner.target.remove(), this.createColumnGrips());
|
|
7645
7645
|
}, P.prototype.updateRowGrips = function() {
|
|
7646
7646
|
this.rgripContariner && (this.rgripContariner.target.remove(), this.createRowGrips());
|
|
7647
7647
|
}, P.prototype.createRowGrips = function() {
|
|
7648
|
-
var o = this, m = this, a = [],
|
|
7648
|
+
var o = this, m = this, a = [], c = x('<div class="rowgrips"/>');
|
|
7649
7649
|
this.rows.forEach(function(h, M) {
|
|
7650
7650
|
var u = x('<div class="rowgrip"><div class="gripResizer"></div></div>');
|
|
7651
|
-
|
|
7651
|
+
c.append(u);
|
|
7652
7652
|
var d = new r(u);
|
|
7653
7653
|
a.push(d), M > 0 && M < o.rows.length && x(u).hidraggable({
|
|
7654
7654
|
axis: "v",
|
|
@@ -7664,7 +7664,7 @@ var At = function(q) {
|
|
|
7664
7664
|
m.rows[M].columns[0].getTarget().css("height", J + "pt"), m.syncRowGrips(), d.target.removeClass("rowgripDraging");
|
|
7665
7665
|
}
|
|
7666
7666
|
});
|
|
7667
|
-
}), this.target.before(
|
|
7667
|
+
}), this.target.before(c), this.rgripContariner = new N(c, a), this.syncRowGrips();
|
|
7668
7668
|
}, P.prototype.syncGrips = function(o, m) {
|
|
7669
7669
|
var a = o.getTarget();
|
|
7670
7670
|
m.cell = o, m.target.css({
|
|
@@ -7674,9 +7674,9 @@ var At = function(q) {
|
|
|
7674
7674
|
}, P.prototype.syncRowGrips = function() {
|
|
7675
7675
|
var o = this;
|
|
7676
7676
|
this.rgripContariner.target.height(this.target.height()), this.rows.forEach(function(m, a) {
|
|
7677
|
-
var
|
|
7677
|
+
var c = m.columns[0].getTarget();
|
|
7678
7678
|
o.rgripContariner.grips[a].target.css({
|
|
7679
|
-
top:
|
|
7679
|
+
top: c.offset().top - o.target.offset().top + c.outerHeight(!1),
|
|
7680
7680
|
width: 30
|
|
7681
7681
|
});
|
|
7682
7682
|
});
|
|
@@ -7696,10 +7696,10 @@ var At = function(q) {
|
|
|
7696
7696
|
});
|
|
7697
7697
|
var v = function() {
|
|
7698
7698
|
function P(o) {
|
|
7699
|
-
this.id = C.a.createId(), this.optionsCoat = new E(o), this.handle = o.handle, this.target = o.table, this.initRows(o.rows), this.init(o), this.tableCellSelector = new
|
|
7699
|
+
this.id = C.a.createId(), this.optionsCoat = new E(o), this.handle = o.handle, this.target = o.table, this.initRows(o.rows), this.init(o), this.tableCellSelector = new I.a(this.rows, this.target), this.resizer = this.optionsCoat.options.columnResizable ? new H(this) : new j(), this.resizer.init();
|
|
7700
7700
|
}
|
|
7701
7701
|
return P.prototype.insertRow = function(o, m, a) {
|
|
7702
|
-
var
|
|
7702
|
+
var c = m || this.tableCellSelector.getSingleSelect(), h = c.cell, M = this.rows[c.rowIndex], u = c.rowIndex, d = this.getCellGrid(), A = new w.a();
|
|
7703
7703
|
if (A.init(this.optionsCoat, void 0, M.isHead), a && A.getTarget().addClass(a), o == "above")
|
|
7704
7704
|
d[u].forEach(function(L) {
|
|
7705
7705
|
var J = L.link ? L.link : L.cell, Y = J.width / J.colspan;
|
|
@@ -7730,7 +7730,7 @@ var At = function(q) {
|
|
|
7730
7730
|
}
|
|
7731
7731
|
}), this.rows.splice(Z + 1, 0, A), this.rows[Z].getTarget().after(A.getTarget()), b.a.event.trigger("newRow" + this.id, A);
|
|
7732
7732
|
}
|
|
7733
|
-
}, P.prototype.insertColumn = function(o, m, a,
|
|
7733
|
+
}, P.prototype.insertColumn = function(o, m, a, c) {
|
|
7734
7734
|
var h = this, M = this.rows.concat(this.trRows), u = m || this.tableCellSelector.getSingleSelect(), d = u.cell, A = u.rowIndex, Z = this.getCellGrid(M), L = Z[A].filter(function(R) {
|
|
7735
7735
|
return R.cell && R.cell.id == d.id || R.link && R.link.id == d.id;
|
|
7736
7736
|
});
|
|
@@ -7742,7 +7742,7 @@ var At = function(q) {
|
|
|
7742
7742
|
});
|
|
7743
7743
|
if ($.rowLevel == 0) {
|
|
7744
7744
|
var et = M[V], ot = M[V].createTableCell();
|
|
7745
|
-
a && ot.getTarget().addClass(a),
|
|
7745
|
+
a && ot.getTarget().addClass(a), c != null && (ot.width = c), z.length ? et.insertToTargetCellLeft(z[0].cell, ot) : et.insertCellToLast(ot), b.a.event.trigger("newCell" + h.id, ot);
|
|
7746
7746
|
} else if ($.linkType == "row") {
|
|
7747
7747
|
var pt = $.link.getTarget();
|
|
7748
7748
|
$.link.colspan += 1, pt.attr("colspan", $.link.colspan);
|
|
@@ -7756,7 +7756,7 @@ var At = function(q) {
|
|
|
7756
7756
|
});
|
|
7757
7757
|
if ($.rightMost) {
|
|
7758
7758
|
var et = M[V], ot = et.createTableCell();
|
|
7759
|
-
a && ot.getTarget().addClass(a),
|
|
7759
|
+
a && ot.getTarget().addClass(a), c != null && (ot.width = c), z.length ? et.insertToTargetCellRight(z[z.length - 1].cell, ot) : et.insertCellToFirst(ot), b.a.event.trigger("newCell" + h.id, ot);
|
|
7760
7760
|
} else {
|
|
7761
7761
|
var pt = $.link || $.cell;
|
|
7762
7762
|
if ($.linkType == "row") {
|
|
@@ -7768,14 +7768,14 @@ var At = function(q) {
|
|
|
7768
7768
|
});
|
|
7769
7769
|
}
|
|
7770
7770
|
}, P.prototype.deleteRow = function() {
|
|
7771
|
-
var o = this, m = this.tableCellSelector.getSingleSelect(), a = (m.cell, this.rows[m.rowIndex], m.rowIndex),
|
|
7772
|
-
|
|
7771
|
+
var o = this, m = this.tableCellSelector.getSingleSelect(), a = (m.cell, this.rows[m.rowIndex], m.rowIndex), c = this.getCellGrid(), h = this.rows[a];
|
|
7772
|
+
c[a].forEach(function(M, u) {
|
|
7773
7773
|
if (M.cell)
|
|
7774
7774
|
if (M.cell.rowspan == 1)
|
|
7775
7775
|
h.removeCell(M.cell);
|
|
7776
7776
|
else {
|
|
7777
7777
|
h.removeCell(M.cell);
|
|
7778
|
-
var d =
|
|
7778
|
+
var d = c[a + 1].filter(function(J, Y) {
|
|
7779
7779
|
return J.cell && Y > u;
|
|
7780
7780
|
}), A = o.rows[a + 1], Z = A.createTableCell(M.cell.rowspan - 1, M.cell.colspan);
|
|
7781
7781
|
d.length ? A.insertToTargetCellLeft(d[0].cell, Z) : A.insertCellToLast(Z);
|
|
@@ -7786,7 +7786,7 @@ var At = function(q) {
|
|
|
7786
7786
|
}
|
|
7787
7787
|
}), h.getTarget().remove(), this.rows.splice(a, 1);
|
|
7788
7788
|
}, P.prototype.deleteColums = function() {
|
|
7789
|
-
var o = this.rows.concat(this.trRows), m = this.tableCellSelector.getSingleSelect(), a = m.cell,
|
|
7789
|
+
var o = this.rows.concat(this.trRows), m = this.tableCellSelector.getSingleSelect(), a = m.cell, c = m.rowIndex, h = this.getCellGrid(o), M = h[c].filter(function(u) {
|
|
7790
7790
|
return u.cell && u.cell.id == a.id || u.link && u.link.id == a.id;
|
|
7791
7791
|
})[0].indexInTableGridRow;
|
|
7792
7792
|
h.forEach(function(u, d) {
|
|
@@ -7797,8 +7797,8 @@ var At = function(q) {
|
|
|
7797
7797
|
var o = this, m = this.tableCellSelector.getSelectedCells();
|
|
7798
7798
|
if (m.length != 0) {
|
|
7799
7799
|
var a = m[0][0].cell;
|
|
7800
|
-
m.forEach(function(
|
|
7801
|
-
|
|
7800
|
+
m.forEach(function(c, h) {
|
|
7801
|
+
c.forEach(function(M, u) {
|
|
7802
7802
|
h == 0 ? u != 0 && (a.colspan += M.cell.colspan, o.rows[M.rowIndex].removeCell(M.cell)) : o.rows[M.rowIndex].removeCell(M.cell), u == 0 && m[0][0].rowIndex + a.rowspan - 1 < M.rowIndex && (a.rowspan += M.cell.rowspan);
|
|
7803
7803
|
});
|
|
7804
7804
|
}), a.getTarget().attr("colspan", a.colspan), a.getTarget().attr("rowspan", a.rowspan), this.tableCellSelector.setSingleSelect(m[0][0]);
|
|
@@ -7806,9 +7806,9 @@ var At = function(q) {
|
|
|
7806
7806
|
}, P.prototype.splitCell = function() {
|
|
7807
7807
|
var o = this.tableCellSelector.getSingleSelect(), m = this.getCellGrid(), a = s.getIndex(m[o.rowIndex], o.cell.id);
|
|
7808
7808
|
if (o) {
|
|
7809
|
-
for (var
|
|
7810
|
-
for (var h = this.rows[
|
|
7811
|
-
|
|
7809
|
+
for (var c = o.rowIndex; c < o.rowIndex + o.cell.rowspan; c++)
|
|
7810
|
+
for (var h = this.rows[c], M = c == o.rowIndex ? o.cell : s.getLeftTableCell(m[c], a), u = 0; u < o.cell.colspan; u++)
|
|
7811
|
+
c == o.rowIndex && u == 0 || (M ? h.insertToTargetCellRight(M, h.createTableCell()) : h.insertCellToFirst(h.createTableCell()));
|
|
7812
7812
|
o.cell.rowspan = 1, o.cell.colspan = 1, o.cell.getTarget().attr("colspan", o.cell.colspan), o.cell.getTarget().attr("rowspan", o.cell.rowspan);
|
|
7813
7813
|
}
|
|
7814
7814
|
}, P.prototype.init = function(o) {
|
|
@@ -7827,33 +7827,33 @@ var At = function(q) {
|
|
|
7827
7827
|
}, P.prototype.initRows = function(o) {
|
|
7828
7828
|
var m = this;
|
|
7829
7829
|
if (this.trRows = [], o) {
|
|
7830
|
-
this.rows = o, o.forEach(function(
|
|
7831
|
-
|
|
7830
|
+
this.rows = o, o.forEach(function(c, h) {
|
|
7831
|
+
c.init(m.optionsCoat, m.target.find("tr:eq(" + h + ")"), !0);
|
|
7832
7832
|
});
|
|
7833
7833
|
var a = this.optionsCoat.options.trs;
|
|
7834
|
-
a && this.initRowsByTrs(a).forEach(function(
|
|
7835
|
-
m.trRows.push(
|
|
7834
|
+
a && this.initRowsByTrs(a).forEach(function(c) {
|
|
7835
|
+
m.trRows.push(c);
|
|
7836
7836
|
});
|
|
7837
7837
|
} else
|
|
7838
7838
|
this.rows = this.initRowsByTrs(this.target.find("tr"));
|
|
7839
7839
|
}, P.prototype.initRowsByTrs = function(o) {
|
|
7840
7840
|
var m = this;
|
|
7841
|
-
return o.map(function(a,
|
|
7841
|
+
return o.map(function(a, c) {
|
|
7842
7842
|
var h = new w.a();
|
|
7843
|
-
return h.init(m.optionsCoat, x(
|
|
7843
|
+
return h.init(m.optionsCoat, x(c)), h;
|
|
7844
7844
|
}).get();
|
|
7845
7845
|
}, P.prototype.enableEidt = function() {
|
|
7846
7846
|
this.optionsCoat.enableEidt();
|
|
7847
7847
|
}, P.prototype.disableEdit = function() {
|
|
7848
7848
|
this.optionsCoat.disableEdit();
|
|
7849
7849
|
}, P.prototype.getCellGrid = function(o) {
|
|
7850
|
-
var m = o || this.rows, a = this.getColumnStep(),
|
|
7850
|
+
var m = o || this.rows, a = this.getColumnStep(), c = [];
|
|
7851
7851
|
return m.forEach(function(h, M) {
|
|
7852
7852
|
h.columns.forEach(function(u, d) {
|
|
7853
7853
|
for (var A = 0; A < u.colspan; A++)
|
|
7854
7854
|
for (var Z = 0, L = !1; Z < a && !L; ) {
|
|
7855
|
-
if (
|
|
7856
|
-
|
|
7855
|
+
if (c[M] = c[M] || [], !c[M][Z]) {
|
|
7856
|
+
c[M][Z] = new l({
|
|
7857
7857
|
cell: A == 0 ? u : void 0,
|
|
7858
7858
|
link: A != 0 ? u : void 0,
|
|
7859
7859
|
linkType: A > 0 ? "row" : void 0,
|
|
@@ -7865,7 +7865,7 @@ var At = function(q) {
|
|
|
7865
7865
|
indexInTableGridColumn: M
|
|
7866
7866
|
});
|
|
7867
7867
|
for (var J = M + 1, Y = 1; Y < u.rowspan; Y++)
|
|
7868
|
-
|
|
7868
|
+
c[J] = c[J] || [], c[J][Z] = new l({
|
|
7869
7869
|
cell: void 0,
|
|
7870
7870
|
link: u,
|
|
7871
7871
|
linkType: A > 0 ? "rowColumn" : "column",
|
|
@@ -7881,7 +7881,7 @@ var At = function(q) {
|
|
|
7881
7881
|
Z++;
|
|
7882
7882
|
}
|
|
7883
7883
|
});
|
|
7884
|
-
}),
|
|
7884
|
+
}), c;
|
|
7885
7885
|
}, P.prototype.setAlign = function(o) {
|
|
7886
7886
|
var m = this.tableCellSelector.getSingleSelect();
|
|
7887
7887
|
m && m.cell.setAlign(o);
|
|
@@ -8072,8 +8072,8 @@ var At = function(q) {
|
|
|
8072
8072
|
g.d(F, "a", function() {
|
|
8073
8073
|
return w;
|
|
8074
8074
|
});
|
|
8075
|
-
var
|
|
8076
|
-
return (
|
|
8075
|
+
var I, s = (I = function(N, r) {
|
|
8076
|
+
return (I = Object.setPrototypeOf || Dt(
|
|
8077
8077
|
{
|
|
8078
8078
|
__proto__: []
|
|
8079
8079
|
},
|
|
@@ -8088,7 +8088,7 @@ var At = function(q) {
|
|
|
8088
8088
|
function r() {
|
|
8089
8089
|
this.constructor = C;
|
|
8090
8090
|
}
|
|
8091
|
-
|
|
8091
|
+
I(C, N), C.prototype = N === null ? Object.create(N) : (r.prototype = N.prototype, new r());
|
|
8092
8092
|
}), w = function(C) {
|
|
8093
8093
|
function N(r, T) {
|
|
8094
8094
|
var S = this;
|
|
@@ -8180,7 +8180,7 @@ var At = function(q) {
|
|
|
8180
8180
|
function l(r, T, S, D, H, j) {
|
|
8181
8181
|
Math.abs(r[S] - T[D]) <= HIPRINT_CONFIG.adsorbLineMin ? r.v.length ? r.v.css("left", r[S] + "pt") : (r.v = x("<div class='verLine id-" + r.id + "'></div>"), r.v.css("height", H + "pt"), r.v.css("left", r[S] + "pt"), j.append(r.v)) : r.v && r.v.remove();
|
|
8182
8182
|
}
|
|
8183
|
-
function
|
|
8183
|
+
function I(r) {
|
|
8184
8184
|
r && r.v && r.v.remove(), x(".verLine").remove();
|
|
8185
8185
|
}
|
|
8186
8186
|
function s(r, T, S, D, H, j) {
|
|
@@ -8212,7 +8212,7 @@ var At = function(q) {
|
|
|
8212
8212
|
};
|
|
8213
8213
|
}).sort(($, z) => $.distance - z.distance).slice(0, 1), A = T.options.designTarget.designPaper, Z = A.target.find(".hiprint-printPaper-content"), L = A.width, J = A.height, Y = HIPRINT_CONFIG.showAdsorbLine, R = HIPRINT_CONFIG.adsorbMin, V = HIPRINT_CONFIG.adsorbLineMin;
|
|
8214
8214
|
d.forEach(($, z) => {
|
|
8215
|
-
Math.abs(d[z].left - u.left) <= R ? (u.left = d[z].left,
|
|
8215
|
+
Math.abs(d[z].left - u.left) <= R ? (u.left = d[z].left, I(d[z])) : Math.abs(d[z].vCenter - u.left) <= R ? (u.left = d[z].vCenter, I(d[z])) : Math.abs(d[z].right - u.left) <= R && (u.left = d[z].right, I(d[z])), Math.abs(d[z].left - u.vCenter) <= R ? (u.left = d[z].left - u.width / 2, I(d[z])) : Math.abs(d[z].vCenter - u.vCenter) <= R ? (u.left = d[z].vCenter - u.width / 2, I(d[z])) : Math.abs(d[z].right - u.vCenter) <= R && (u.left = d[z].right - u.width / 2, I(d[z])), Math.abs(d[z].left - u.right) <= R ? (u.left = d[z].left - u.width, I(d[z])) : Math.abs(d[z].vCenter - u.right) <= R ? (u.left = d[z].vCenter - u.width, I(d[z])) : Math.abs(d[z].right - u.right) <= R && (u.left = d[z].right - u.width, I(d[z])), Math.abs(d[z].top - u.top) <= R ? (u.top = d[z].top, w(d[z])) : Math.abs(d[z].hCenter - u.top) <= R ? (u.top = d[z].hCenter, w(d[z])) : Math.abs(d[z].bottom - u.top) <= R && (u.top = d[z].bottom, w(d[z])), Math.abs(d[z].top - u.hCenter) <= R ? (u.top = d[z].top - u.height / 2, w(d[z])) : Math.abs(d[z].hCenter - u.hCenter) <= R ? (u.top = d[z].hCenter - u.height / 2, w(d[z])) : Math.abs(d[z].bottom - u.hCenter) <= R && (u.top = d[z].bottom - u.height / 2, w(d[z])), Math.abs(d[z].top - u.bottom) <= R ? (u.top = d[z].top - u.height, w(d[z])) : Math.abs(d[z].hCenter - u.bottom) <= R ? (u.top = d[z].hCenter - u.height, w(d[z])) : Math.abs(d[z].bottom - u.bottom) <= R && (u.top = d[z].bottom - u.height, w(d[z])), Y && (Math.abs(d[z].left - u.left) > R && Math.abs(d[z].left - u.left) <= V ? l(d[z], u, "left", "left", J, Z) : Math.abs(d[z].vCenter - u.left) > R && Math.abs(d[z].vCenter - u.left) <= V ? l(d[z], u, "vCenter", "left", J, Z) : Math.abs(d[z].right - u.left) > R && Math.abs(d[z].right - u.left) <= V ? l(d[z], u, "right", "left", J, Z) : Math.abs(d[z].left - u.vCenter) > R && Math.abs(d[z].left - u.vCenter) <= V ? l(d[z], u, "left", "vCenter", J, Z) : Math.abs(d[z].vCenter - u.vCenter) > R && Math.abs(d[z].vCenter - u.vCenter) <= V ? l(d[z], u, "vCenter", "vCenter", J, Z) : Math.abs(d[z].right - u.vCenter) > R && Math.abs(d[z].right - u.vCenter) <= V ? l(d[z], u, "right", "vCenter", J, Z) : Math.abs(d[z].left - u.right) > R && Math.abs(d[z].left - u.right) <= V ? l(d[z], u, "left", "right", J, Z) : Math.abs(d[z].vCenter - u.right) > R && Math.abs(d[z].vCenter - u.right) <= V ? l(d[z], u, "vCenter", "right", J, Z) : Math.abs(d[z].right - u.right) > R && Math.abs(d[z].right - u.right) <= V ? l(d[z], u, "right", "right", J, Z) : Math.abs(d[z].top - u.top) > R && Math.abs(d[z].top - u.top) <= V ? s(d[z], u, "top", "top", L, Z) : Math.abs(d[z].hCenter - u.top) > R && Math.abs(d[z].hCenter - u.top) <= V ? s(d[z], u, "hCenter", "top", L, Z) : Math.abs(d[z].bottom - u.top) > R && Math.abs(d[z].bottom - u.top) <= V ? s(d[z], u, "bottom", "top", L, Z) : Math.abs(d[z].top - u.hCenter) > R && Math.abs(d[z].top - u.hCenter) <= V ? s(d[z], u, "top", "hCenter", L, Z) : Math.abs(d[z].hCenter - u.hCenter) > R && Math.abs(d[z].hCenter - u.hCenter) <= V ? s(d[z], u, "hCenter", "hCenter", L, Z) : Math.abs(d[z].bottom - u.hCenter) > R && Math.abs(d[z].bottom - u.hCenter) <= V ? s(d[z], u, "bottom", "hCenter", L, Z) : Math.abs(d[z].top - u.bottom) > R && Math.abs(d[z].top - u.bottom) <= V ? s(d[z], u, "top", "bottom", L, Z) : Math.abs(d[z].hCenter - u.bottom) > R && Math.abs(d[z].hCenter - u.bottom) <= V ? s(d[z], u, "hCenter", "bottom", L, Z) : Math.abs(d[z].bottom - u.bottom) > R && Math.abs(d[z].bottom - u.bottom) <= V ? s(d[z], u, "bottom", "bottom", L, Z) : (I(d[z]), w(d[z])));
|
|
8216
8216
|
});
|
|
8217
8217
|
})(), r.data.left = window.hinnn.pt.toPx(u.left), r.data.top = window.hinnn.pt.toPx(u.top);
|
|
8218
8218
|
}
|
|
@@ -8224,12 +8224,12 @@ var At = function(q) {
|
|
|
8224
8224
|
S.left < 0 - o ? S.left = 0 - o : S.left >= H - v + o && (S.left = H - v + o), S.top < 0 - m ? S.top = 0 - m : S.top >= j - P + m && (S.top = j - P + m), r.data = S;
|
|
8225
8225
|
}
|
|
8226
8226
|
T.options.onDrag.call(r.data.target, r, g.fn.dragLengthCNum(r.data.left, T.options), g.fn.dragLengthCNum(r.data.top, T.options)) != 0 && E(r);
|
|
8227
|
-
var
|
|
8227
|
+
var c = r.data.target;
|
|
8228
8228
|
return T.hidroppables.each(function() {
|
|
8229
8229
|
var h = g(this);
|
|
8230
8230
|
if (!h.hidroppable("options").disabled) {
|
|
8231
8231
|
var M = h.offset();
|
|
8232
|
-
r.pageX > M.left && r.pageX < M.left + h.outerWidth() && r.pageY > M.top && r.pageY < M.top + h.outerHeight() ? (this.entered || (g(this).trigger("_dragenter", [
|
|
8232
|
+
r.pageX > M.left && r.pageX < M.left + h.outerWidth() && r.pageY > M.top && r.pageY < M.top + h.outerHeight() ? (this.entered || (g(this).trigger("_dragenter", [c]), this.entered = !0), g(this).trigger("_dragover", [c])) : this.entered && (g(this).trigger("_dragleave", [c]), this.entered = !1);
|
|
8233
8233
|
}
|
|
8234
8234
|
}), !1;
|
|
8235
8235
|
}
|
|
@@ -8288,12 +8288,12 @@ var At = function(q) {
|
|
|
8288
8288
|
D ? (D.handle.unbind(".hidraggable"), S = g.extend(D.options, r)) : S = g.extend({}, g.fn.hidraggable.defaults, g.fn.hidraggable.parseOptions(this), r || {});
|
|
8289
8289
|
var H = S.handle ? typeof S.handle == "string" ? g(S.handle, this) : S.handle : g(this);
|
|
8290
8290
|
function j(v) {
|
|
8291
|
-
var P = g.data(v.data.target, "hidraggable"), o = P.handle, m = g(o).offset(), a = g(o)[0].style.transform && parseInt(g(o)[0].style.transform.slice(7, -1)),
|
|
8291
|
+
var P = g.data(v.data.target, "hidraggable"), o = P.handle, m = g(o).offset(), a = g(o)[0].style.transform && parseInt(g(o)[0].style.transform.slice(7, -1)), c = P.options.getScale(), h = g(o).outerWidth(), M = g(o).outerHeight();
|
|
8292
8292
|
if (a) {
|
|
8293
8293
|
var u = a * Math.PI / 180, d = g(o).outerWidth(), A = g(o).outerHeight(), Z = Math.sin(u), L = Math.cos(u);
|
|
8294
8294
|
h = Math.abs(d * L) + Math.abs(A * Z), M = Math.abs(d * Z) + Math.abs(A * L);
|
|
8295
8295
|
}
|
|
8296
|
-
|
|
8296
|
+
c && (h *= c, M *= c);
|
|
8297
8297
|
var J = v.pageY - m.top, Y = m.left + h - v.pageX, R = m.top + M - v.pageY, V = v.pageX - m.left;
|
|
8298
8298
|
return Math.min(J, Y, R, V) > P.options.edge;
|
|
8299
8299
|
}
|
|
@@ -8342,8 +8342,8 @@ var At = function(q) {
|
|
|
8342
8342
|
}, a = g.data(v.data.target, "hidraggable");
|
|
8343
8343
|
if (a.options.draggable === !1 || v.target.className == "r resizebtn")
|
|
8344
8344
|
return;
|
|
8345
|
-
var
|
|
8346
|
-
|
|
8345
|
+
var c = a.options.getScale();
|
|
8346
|
+
c && (m.left /= c, m.top /= c, m.startLeft /= c, m.startTop /= c);
|
|
8347
8347
|
var h = m.target.style.transform && parseInt(m.target.style.transform.slice(7, -1));
|
|
8348
8348
|
if (h) {
|
|
8349
8349
|
var M = h * Math.PI / 180, u = g(v.data.target).outerWidth(), d = g(v.data.target).outerHeight(), A = Math.sin(M), Z = Math.cos(M), L = Math.abs(u * Z) + Math.abs(d * A), J = Math.abs(u * A) + Math.abs(d * Z), Y = (L - u) / 2, R = (J - d) / 2;
|
|
@@ -8427,14 +8427,14 @@ var At = function(q) {
|
|
|
8427
8427
|
g.fn.hidroppable = function(W, E) {
|
|
8428
8428
|
return typeof W == "string" ? g.fn.hidroppable.methods[W](this, E) : (W = W || {}, this.each(function() {
|
|
8429
8429
|
var b, l = g.data(this, "hidroppable");
|
|
8430
|
-
l ? g.extend(l.options, W) : (g(b = this).addClass("hidroppable"), g(b).bind("_dragenter", function(
|
|
8431
|
-
g.data(b, "hidroppable").options.onDragEnter.apply(b, [
|
|
8432
|
-
}), g(b).bind("_dragleave", function(
|
|
8433
|
-
g.data(b, "hidroppable").options.onDragLeave.apply(b, [
|
|
8434
|
-
}), g(b).bind("_dragover", function(
|
|
8435
|
-
g.data(b, "hidroppable").options.onDragOver.apply(b, [
|
|
8436
|
-
}), g(b).bind("_drop", function(
|
|
8437
|
-
g.data(b, "hidroppable").options.onDrop.apply(b, [
|
|
8430
|
+
l ? g.extend(l.options, W) : (g(b = this).addClass("hidroppable"), g(b).bind("_dragenter", function(I, s) {
|
|
8431
|
+
g.data(b, "hidroppable").options.onDragEnter.apply(b, [I, s]);
|
|
8432
|
+
}), g(b).bind("_dragleave", function(I, s) {
|
|
8433
|
+
g.data(b, "hidroppable").options.onDragLeave.apply(b, [I, s]);
|
|
8434
|
+
}), g(b).bind("_dragover", function(I, s) {
|
|
8435
|
+
g.data(b, "hidroppable").options.onDragOver.apply(b, [I, s]);
|
|
8436
|
+
}), g(b).bind("_drop", function(I, s) {
|
|
8437
|
+
g.data(b, "hidroppable").options.onDrop.apply(b, [I, s]);
|
|
8438
8438
|
}), g.data(this, "hidroppable", {
|
|
8439
8439
|
options: g.extend({}, g.fn.hidroppable.defaults, g.fn.hidroppable.parseOptions(this), W)
|
|
8440
8440
|
}));
|
|
@@ -8480,8 +8480,8 @@ var At = function(q) {
|
|
|
8480
8480
|
var g;
|
|
8481
8481
|
(g = jQuery).hiprintparser = {
|
|
8482
8482
|
parseOptions: function(E, b) {
|
|
8483
|
-
var l = g(E),
|
|
8484
|
-
if (s && (s.substring(0, 1) != "{" && (s = "{" + s + "}"),
|
|
8483
|
+
var l = g(E), I = {}, s = g.trim(l.attr("data-options"));
|
|
8484
|
+
if (s && (s.substring(0, 1) != "{" && (s = "{" + s + "}"), I = new Function("return " + s)()), b) {
|
|
8485
8485
|
for (var w = {}, C = 0; C < b.length; C++) {
|
|
8486
8486
|
var N = b[C];
|
|
8487
8487
|
if (typeof N == "string")
|
|
@@ -8492,9 +8492,9 @@ var At = function(q) {
|
|
|
8492
8492
|
T == "boolean" ? w[r] = l.attr(r) ? l.attr(r) == "true" : void 0 : T == "number" && (w[r] = l.attr(r) == "0" ? 0 : parseFloat(l.attr(r)) || void 0);
|
|
8493
8493
|
}
|
|
8494
8494
|
}
|
|
8495
|
-
g.extend(
|
|
8495
|
+
g.extend(I, w);
|
|
8496
8496
|
}
|
|
8497
|
-
return
|
|
8497
|
+
return I;
|
|
8498
8498
|
}
|
|
8499
8499
|
}, g.fn.dragLengthC = function(W, E) {
|
|
8500
8500
|
return E.moveUnit == "pt" ? g.fn.dragLengthCNum(W, E) + "pt" : g.fn.dragLengthCNum(W, E);
|
|
@@ -8518,24 +8518,24 @@ var At = function(q) {
|
|
|
8518
8518
|
return this.numHandler(l) + "pt";
|
|
8519
8519
|
},
|
|
8520
8520
|
numHandler: function(l) {
|
|
8521
|
-
var
|
|
8522
|
-
return this.options.minResize && (
|
|
8521
|
+
var I = 1.5, s = 0.75 * l;
|
|
8522
|
+
return this.options.minResize && (I = this.options.minResize), Math.round(s / I) * I;
|
|
8523
8523
|
},
|
|
8524
8524
|
init: function(l) {
|
|
8525
|
-
var
|
|
8525
|
+
var I = this;
|
|
8526
8526
|
if (l.className.includes("hiprint-printElement")) {
|
|
8527
8527
|
this.initResizeBox(l);
|
|
8528
8528
|
var s = new ResizeObserver((w, C) => {
|
|
8529
|
-
|
|
8529
|
+
I.refreshSizeBox(g(l));
|
|
8530
8530
|
});
|
|
8531
8531
|
s.observe(l);
|
|
8532
8532
|
}
|
|
8533
8533
|
},
|
|
8534
8534
|
initResizeBox: function(l) {
|
|
8535
|
-
var
|
|
8535
|
+
var I = this;
|
|
8536
8536
|
g(l).each(function() {
|
|
8537
8537
|
var s;
|
|
8538
|
-
W.maxPanelIndex += 1,
|
|
8538
|
+
W.maxPanelIndex += 1, I.options.noContainer ? s = g(l) : s = g("<div panelIndex=" + W.maxPanelIndex + ' class="resize-panel"></div>'), I.appendHandler(s, g(this));
|
|
8539
8539
|
var w = {
|
|
8540
8540
|
name: "n",
|
|
8541
8541
|
target: g('<div class="resizebtn n"/>')
|
|
@@ -8567,26 +8567,26 @@ var At = function(q) {
|
|
|
8567
8567
|
name: "why",
|
|
8568
8568
|
target: g('<div class="resizebtn why"/>')
|
|
8569
8569
|
}, P = g('<div class="size-box"></div>'), o = g('<div class="del-btn">\u2715</div>'), m = function() {
|
|
8570
|
-
var h = [v.target], M =
|
|
8570
|
+
var h = [v.target], M = I.options.showPoints;
|
|
8571
8571
|
return g.each([j, w, C, N, r, T, S, D, H], function(u, d) {
|
|
8572
8572
|
g.inArray(d.name, M) > -1 && h.push(d.target);
|
|
8573
8573
|
}), h;
|
|
8574
8574
|
};
|
|
8575
|
-
|
|
8576
|
-
var
|
|
8577
|
-
l.dispatchEvent(
|
|
8578
|
-
})),
|
|
8575
|
+
I.refreshSizeBox(void 0, P, s), I.options.draggable != !1 && (s.append(o), s.on("mousedown", ".del-btn", () => {
|
|
8576
|
+
var c = new KeyboardEvent("keydown", { bubbles: !0, keyCode: 46 });
|
|
8577
|
+
l.dispatchEvent(c);
|
|
8578
|
+
})), I.appendHandler(m(), s), I.bindResizeEvent(s, g(this));
|
|
8579
8579
|
var a = g(this);
|
|
8580
8580
|
g(s).on("mousedown", ".resizebtn", function() {
|
|
8581
8581
|
a.addClass("resizeing");
|
|
8582
8582
|
}), g(".easyui-droppable").on("mouseup", function() {
|
|
8583
8583
|
a.removeClass("resizeing");
|
|
8584
|
-
}),
|
|
8585
|
-
}),
|
|
8584
|
+
}), I.bindTrigger(g(this));
|
|
8585
|
+
}), I.bindHidePanel();
|
|
8586
8586
|
},
|
|
8587
8587
|
addHandlerCss: function(l) {
|
|
8588
|
-
for (var
|
|
8589
|
-
l[
|
|
8588
|
+
for (var I = 0; I < l.length; I++)
|
|
8589
|
+
l[I].css({
|
|
8590
8590
|
position: "absolute",
|
|
8591
8591
|
width: "8px",
|
|
8592
8592
|
height: "8px",
|
|
@@ -8594,15 +8594,15 @@ var At = function(q) {
|
|
|
8594
8594
|
"border-radius": "50%"
|
|
8595
8595
|
});
|
|
8596
8596
|
},
|
|
8597
|
-
appendHandler: function(l,
|
|
8598
|
-
|
|
8597
|
+
appendHandler: function(l, I) {
|
|
8598
|
+
I.find(".resize-panel").remove();
|
|
8599
8599
|
for (var s = 0; s < l.length; s++)
|
|
8600
|
-
|
|
8600
|
+
I.append(l[s]);
|
|
8601
8601
|
},
|
|
8602
|
-
refreshSizeBox: function(l,
|
|
8602
|
+
refreshSizeBox: function(l, I, s) {
|
|
8603
8603
|
if (!!this.options.showSizeBox) {
|
|
8604
|
-
if (
|
|
8605
|
-
s.append(
|
|
8604
|
+
if (I)
|
|
8605
|
+
s.append(I);
|
|
8606
8606
|
else if (l && l.length) {
|
|
8607
8607
|
var w = l.height(), C = l[0].clientHeight, N = l.width(), r = l[0].clientWidth;
|
|
8608
8608
|
w <= 40 ? (g.each([".ne", ".nw", ".se", ".sw"], function(D, H) {
|
|
@@ -8639,15 +8639,15 @@ var At = function(q) {
|
|
|
8639
8639
|
S && (S.text(T.width + " x " + T.height), S.css("top", -(S.outerHeight() || 20)));
|
|
8640
8640
|
}
|
|
8641
8641
|
},
|
|
8642
|
-
triggerResize: function(l,
|
|
8643
|
-
|
|
8642
|
+
triggerResize: function(l, I) {
|
|
8643
|
+
I.ctrlKey || I.metaKey || (l.siblings().children("div[panelindex]").removeClass("selected"), l.siblings().children("div[panelindex]").css({
|
|
8644
8644
|
display: "none"
|
|
8645
8645
|
})), l.children("div[panelindex]").addClass("selected"), l.children("div[panelindex]").css({
|
|
8646
8646
|
display: "block"
|
|
8647
8647
|
}), this.refreshSizeBox(l);
|
|
8648
8648
|
},
|
|
8649
|
-
bindResizeEvent: function(l,
|
|
8650
|
-
var s = this, w = 0, C = 0, N = l.width(), r = l.height(), T = l.offset().left, S = l.offset().top, D = s.options.noContainer ? g(
|
|
8649
|
+
bindResizeEvent: function(l, I) {
|
|
8650
|
+
var s = this, w = 0, C = 0, N = l.width(), r = l.height(), T = l.offset().left, S = l.offset().top, D = s.options.noContainer ? g(I) : l.parent(), H = !1;
|
|
8651
8651
|
l.on("mousedown", ".e", function(u) {
|
|
8652
8652
|
w = u.pageX, N = l.width(), H = !0, u.stopPropagation();
|
|
8653
8653
|
});
|
|
@@ -8675,9 +8675,9 @@ var At = function(q) {
|
|
|
8675
8675
|
l.on("mousedown", ".se", function(u) {
|
|
8676
8676
|
w = u.pageX, C = u.pageY, N = l.width(), r = l.height(), a = !0, u.stopPropagation();
|
|
8677
8677
|
});
|
|
8678
|
-
var
|
|
8678
|
+
var c = !1;
|
|
8679
8679
|
l.on("mousedown", ".sw", function(u) {
|
|
8680
|
-
w = u.pageX, C = u.pageY, N = l.width(), r = l.height(),
|
|
8680
|
+
w = u.pageX, C = u.pageY, N = l.width(), r = l.height(), c = !0, T = D.position().left, u.stopPropagation();
|
|
8681
8681
|
});
|
|
8682
8682
|
var h = !1;
|
|
8683
8683
|
l.on("mousedown", ".r", function(u) {
|
|
@@ -8779,7 +8779,7 @@ var At = function(q) {
|
|
|
8779
8779
|
height: s.numHandlerText($)
|
|
8780
8780
|
}), s.options.onResize(u, s.numHandler($), s.numHandler(V), void 0, void 0);
|
|
8781
8781
|
}
|
|
8782
|
-
else if (
|
|
8782
|
+
else if (c)
|
|
8783
8783
|
if (d = (u.pageX - w) / s.options.getScale(), A = (u.pageY - C) / s.options.getScale(), l.css({
|
|
8784
8784
|
width: "100%",
|
|
8785
8785
|
height: "100%"
|
|
@@ -8803,19 +8803,19 @@ var At = function(q) {
|
|
|
8803
8803
|
top: s.numHandlerText(s.options.noDrag ? void 0 : S + A)
|
|
8804
8804
|
}), s.options.onResize(u, void 0, void 0, s.options.noDrag ? void 0 : s.numHandler(S + A), s.options.noDrag ? void 0 : s.numHandler(T + d)));
|
|
8805
8805
|
}).on("mouseup", function(u) {
|
|
8806
|
-
(H || j || v || P || o || m ||
|
|
8806
|
+
(H || j || v || P || o || m || c || a || M || h) && s.options.onStopResize(h), H = !1, j = !1, v = !1, P = !1, o = !1, m = !1, c = !1, a = !1, M = !1, h = !1;
|
|
8807
8807
|
});
|
|
8808
8808
|
},
|
|
8809
8809
|
bindTrigger: function(l) {
|
|
8810
|
-
var
|
|
8810
|
+
var I = this;
|
|
8811
8811
|
l.on("click", function(s) {
|
|
8812
|
-
s.stopPropagation(),
|
|
8812
|
+
s.stopPropagation(), I.triggerResize(l, s), g(".mouseRect").remove();
|
|
8813
8813
|
});
|
|
8814
8814
|
},
|
|
8815
8815
|
bindHidePanel: function(l) {
|
|
8816
8816
|
if (W.maxPanelIndex < 2) {
|
|
8817
|
-
var
|
|
8818
|
-
g(
|
|
8817
|
+
var I = this.options.stage;
|
|
8818
|
+
g(I).bind("click", function(s) {
|
|
8819
8819
|
s.target.className && jt(s.target.className) == "string" && (s.target.className.includes("design") || s.target.className.includes("hiprint-printPaper-content") || s.target.className.includes("paperBox")) && (s.stopPropagation(), g("div[panelindex]").css({
|
|
8820
8820
|
display: "none"
|
|
8821
8821
|
}), g("div[panelindex]").removeClass("selected"));
|
|
@@ -8825,9 +8825,9 @@ var At = function(q) {
|
|
|
8825
8825
|
}, g.fn.extend({
|
|
8826
8826
|
hireizeable: function(l) {
|
|
8827
8827
|
return this.each(function() {
|
|
8828
|
-
var
|
|
8829
|
-
|
|
8830
|
-
options:
|
|
8828
|
+
var I, s = g.data(this, "hireizeable");
|
|
8829
|
+
I = s ? g.extend({}, s.options, l || {}) : g.extend({}, g.fn.hireizeable.defaults, l || {}), g.data(this, "hireizeable", {
|
|
8830
|
+
options: I
|
|
8831
8831
|
}), new E({
|
|
8832
8832
|
target: this,
|
|
8833
8833
|
onResize: function(C, N, r, T, S) {
|
|
@@ -8844,11 +8844,11 @@ var At = function(q) {
|
|
|
8844
8844
|
showSizeBox: !0,
|
|
8845
8845
|
showPoints: ["s", "e"],
|
|
8846
8846
|
noContainer: !1,
|
|
8847
|
-
onBeforeResize: function(l,
|
|
8847
|
+
onBeforeResize: function(l, I, s, w, C) {
|
|
8848
8848
|
},
|
|
8849
|
-
onResize: function(l,
|
|
8849
|
+
onResize: function(l, I, s, w, C) {
|
|
8850
8850
|
},
|
|
8851
|
-
onStopResize: function(l,
|
|
8851
|
+
onStopResize: function(l, I, s, w, C) {
|
|
8852
8852
|
},
|
|
8853
8853
|
noDrag: !1
|
|
8854
8854
|
};
|
|
@@ -8889,8 +8889,8 @@ var At = function(q) {
|
|
|
8889
8889
|
getAddress: function(b, ...l) {
|
|
8890
8890
|
try {
|
|
8891
8891
|
this.socket.emit("address", b, ...l);
|
|
8892
|
-
} catch (
|
|
8893
|
-
console.log("getAddress error:" + JSON.stringify(
|
|
8892
|
+
} catch (I) {
|
|
8893
|
+
console.log("getAddress error:" + JSON.stringify(I));
|
|
8894
8894
|
}
|
|
8895
8895
|
},
|
|
8896
8896
|
ippPrint: function(b) {
|
|
@@ -8911,16 +8911,16 @@ var At = function(q) {
|
|
|
8911
8911
|
window.utools ? this.host2 = host2 : this.host = E, this.stop(), this.start(b);
|
|
8912
8912
|
},
|
|
8913
8913
|
start: function(b) {
|
|
8914
|
-
var l = this,
|
|
8914
|
+
var l = this, I = this;
|
|
8915
8915
|
window.WebSocket ? this.socket || (this.socket = window.io(window.utools ? this.host2 : this.host, {
|
|
8916
8916
|
reconnectionAttempts: 5
|
|
8917
8917
|
}), this.socket.on("connect", function(s) {
|
|
8918
|
-
|
|
8918
|
+
I.opened = !0, console.log("Websocket opened."), l.socket.on("successs", function(w) {
|
|
8919
8919
|
hinnn.event.trigger("printSuccess_" + w.templateId, w);
|
|
8920
8920
|
}), l.socket.on("error", function(w) {
|
|
8921
8921
|
hinnn.event.trigger("printError_" + w.templateId, w);
|
|
8922
8922
|
}), l.socket.on("printerList", function(w) {
|
|
8923
|
-
|
|
8923
|
+
I.printerList = w, hinnn.event.trigger("printerList", w);
|
|
8924
8924
|
}), l.socket.on("address", function(w, C, N) {
|
|
8925
8925
|
hinnn.event.trigger("address_" + w, {
|
|
8926
8926
|
addr: C,
|
|
@@ -8938,9 +8938,9 @@ var At = function(q) {
|
|
|
8938
8938
|
err: w,
|
|
8939
8939
|
res: C
|
|
8940
8940
|
});
|
|
8941
|
-
}),
|
|
8941
|
+
}), I.state = g, b && b(!0, s);
|
|
8942
8942
|
}), this.socket.on("disconnect", function() {
|
|
8943
|
-
|
|
8943
|
+
I.opened = !1, b && b(!1);
|
|
8944
8944
|
})) : console.log("WebSocket start fail"), b && b(!1);
|
|
8945
8945
|
},
|
|
8946
8946
|
reconnect: function() {
|
|
@@ -8972,8 +8972,8 @@ var At = function(q) {
|
|
|
8972
8972
|
var E = [];
|
|
8973
8973
|
return E.toString = function() {
|
|
8974
8974
|
return this.map(function(b) {
|
|
8975
|
-
var l = function(
|
|
8976
|
-
var w =
|
|
8975
|
+
var l = function(I, s) {
|
|
8976
|
+
var w = I[1] || "", C = I[3];
|
|
8977
8977
|
if (!C)
|
|
8978
8978
|
return w;
|
|
8979
8979
|
if (s && typeof btoa == "function") {
|
|
@@ -8991,13 +8991,13 @@ var At = function(q) {
|
|
|
8991
8991
|
}).join("");
|
|
8992
8992
|
}, E.i = function(b, l) {
|
|
8993
8993
|
typeof b == "string" && (b = [[null, b, ""]]);
|
|
8994
|
-
for (var
|
|
8994
|
+
for (var I = {}, s = 0; s < this.length; s++) {
|
|
8995
8995
|
var w = this[s][0];
|
|
8996
|
-
w != null && (
|
|
8996
|
+
w != null && (I[w] = !0);
|
|
8997
8997
|
}
|
|
8998
8998
|
for (s = 0; s < b.length; s++) {
|
|
8999
8999
|
var C = b[s];
|
|
9000
|
-
C[0] != null &&
|
|
9000
|
+
C[0] != null && I[C[0]] || (l && !C[2] ? C[2] = l : l && (C[2] = "(" + C[2] + ") and (" + l + ")"), E.push(C));
|
|
9001
9001
|
}
|
|
9002
9002
|
}, E;
|
|
9003
9003
|
};
|
|
@@ -9007,12 +9007,12 @@ var At = function(q) {
|
|
|
9007
9007
|
return window && document && document.all && !window.atob;
|
|
9008
9008
|
}, function() {
|
|
9009
9009
|
return E === void 0 && (E = W.apply(this, arguments)), E;
|
|
9010
|
-
}),
|
|
9011
|
-
var
|
|
9010
|
+
}), I = function(a) {
|
|
9011
|
+
var c = {};
|
|
9012
9012
|
return function(h, M) {
|
|
9013
9013
|
if (typeof h == "function")
|
|
9014
9014
|
return h();
|
|
9015
|
-
if (
|
|
9015
|
+
if (c[h] === void 0) {
|
|
9016
9016
|
var u = function(d, A) {
|
|
9017
9017
|
return A ? A.querySelector(d) : document.querySelector(d);
|
|
9018
9018
|
}.call(this, h, M);
|
|
@@ -9022,12 +9022,12 @@ var At = function(q) {
|
|
|
9022
9022
|
} catch {
|
|
9023
9023
|
u = null;
|
|
9024
9024
|
}
|
|
9025
|
-
|
|
9025
|
+
c[h] = u;
|
|
9026
9026
|
}
|
|
9027
|
-
return
|
|
9027
|
+
return c[h];
|
|
9028
9028
|
};
|
|
9029
9029
|
}(), s = null, w = 0, C = [], N = g(31);
|
|
9030
|
-
function r(a,
|
|
9030
|
+
function r(a, c) {
|
|
9031
9031
|
for (var h = 0; h < a.length; h++) {
|
|
9032
9032
|
var M = a[h], u = b[M.id];
|
|
9033
9033
|
if (u) {
|
|
@@ -9035,11 +9035,11 @@ var At = function(q) {
|
|
|
9035
9035
|
for (var d = 0; d < u.parts.length; d++)
|
|
9036
9036
|
u.parts[d](M.parts[d]);
|
|
9037
9037
|
for (; d < M.parts.length; d++)
|
|
9038
|
-
u.parts.push(v(M.parts[d],
|
|
9038
|
+
u.parts.push(v(M.parts[d], c));
|
|
9039
9039
|
} else {
|
|
9040
9040
|
var A = [];
|
|
9041
9041
|
for (d = 0; d < M.parts.length; d++)
|
|
9042
|
-
A.push(v(M.parts[d],
|
|
9042
|
+
A.push(v(M.parts[d], c));
|
|
9043
9043
|
b[M.id] = {
|
|
9044
9044
|
id: M.id,
|
|
9045
9045
|
refs: 1,
|
|
@@ -9048,9 +9048,9 @@ var At = function(q) {
|
|
|
9048
9048
|
}
|
|
9049
9049
|
}
|
|
9050
9050
|
}
|
|
9051
|
-
function T(a,
|
|
9051
|
+
function T(a, c) {
|
|
9052
9052
|
for (var h = [], M = {}, u = 0; u < a.length; u++) {
|
|
9053
|
-
var d = a[u], A =
|
|
9053
|
+
var d = a[u], A = c.base ? d[0] + c.base : d[0], Z = {
|
|
9054
9054
|
css: d[1],
|
|
9055
9055
|
media: d[2],
|
|
9056
9056
|
sourceMap: d[3]
|
|
@@ -9064,15 +9064,15 @@ var At = function(q) {
|
|
|
9064
9064
|
}
|
|
9065
9065
|
return h;
|
|
9066
9066
|
}
|
|
9067
|
-
function S(a,
|
|
9068
|
-
var h =
|
|
9067
|
+
function S(a, c) {
|
|
9068
|
+
var h = I(a.insertInto);
|
|
9069
9069
|
if (!h)
|
|
9070
9070
|
throw new Error("Couldn't find a style target. This probably means that the value for the 'insertInto' parameter is invalid.");
|
|
9071
9071
|
var M = C[C.length - 1];
|
|
9072
9072
|
if (a.insertAt === "top")
|
|
9073
|
-
M ? M.nextSibling ? h.insertBefore(
|
|
9073
|
+
M ? M.nextSibling ? h.insertBefore(c, M.nextSibling) : h.appendChild(c) : h.insertBefore(c, h.firstChild), C.push(c);
|
|
9074
9074
|
else if (a.insertAt === "bottom")
|
|
9075
|
-
h.appendChild(
|
|
9075
|
+
h.appendChild(c);
|
|
9076
9076
|
else {
|
|
9077
9077
|
if (jt(a.insertAt) != "object" || !a.insertAt.before)
|
|
9078
9078
|
throw new Error(
|
|
@@ -9083,48 +9083,48 @@ var At = function(q) {
|
|
|
9083
9083
|
(https://github.com/webpack-contrib/style-loader#insertat)
|
|
9084
9084
|
`
|
|
9085
9085
|
);
|
|
9086
|
-
var u =
|
|
9087
|
-
h.insertBefore(
|
|
9086
|
+
var u = I(a.insertAt.before, h);
|
|
9087
|
+
h.insertBefore(c, u);
|
|
9088
9088
|
}
|
|
9089
9089
|
}
|
|
9090
9090
|
function D(a) {
|
|
9091
9091
|
if (a.parentNode === null)
|
|
9092
9092
|
return !1;
|
|
9093
9093
|
a.parentNode.removeChild(a);
|
|
9094
|
-
var
|
|
9095
|
-
|
|
9094
|
+
var c = C.indexOf(a);
|
|
9095
|
+
c >= 0 && C.splice(c, 1);
|
|
9096
9096
|
}
|
|
9097
9097
|
function H(a) {
|
|
9098
|
-
var
|
|
9098
|
+
var c = document.createElement("style");
|
|
9099
9099
|
if (a.attrs.type === void 0 && (a.attrs.type = "text/css"), a.attrs.nonce === void 0) {
|
|
9100
9100
|
var h = function() {
|
|
9101
9101
|
return g.nc;
|
|
9102
9102
|
}();
|
|
9103
9103
|
h && (a.attrs.nonce = h);
|
|
9104
9104
|
}
|
|
9105
|
-
return j(
|
|
9105
|
+
return j(c, a.attrs), S(a, c), c;
|
|
9106
9106
|
}
|
|
9107
|
-
function j(a,
|
|
9108
|
-
Object.keys(
|
|
9109
|
-
a.setAttribute(h,
|
|
9107
|
+
function j(a, c) {
|
|
9108
|
+
Object.keys(c).forEach(function(h) {
|
|
9109
|
+
a.setAttribute(h, c[h]);
|
|
9110
9110
|
});
|
|
9111
9111
|
}
|
|
9112
|
-
function v(a,
|
|
9112
|
+
function v(a, c) {
|
|
9113
9113
|
var h, M, u, d;
|
|
9114
|
-
if (
|
|
9115
|
-
if (!(d = typeof
|
|
9114
|
+
if (c.transform && a.css) {
|
|
9115
|
+
if (!(d = typeof c.transform == "function" ? c.transform(a.css) : c.transform.default(a.css)))
|
|
9116
9116
|
return function() {
|
|
9117
9117
|
};
|
|
9118
9118
|
a.css = d;
|
|
9119
9119
|
}
|
|
9120
|
-
if (
|
|
9120
|
+
if (c.singleton) {
|
|
9121
9121
|
var A = w++;
|
|
9122
|
-
h = s || (s = H(
|
|
9122
|
+
h = s || (s = H(c)), M = m.bind(null, h, A, !1), u = m.bind(null, h, A, !0);
|
|
9123
9123
|
} else
|
|
9124
9124
|
a.sourceMap && typeof URL == "function" && typeof URL.createObjectURL == "function" && typeof URL.revokeObjectURL == "function" && typeof Blob == "function" && typeof btoa == "function" ? (h = function(Z) {
|
|
9125
9125
|
var L = document.createElement("link");
|
|
9126
9126
|
return Z.attrs.type === void 0 && (Z.attrs.type = "text/css"), Z.attrs.rel = "stylesheet", j(L, Z.attrs), S(Z, L), L;
|
|
9127
|
-
}(
|
|
9127
|
+
}(c), M = function(Z, L, J) {
|
|
9128
9128
|
var Y = J.css, R = J.sourceMap, V = L.convertToAbsoluteUrls === void 0 && R;
|
|
9129
9129
|
(L.convertToAbsoluteUrls || V) && (Y = N(Y)), R && (Y += `
|
|
9130
9130
|
/*# sourceMappingURL=data:application/json;base64,` + btoa(unescape(encodeURIComponent(JSON.stringify(R)))) + " */");
|
|
@@ -9132,9 +9132,9 @@ var At = function(q) {
|
|
|
9132
9132
|
type: "text/css"
|
|
9133
9133
|
}), z = Z.href;
|
|
9134
9134
|
Z.href = URL.createObjectURL($), z && URL.revokeObjectURL(z);
|
|
9135
|
-
}.bind(null, h,
|
|
9135
|
+
}.bind(null, h, c), u = function() {
|
|
9136
9136
|
D(h), h.href && URL.revokeObjectURL(h.href);
|
|
9137
|
-
}) : (h = H(
|
|
9137
|
+
}) : (h = H(c), M = function(Z, L) {
|
|
9138
9138
|
var J = L.css, Y = L.media;
|
|
9139
9139
|
if (Y && Z.setAttribute("media", Y), Z.styleSheet)
|
|
9140
9140
|
Z.styleSheet.cssText = J;
|
|
@@ -9155,17 +9155,17 @@ var At = function(q) {
|
|
|
9155
9155
|
u();
|
|
9156
9156
|
};
|
|
9157
9157
|
}
|
|
9158
|
-
q.exports = function(a,
|
|
9158
|
+
q.exports = function(a, c) {
|
|
9159
9159
|
if (typeof DEBUG < "u" && DEBUG && (typeof document > "u" ? "undefined" : jt(document)) != "object")
|
|
9160
9160
|
throw new Error("The style-loader cannot be used in a non-browser environment");
|
|
9161
|
-
(
|
|
9162
|
-
var h = T(a,
|
|
9163
|
-
return r(h,
|
|
9161
|
+
(c = c || {}).attrs = jt(c.attrs) == "object" ? c.attrs : {}, c.singleton || typeof c.singleton == "boolean" || (c.singleton = l()), c.insertInto || (c.insertInto = "head"), c.insertAt || (c.insertAt = "bottom");
|
|
9162
|
+
var h = T(a, c);
|
|
9163
|
+
return r(h, c), function(M) {
|
|
9164
9164
|
for (var u = [], d = 0; d < h.length; d++) {
|
|
9165
9165
|
var A = h[d];
|
|
9166
9166
|
(Z = b[A.id]).refs--, u.push(Z);
|
|
9167
9167
|
}
|
|
9168
|
-
for (M && r(T(M,
|
|
9168
|
+
for (M && r(T(M, c), c), d = 0; d < u.length; d++) {
|
|
9169
9169
|
var Z;
|
|
9170
9170
|
if ((Z = u[d]).refs === 0) {
|
|
9171
9171
|
for (var L = 0; L < Z.parts.length; L++)
|
|
@@ -9175,17 +9175,17 @@ var At = function(q) {
|
|
|
9175
9175
|
}
|
|
9176
9176
|
};
|
|
9177
9177
|
};
|
|
9178
|
-
var P, o = (P = [], function(a,
|
|
9179
|
-
return P[a] =
|
|
9178
|
+
var P, o = (P = [], function(a, c) {
|
|
9179
|
+
return P[a] = c, P.filter(Boolean).join(`
|
|
9180
9180
|
`);
|
|
9181
9181
|
});
|
|
9182
|
-
function m(a,
|
|
9182
|
+
function m(a, c, h, M) {
|
|
9183
9183
|
var u = h ? "" : M.css;
|
|
9184
9184
|
if (a.styleSheet)
|
|
9185
|
-
a.styleSheet.cssText = o(
|
|
9185
|
+
a.styleSheet.cssText = o(c, u);
|
|
9186
9186
|
else {
|
|
9187
9187
|
var d = document.createTextNode(u), A = a.childNodes;
|
|
9188
|
-
A[
|
|
9188
|
+
A[c] && a.removeChild(A[c]), A.length ? a.insertBefore(d, A[c]) : a.appendChild(d);
|
|
9189
9189
|
}
|
|
9190
9190
|
}
|
|
9191
9191
|
},
|
|
@@ -9197,8 +9197,8 @@ var At = function(q) {
|
|
|
9197
9197
|
if (!g || typeof g != "string")
|
|
9198
9198
|
return g;
|
|
9199
9199
|
var E = W.protocol + "//" + W.host, b = E + W.pathname.replace(/\/[^\/]*$/, "/");
|
|
9200
|
-
return g.replace(/url\s*\(((?:[^)(]|\((?:[^)(]+|\([^)(]*\))*\))*)\)/gi, function(l,
|
|
9201
|
-
var s, w =
|
|
9200
|
+
return g.replace(/url\s*\(((?:[^)(]|\((?:[^)(]+|\([^)(]*\))*\))*)\)/gi, function(l, I) {
|
|
9201
|
+
var s, w = I.trim().replace(/^"(.*)"$/, function(C, N) {
|
|
9202
9202
|
return N;
|
|
9203
9203
|
}).replace(/^'(.*)'$/, function(C, N) {
|
|
9204
9204
|
return N;
|
|
@@ -9233,11 +9233,11 @@ var At = function(q) {
|
|
|
9233
9233
|
}, this.opts = g.extend(!0, {}, this.defaults, l), this.random = new Date().getTime() + parseInt(1e3 * Math.random()), this.eventBind();
|
|
9234
9234
|
},
|
|
9235
9235
|
renderMenu: function(b, l) {
|
|
9236
|
-
var
|
|
9236
|
+
var I = this, s = l;
|
|
9237
9237
|
if (b && b.length) {
|
|
9238
9238
|
var w = x('<ul class="hicontextmenu" style="z-index: 9999;"></ul>');
|
|
9239
9239
|
if (l) {
|
|
9240
|
-
var C = b.length *
|
|
9240
|
+
var C = b.length * I.opts.itemHeight - 31;
|
|
9241
9241
|
w.css({
|
|
9242
9242
|
top: -C
|
|
9243
9243
|
});
|
|
@@ -9246,7 +9246,7 @@ var At = function(q) {
|
|
|
9246
9246
|
var T = '<div class="nav">' + (r.desc || "") + "</div>", S = '<i class="svicon ' + r.icon + '"></i>';
|
|
9247
9247
|
r.menus && r.menus.length && (T = '<div class="nav">' + (r.desc || "") + "\u203A</div>");
|
|
9248
9248
|
var D = !!r.disable && r.disable(), H = x('<li class="hicontextmenuitem"><a href="javascript:void(0);"><div class="title">' + S + "<span>" + (r.text || "") + "</span></div>" + T + "</a></li>");
|
|
9249
|
-
D && H.addClass("disable"), r.borderBottom && H.addClass("borderBottom"), r.menus && (H.addClass("hicontextsubmenu"),
|
|
9249
|
+
D && H.addClass("disable"), r.borderBottom && H.addClass("borderBottom"), r.menus && (H.addClass("hicontextsubmenu"), I.renderMenu(r.menus, H)), r.callback && H.click(function(j) {
|
|
9250
9250
|
x(this).hasClass("disable") || (x(".hicontextmenuroot").remove(), r.callback()), j.stopPropagation();
|
|
9251
9251
|
}), w.append(H);
|
|
9252
9252
|
}), l && l.append(w);
|
|
@@ -9254,8 +9254,8 @@ var At = function(q) {
|
|
|
9254
9254
|
l || x("body").append(s).find(".hicontextmenuroot").hide();
|
|
9255
9255
|
},
|
|
9256
9256
|
setPosition: function(b) {
|
|
9257
|
-
var l = this,
|
|
9258
|
-
C >
|
|
9257
|
+
var l = this, I = document.documentElement.clientWidth, s = document.documentElement.clientHeight, w = x(".hicontextmenuroot").height(), C = b.pageX, N = b.pageY;
|
|
9258
|
+
C > I - l.opts.width && (C -= l.opts.width), N > s - w && (N -= w), x(".hicontextmenuroot").css({
|
|
9259
9259
|
left: C,
|
|
9260
9260
|
top: N
|
|
9261
9261
|
}).show();
|
|
@@ -9264,14 +9264,14 @@ var At = function(q) {
|
|
|
9264
9264
|
var b = this;
|
|
9265
9265
|
this.ele.on("contextmenu", function(l) {
|
|
9266
9266
|
x(".hicontextmenuroot").remove(), l.preventDefault();
|
|
9267
|
-
var
|
|
9267
|
+
var I = b.opts.menus.filter(function(w) {
|
|
9268
9268
|
return typeof w.enabled == "boolean" ? w.enabled : w.enabled();
|
|
9269
9269
|
});
|
|
9270
9270
|
if (!b.opts.table) {
|
|
9271
9271
|
var s = b.opts.panel.getSelectEls();
|
|
9272
9272
|
s.length <= 1 && x(this).trigger(x.Event("click"));
|
|
9273
9273
|
}
|
|
9274
|
-
b.renderMenu(
|
|
9274
|
+
b.renderMenu(I), b.setPosition(l), b.opts.target && typeof b.opts.target == "function" && b.opts.target(g(this));
|
|
9275
9275
|
}), g("body").on("click", function() {
|
|
9276
9276
|
g(".hicontextmenuroot").remove();
|
|
9277
9277
|
});
|
|
@@ -9344,7 +9344,7 @@ var At = function(q) {
|
|
|
9344
9344
|
}, y.prototype.formatterModule = function(t) {
|
|
9345
9345
|
return t || "_default";
|
|
9346
9346
|
}, y;
|
|
9347
|
-
}(),
|
|
9347
|
+
}(), I = g(1), s = g(2), w = function() {
|
|
9348
9348
|
function y() {
|
|
9349
9349
|
}
|
|
9350
9350
|
return y.prototype.createPrintElementTypeHtml = function(t, i) {
|
|
@@ -9444,10 +9444,10 @@ var At = function(q) {
|
|
|
9444
9444
|
}), v = function(y) {
|
|
9445
9445
|
function t(i, p) {
|
|
9446
9446
|
var f = y.call(this, i) || this;
|
|
9447
|
-
return f.options = new H.a(p), f.options.setDefault(new H.a(
|
|
9447
|
+
return f.options = new H.a(p), f.options.setDefault(new H.a(I.a.instance.image.default).getPrintElementOptionEntity()), f;
|
|
9448
9448
|
}
|
|
9449
9449
|
return j(t, y), t.prototype.getReizeableShowPoints = function() {
|
|
9450
|
-
return this.options.showPoints ||
|
|
9450
|
+
return this.options.showPoints || I.a.instance.image.showPoints;
|
|
9451
9451
|
}, t.prototype.getData = function(i) {
|
|
9452
9452
|
var p = "", f = this.getField();
|
|
9453
9453
|
i ? p = f ? f.split(".").reduce((k, G) => k ? k[G] : i[G], !1) || "" : this.options.src || this.printElementType.getData() : p = this.options.src || this.printElementType.getData();
|
|
@@ -9461,7 +9461,7 @@ var At = function(q) {
|
|
|
9461
9461
|
}, t.prototype.initSizeByHtml = function(i) {
|
|
9462
9462
|
y.prototype.initSizeByHtml.call(this, i), this.css(i, this.getData());
|
|
9463
9463
|
}, t.prototype.getConfigOptions = function() {
|
|
9464
|
-
return
|
|
9464
|
+
return I.a.instance.image;
|
|
9465
9465
|
}, t.prototype.updateDesignViewFromOptions = function() {
|
|
9466
9466
|
this.designTarget && (this.css(this.designTarget, this.getData()), this.updateTargetImage(this.designTarget, this.getTitle(), this.getData()));
|
|
9467
9467
|
}, t.prototype.updateTargetImage = function(i, p, f) {
|
|
@@ -9513,7 +9513,7 @@ var At = function(q) {
|
|
|
9513
9513
|
}, y.prototype.setTopOffset = function(t) {
|
|
9514
9514
|
t ? this.paperContentTarget.css("top", t + "pt") : this.paperContentTarget[0].style.top = "";
|
|
9515
9515
|
}, y.prototype.createTarget = function() {
|
|
9516
|
-
this.target = x('<div class="hiprint-printPaper"><div class="hiprint-printPaper-content"></div></div>'), this.paperContentTarget = this.target.find(".hiprint-printPaper-content"), this.target.css("width", this.mmwidth + "mm"), this.target.css("height", this.mmheight -
|
|
9516
|
+
this.target = x('<div class="hiprint-printPaper"><div class="hiprint-printPaper-content"></div></div>'), this.paperContentTarget = this.target.find(".hiprint-printPaper-content"), this.target.css("width", this.mmwidth + "mm"), this.target.css("height", this.mmheight - I.a.instance.paperHeightTrim + "mm"), this.target.attr("original-height", this.mmheight), this.zoom(this.scale);
|
|
9517
9517
|
}, y.prototype.createHeaderLine = function() {
|
|
9518
9518
|
var t = this;
|
|
9519
9519
|
this.headerLinetarget = x('<div class="hiprint-headerLine" style="position: absolute;width: 100%;border-top: 1px dashed #c9bebe;height: 7pt;"></div>'), this.headerLinetarget.css("top", (this.paperHeader || -1) + "pt"), this.paperHeader == 0 && this.headerLinetarget.addClass("hideheaderLinetarget"), this.paperContentTarget.append(this.headerLinetarget), this.dragHeadLineOrFootLine(this.headerLinetarget, function(i, p) {
|
|
@@ -9521,7 +9521,7 @@ var At = function(q) {
|
|
|
9521
9521
|
});
|
|
9522
9522
|
}, y.prototype.createFooterLine = function() {
|
|
9523
9523
|
var t = this;
|
|
9524
|
-
this.footerLinetarget = x('<div class="hiprint-footerLine" style="position: absolute;width: 100%;border-top: 1px dashed #c9bebe;height: 7pt;"></div>'), this.footerLinetarget.css("top", parseInt(this.paperFooter.toString()) + "pt"), this.paperFooter == this.height && (this.footerLinetarget.css("top", this.mmheight -
|
|
9524
|
+
this.footerLinetarget = x('<div class="hiprint-footerLine" style="position: absolute;width: 100%;border-top: 1px dashed #c9bebe;height: 7pt;"></div>'), this.footerLinetarget.css("top", parseInt(this.paperFooter.toString()) + "pt"), this.paperFooter == this.height && (this.footerLinetarget.css("top", this.mmheight - I.a.instance.paperHeightTrim + "mm"), this.footerLinetarget.addClass("hidefooterLinetarget")), this.paperContentTarget.append(this.footerLinetarget), this.dragHeadLineOrFootLine(this.footerLinetarget, function(i, p) {
|
|
9525
9525
|
p <= t.paperHeader && (p = t.paperHeader + 10), t.paperFooter = p, t.triggerOnPaperBaseInfoChanged();
|
|
9526
9526
|
});
|
|
9527
9527
|
}, y.prototype.createPaperNumber = function(t, i) {
|
|
@@ -9546,7 +9546,7 @@ var At = function(q) {
|
|
|
9546
9546
|
t >= this.printLine && (this.printLine = t);
|
|
9547
9547
|
}, y.prototype.design = function(t) {
|
|
9548
9548
|
var i = this;
|
|
9549
|
-
this.createHeaderLine(), this.createFooterLine(), this.target.addClass("design"), t && t.grid && this.target.addClass("grid"), this.target.parent().parent().css("width", this.mmwidth + "mm"), this.target.parent().parent().css("height", this.mmheight + "mm"), this.paperNumberTarget = this.createPaperNumber(this.formatPaperNumber(1, 1), !0), this.createRuler(), this.createWaterMark(!0, this.panelIdx, this.watermarkOptions), this.resetPaperNumber(this.paperNumberTarget), x(this.paperNumberTarget).bind("dblclick.hiprint", function() {
|
|
9549
|
+
this.createHeaderLine(), this.createFooterLine(), this.target.addClass("design"), t && t.grid && this.target.addClass("grid"), this.target.parent().parent().css("width", this.mmwidth + "mm"), this.target.parent().parent().css("height", this.mmheight - I.a.instance.paperHeightTrim + "mm"), this.paperNumberTarget = this.createPaperNumber(this.formatPaperNumber(1, 1), !0), this.createRuler(), this.createWaterMark(!0, this.panelIdx, this.watermarkOptions), this.resetPaperNumber(this.paperNumberTarget), x(this.paperNumberTarget).bind("dblclick.hiprint", function() {
|
|
9550
9550
|
i.paperNumberDisabled == null && (i.paperNumberDisabled = !1), i.paperNumberDisabled = !i.paperNumberDisabled, i.resetPaperNumber(i.paperNumberTarget), i.triggerOnPaperBaseInfoChanged("\u521D\u59CB");
|
|
9551
9551
|
}), x(this.paperNumberTarget).bind("click.hiprint", function() {
|
|
9552
9552
|
E.a.event.trigger("BuildCustomOptionSettingEventKey_" + i.templateId, {
|
|
@@ -9574,7 +9574,7 @@ var At = function(q) {
|
|
|
9574
9574
|
i(G, O);
|
|
9575
9575
|
},
|
|
9576
9576
|
moveUnit: "pt",
|
|
9577
|
-
minMove:
|
|
9577
|
+
minMove: I.a.instance.movingDistance,
|
|
9578
9578
|
onBeforeDrag: function(k) {
|
|
9579
9579
|
s.a.instance.draging = !0;
|
|
9580
9580
|
},
|
|
@@ -9587,7 +9587,7 @@ var At = function(q) {
|
|
|
9587
9587
|
});
|
|
9588
9588
|
}, y.prototype.resize = function(t, i) {
|
|
9589
9589
|
var p = this.paperFooter / this.height;
|
|
9590
|
-
this.width = E.a.mm.toPt(t), this.height = E.a.mm.toPt(i), this.mmwidth = t, this.mmheight = i, this.target.css("width", t + "mm"), this.target.css("height", i -
|
|
9590
|
+
this.width = E.a.mm.toPt(t), this.height = E.a.mm.toPt(i), this.mmwidth = t, this.mmheight = i, this.target.css("width", t + "mm"), this.target.css("height", i - I.a.instance.paperHeightTrim + "mm"), this.target.parent().parent().css("width", t + "mm"), this.target.parent().parent().css("height", i - I.a.instance.paperHeightTrim + "mm"), this.target.attr("original-height", this.mmheight);
|
|
9591
9591
|
var f = this.height * p;
|
|
9592
9592
|
this.paperFooter = f || this.height, this.footerLinetarget.css("top", f + "pt"), this.contentHeight = this.paperFooter - this.paperHeader, this.paperNumberLeft = this.paperNumberLeft > this.width ? parseInt((this.width - 30).toString()) : this.paperNumberLeft, this.paperNumberTop = this.paperNumberTop > this.height ? this.paperNumberTop = parseInt((this.height - 22).toString()) : this.paperNumberTop, this.paperNumberTarget.css("top", this.paperNumberTop + "pt"), this.paperNumberTarget.css("left", this.paperNumberLeft + "pt"), this.triggerOnPaperBaseInfoChanged("\u8C03\u6574\u5927\u5C0F");
|
|
9593
9593
|
}, y.prototype.zoom = function(t) {
|
|
@@ -9616,16 +9616,16 @@ var At = function(q) {
|
|
|
9616
9616
|
})
|
|
9617
9617
|
), Ft.createWatermark(U)) : Ft.destroyWatermark(U));
|
|
9618
9618
|
}, y.prototype.displayHeight = function() {
|
|
9619
|
-
return this.mmheight -
|
|
9619
|
+
return this.mmheight - I.a.instance.paperHeightTrim + "mm";
|
|
9620
9620
|
}, y.prototype.displayWidth = function() {
|
|
9621
9621
|
return this.mmwidth + "mm";
|
|
9622
9622
|
}, y.prototype.getPanelTarget = function() {
|
|
9623
9623
|
return this.target.parent(".hiprint-printPanel ");
|
|
9624
9624
|
}, y;
|
|
9625
|
-
}(), a = g(6),
|
|
9625
|
+
}(), a = g(6), c = function(y) {
|
|
9626
9626
|
function t(i, p) {
|
|
9627
9627
|
var f = y.call(this, i) || this;
|
|
9628
|
-
return f.options = new P(p), f.options.setDefault(new P(
|
|
9628
|
+
return f.options = new P(p), f.options.setDefault(new P(I.a.instance.longText.default).getPrintElementOptionEntity()), f;
|
|
9629
9629
|
}
|
|
9630
9630
|
return j(t, y), t.prototype.getDesignTarget = function(i) {
|
|
9631
9631
|
var p = y.prototype.getDesignTarget.call(this, i);
|
|
@@ -9640,7 +9640,7 @@ var At = function(q) {
|
|
|
9640
9640
|
this.designTarget.find(".hiprint-printElement-longText-content").html(p.find(".hiprint-printElement-longText-content").html()), this.css(this.designTarget, i);
|
|
9641
9641
|
}
|
|
9642
9642
|
}, t.prototype.getConfigOptions = function() {
|
|
9643
|
-
return
|
|
9643
|
+
return I.a.instance.longText;
|
|
9644
9644
|
}, t.prototype.getTitle = function() {
|
|
9645
9645
|
return this.options.title || this.printElementType.title;
|
|
9646
9646
|
}, t.prototype.getData = function(i) {
|
|
@@ -9800,7 +9800,7 @@ var At = function(q) {
|
|
|
9800
9800
|
}(H.a), u = function(y) {
|
|
9801
9801
|
function t(i, p) {
|
|
9802
9802
|
var f = y.call(this, i) || this;
|
|
9803
|
-
return f.options = new M(p), f.options.setDefault(new M(
|
|
9803
|
+
return f.options = new M(p), f.options.setDefault(new M(I.a.instance.text.default).getPrintElementOptionEntity()), f;
|
|
9804
9804
|
}
|
|
9805
9805
|
return j(t, y), t.prototype.getDesignTarget = function(i) {
|
|
9806
9806
|
return y.prototype.getDesignTarget.call(this, i);
|
|
@@ -9814,7 +9814,7 @@ var At = function(q) {
|
|
|
9814
9814
|
this.css(this.designTarget, i), this.updateTargetText(this.designTarget, this.getTitle(), i);
|
|
9815
9815
|
}
|
|
9816
9816
|
}, t.prototype.getConfigOptions = function() {
|
|
9817
|
-
return
|
|
9817
|
+
return I.a.instance.text;
|
|
9818
9818
|
}, t.prototype.getTitle = function() {
|
|
9819
9819
|
var i = this.options.title || this.printElementType.title || "";
|
|
9820
9820
|
return i && (i = h.replaceEnterAndNewlineAndTab(i, "")), i;
|
|
@@ -9894,7 +9894,7 @@ var At = function(q) {
|
|
|
9894
9894
|
}(H.a), A = function(y) {
|
|
9895
9895
|
function t(i, p) {
|
|
9896
9896
|
var f = y.call(this, i) || this;
|
|
9897
|
-
return f.options = new d(p), f.options.setDefault(new d(
|
|
9897
|
+
return f.options = new d(p), f.options.setDefault(new d(I.a.instance.html.default).getPrintElementOptionEntity()), f;
|
|
9898
9898
|
}
|
|
9899
9899
|
return j(t, y), t.prototype.updateDesignViewFromOptions = function() {
|
|
9900
9900
|
if (this.designTarget) {
|
|
@@ -9908,9 +9908,9 @@ var At = function(q) {
|
|
|
9908
9908
|
this.designTarget.find(".hiprint-printElement-html-content").html(p);
|
|
9909
9909
|
}
|
|
9910
9910
|
}, t.prototype.getReizeableShowPoints = function() {
|
|
9911
|
-
return this.options.showPoints ||
|
|
9911
|
+
return this.options.showPoints || I.a.instance.html.showPoints;
|
|
9912
9912
|
}, t.prototype.getConfigOptions = function() {
|
|
9913
|
-
return
|
|
9913
|
+
return I.a.instance.html;
|
|
9914
9914
|
}, t.prototype.createTarget = function(i, p) {
|
|
9915
9915
|
var f = x(
|
|
9916
9916
|
'<div class="hiprint-printElement hiprint-printElement-html" style="position: absolute;"><div class="hiprint-printElement-html-content" style="height:100%;width:100%"></div></div>'
|
|
@@ -9927,7 +9927,7 @@ var At = function(q) {
|
|
|
9927
9927
|
}(D.a), Z = function(y) {
|
|
9928
9928
|
function t(i, p) {
|
|
9929
9929
|
var f = y.call(this, i) || this;
|
|
9930
|
-
return f.options = new H.a(p), f.options.setDefault(new H.a(
|
|
9930
|
+
return f.options = new H.a(p), f.options.setDefault(new H.a(I.a.instance.vline.default).getPrintElementOptionEntity()), f;
|
|
9931
9931
|
}
|
|
9932
9932
|
return j(t, y), t.prototype.updateDesignViewFromOptions = function() {
|
|
9933
9933
|
if (this.designTarget) {
|
|
@@ -9935,18 +9935,18 @@ var At = function(q) {
|
|
|
9935
9935
|
this.css(this.designTarget, i);
|
|
9936
9936
|
}
|
|
9937
9937
|
}, t.prototype.getConfigOptions = function() {
|
|
9938
|
-
return
|
|
9938
|
+
return I.a.instance.vline;
|
|
9939
9939
|
}, t.prototype.createTarget = function(i, p) {
|
|
9940
9940
|
return x('<div class="hiprint-printElement hiprint-printElement-vline" style="border-left:1px solid;position: absolute;"></div>');
|
|
9941
9941
|
}, t.prototype.getReizeableShowPoints = function() {
|
|
9942
|
-
return this.options.showPoints ||
|
|
9942
|
+
return this.options.showPoints || I.a.instance.vline.showPoints;
|
|
9943
9943
|
}, t.prototype.getHtml = function(i, p, f) {
|
|
9944
9944
|
return this.getHtml2(i, p, f);
|
|
9945
9945
|
}, t;
|
|
9946
9946
|
}(D.a), L = function(y) {
|
|
9947
9947
|
function t(i, p) {
|
|
9948
9948
|
var f = y.call(this, i) || this;
|
|
9949
|
-
return f.options = new H.a(p), f.options.setDefault(new H.a(
|
|
9949
|
+
return f.options = new H.a(p), f.options.setDefault(new H.a(I.a.instance.hline.default).getPrintElementOptionEntity()), f;
|
|
9950
9950
|
}
|
|
9951
9951
|
return j(t, y), t.prototype.updateDesignViewFromOptions = function() {
|
|
9952
9952
|
if (this.designTarget) {
|
|
@@ -9954,16 +9954,16 @@ var At = function(q) {
|
|
|
9954
9954
|
this.css(this.designTarget, i);
|
|
9955
9955
|
}
|
|
9956
9956
|
}, t.prototype.getConfigOptions = function() {
|
|
9957
|
-
return
|
|
9957
|
+
return I.a.instance.hline;
|
|
9958
9958
|
}, t.prototype.createTarget = function(i, p) {
|
|
9959
9959
|
return x('<div class="hiprint-printElement hiprint-printElement-hline" style="border-top:1px solid;position: absolute;"></div>');
|
|
9960
9960
|
}, t.prototype.getReizeableShowPoints = function() {
|
|
9961
|
-
return this.options.showPoints ||
|
|
9961
|
+
return this.options.showPoints || I.a.instance.hline.showPoints;
|
|
9962
9962
|
}, t;
|
|
9963
9963
|
}(D.a), J = function(y) {
|
|
9964
9964
|
function t(i, p) {
|
|
9965
9965
|
var f = y.call(this, i) || this;
|
|
9966
|
-
return f.options = new H.a(p), f.options.setDefault(new H.a(
|
|
9966
|
+
return f.options = new H.a(p), f.options.setDefault(new H.a(I.a.instance.rect.default).getPrintElementOptionEntity()), f;
|
|
9967
9967
|
}
|
|
9968
9968
|
return j(t, y), t.prototype.updateDesignViewFromOptions = function() {
|
|
9969
9969
|
if (this.designTarget) {
|
|
@@ -9971,9 +9971,9 @@ var At = function(q) {
|
|
|
9971
9971
|
this.css(this.designTarget, i);
|
|
9972
9972
|
}
|
|
9973
9973
|
}, t.prototype.getReizeableShowPoints = function() {
|
|
9974
|
-
return this.options.showPoints ||
|
|
9974
|
+
return this.options.showPoints || I.a.instance.rect.showPoints;
|
|
9975
9975
|
}, t.prototype.getConfigOptions = function() {
|
|
9976
|
-
return
|
|
9976
|
+
return I.a.instance.rect;
|
|
9977
9977
|
}, t.prototype.createTarget = function(i, p) {
|
|
9978
9978
|
return x('<div class="hiprint-printElement hiprint-printElement-rect" style="border:1px solid;position: absolute;"></div>');
|
|
9979
9979
|
}, t.prototype.getHtml = function(i, p, f) {
|
|
@@ -9982,7 +9982,7 @@ var At = function(q) {
|
|
|
9982
9982
|
}(D.a), Y = function(y) {
|
|
9983
9983
|
function t(i, p) {
|
|
9984
9984
|
var f = y.call(this, i) || this;
|
|
9985
|
-
return f.options = new H.a(p), f.options.setDefault(new H.a(
|
|
9985
|
+
return f.options = new H.a(p), f.options.setDefault(new H.a(I.a.instance.oval.default).getPrintElementOptionEntity()), f;
|
|
9986
9986
|
}
|
|
9987
9987
|
return j(t, y), t.prototype.updateDesignViewFromOptions = function() {
|
|
9988
9988
|
if (this.designTarget) {
|
|
@@ -9990,9 +9990,9 @@ var At = function(q) {
|
|
|
9990
9990
|
this.css(this.designTarget, i);
|
|
9991
9991
|
}
|
|
9992
9992
|
}, t.prototype.getReizeableShowPoints = function() {
|
|
9993
|
-
return this.options.showPoints ||
|
|
9993
|
+
return this.options.showPoints || I.a.instance.oval.showPoints;
|
|
9994
9994
|
}, t.prototype.getConfigOptions = function() {
|
|
9995
|
-
return
|
|
9995
|
+
return I.a.instance.oval;
|
|
9996
9996
|
}, t.prototype.createTarget = function(i, p) {
|
|
9997
9997
|
return x('<div class="hiprint-printElement hiprint-printElement-oval" style="border:1px solid;position: absolute;border-radius: 50%;"></div>');
|
|
9998
9998
|
}, t.prototype.getHtml = function(i, p, f) {
|
|
@@ -10003,11 +10003,11 @@ var At = function(q) {
|
|
|
10003
10003
|
}
|
|
10004
10004
|
return y.createPrintElement = function(t, i) {
|
|
10005
10005
|
if (["text", "image", "longText", "table", "html", "vline", "hline", "rect", "oval"].includes(t.type))
|
|
10006
|
-
return t.type == "text" ? new u(t, i) : t.type == "image" ? new v(t, i) : t.type == "longText" ? new
|
|
10007
|
-
var p, f =
|
|
10006
|
+
return t.type == "text" ? new u(t, i) : t.type == "image" ? new v(t, i) : t.type == "longText" ? new c(t, i) : t.type == "table" ? new N.a(t, i) : t.type == "html" ? new A(t, i) : t.type == "vline" ? new Z(t, i) : t.type == "hline" ? new L(t, i) : t.type == "rect" ? new J(t, i) : t.type == "oval" ? new Y(t, i) : void 0;
|
|
10007
|
+
var p, f = I.a.instance.getHooks("createPrintElement");
|
|
10008
10008
|
return f && f.forEach((U) => {
|
|
10009
10009
|
p = U.run({
|
|
10010
|
-
Config:
|
|
10010
|
+
Config: I.a.instance,
|
|
10011
10011
|
BasePrintElement: D.a,
|
|
10012
10012
|
Options: H.a,
|
|
10013
10013
|
Supper: j,
|
|
@@ -10196,7 +10196,7 @@ var At = function(q) {
|
|
|
10196
10196
|
var i = Date.now();
|
|
10197
10197
|
console.log("start", i);
|
|
10198
10198
|
var p = this;
|
|
10199
|
-
this.index = t.index, this.name = t.name, this.width = t.width, this.height = t.height, this.paperType = t.paperType, this.paperHeader = t.paperHeader, this.paperFooter = t.paperFooter, this.designPaper.width = E.a.mm.toPt(t.width), this.designPaper.height = E.a.mm.toPt(this.height), this.designPaper.paperType = this.paperType, this.designPaper.paperHeader = this.paperHeader, this.designPaper.paperFooter = this.paperFooter, this.designPaper.mmheight = t.height, this.designPaper.mmwidth = t.width, this.designPaper.headerLinetarget.css("top", (this.paperHeader || -1) + "pt"), this.paperHeader == 0 && this.designPaper.headerLinetarget.addClass("hideheaderLinetarget"), this.designPaper.footerLinetarget.css("top", parseInt(this.paperFooter.toString()) + "pt"), this.paperFooter == this.height && this.designPaper.footerLinetarget.css("top", t.height -
|
|
10199
|
+
this.index = t.index, this.name = t.name, this.width = t.width, this.height = t.height, this.paperType = t.paperType, this.paperHeader = t.paperHeader, this.paperFooter = t.paperFooter, this.designPaper.width = E.a.mm.toPt(t.width), this.designPaper.height = E.a.mm.toPt(this.height), this.designPaper.paperType = this.paperType, this.designPaper.paperHeader = this.paperHeader, this.designPaper.paperFooter = this.paperFooter, this.designPaper.mmheight = t.height, this.designPaper.mmwidth = t.width, this.designPaper.headerLinetarget.css("top", (this.paperHeader || -1) + "pt"), this.paperHeader == 0 && this.designPaper.headerLinetarget.addClass("hideheaderLinetarget"), this.designPaper.footerLinetarget.css("top", parseInt(this.paperFooter.toString()) + "pt"), this.paperFooter == this.height && this.designPaper.footerLinetarget.css("top", t.height - I.a.instance.paperHeightTrim + "mm"), this.watermarkOptions = t.watermarkOptions || {}, this.paperNumberLeft = t.paperNumberLeft, this.paperNumberTop = t.paperNumberTop, this.paperNumberDisabled = t.paperNumberDisabled, this.paperNumberFormat = t.paperNumberFormat, this.designPaper.paperNumberLeft = this.paperNumberLeft, this.designPaper.paperNumberTop = this.paperNumberTop, this.designPaper.paperNumberDisabled = this.paperNumberDisabled, this.designPaper.paperNumberFormat = this.paperNumberFormat, this.designPaper.paperNumberTarget.css("top", this.paperNumberTop + "pt").css("left", this.paperNumberLeft + "pt"), this.designPaper.resetPaperNumber(this.designPaper.paperNumberTarget), this.fontFamily = t.fontFamily, this.orient = t.orient, this.rotate = t.rotate, this.scale = t.scale, this.designPaper.fontFamily = this.fontFamily, this.designPaper.orient = this.orient, this.designPaper.scale = this.scale, this.panelPaperRule = t.panelPaperRule, this.panelPageRule = t.panelPageRule, this.firstPaperFooter = t.firstPaperFooter, this.evenPaperFooter = t.evenPaperFooter, this.oddPaperFooter = t.oddPaperFooter, this.lastPaperFooter = t.lastPaperFooter, this.topOffset = t.topOffset, this.leftOffset = t.leftOffset, this.designPaper.setFooter(this.firstPaperFooter, this.evenPaperFooter, this.oddPaperFooter, this.lastPaperFooter), this.designPaper.setOffset(this.leftOffset, this.topOffset), this.target.css("width", t.width + "mm"), this.target.css("height", t.height - I.a.instance.paperHeightTrim + "mm"), this.target.attr("original-height", t.height), this.target.parent().css("width", t.width + "mm"), this.target.parent().css("height", t.height - I.a.instance.paperHeightTrim + "mm"), this.designPaper.target.css("width", t.width + "mm"), this.designPaper.target.css("height", t.height - I.a.instance.paperHeightTrim + "mm"), this.designPaper.target.attr("original-height", t.height), this.zoom(this.scale);
|
|
10200
10200
|
var f = Date.now();
|
|
10201
10201
|
console.log("\u66F4\u65B0\u53C2\u6570 end", f), console.log("\u66F4\u65B0\u53C2\u6570 time:", f - i), this.printElements.forEach(function(U) {
|
|
10202
10202
|
U.designTarget && U.designTarget.length && U.designTarget.remove();
|
|
@@ -10217,7 +10217,7 @@ var At = function(q) {
|
|
|
10217
10217
|
x(document).keydown(function(i) {
|
|
10218
10218
|
if (i.target.tagName != "INPUT") {
|
|
10219
10219
|
(i.ctrlKey || i.metaKey) && i.keyCode == 90 && (i.shiftKey ? E.a.event.trigger("hiprintTemplateDataShortcutKey_" + t.templateId, "redo") : E.a.event.trigger("hiprintTemplateDataShortcutKey_" + t.templateId, "undo"), i.preventDefault());
|
|
10220
|
-
var p =
|
|
10220
|
+
var p = I.a.instance.getHooks("documentShortcutKeys");
|
|
10221
10221
|
p && p.forEach((f) => {
|
|
10222
10222
|
f.run({
|
|
10223
10223
|
panel: t,
|
|
@@ -10266,7 +10266,7 @@ var At = function(q) {
|
|
|
10266
10266
|
t.designPaper.target.attr("tabindex", "1"), t.designPaper.target.keydown(function(i) {
|
|
10267
10267
|
if (i.target.tagName != "INPUT") {
|
|
10268
10268
|
(i.ctrlKey || i.metaKey) && i.keyCode == 86 && (t.pasteJson(i), i.preventDefault());
|
|
10269
|
-
var p =
|
|
10269
|
+
var p = I.a.instance.getHooks("shortcutKeys");
|
|
10270
10270
|
p && p.forEach((f) => {
|
|
10271
10271
|
f.run({
|
|
10272
10272
|
panel: t,
|
|
@@ -10402,7 +10402,7 @@ var At = function(q) {
|
|
|
10402
10402
|
console.log("miss " + JSON.stringify(t));
|
|
10403
10403
|
});
|
|
10404
10404
|
}, y.prototype.mathroundToporleft = function(t) {
|
|
10405
|
-
var i =
|
|
10405
|
+
var i = I.a.instance.movingDistance;
|
|
10406
10406
|
return Math.round(t / i) * i;
|
|
10407
10407
|
}, y.prototype.appendDesignPrintElement = function(t, i, p) {
|
|
10408
10408
|
i.setCurrenttemplateData(void 0);
|
|
@@ -10529,8 +10529,8 @@ var At = function(q) {
|
|
|
10529
10529
|
s.a.instance.rectDraging = !0, !(i.target.className && jt(i.target.className) == "string" && i.target.className.includes("editing")) && (s.a.instance.draging || (t.mouseRect && t.mouseRect.target && t.mouseRect.target.remove(), i.buttons === 1 && s.a.instance.rectDraging && (jt(i.target.className) == "string" && i.target.className.includes("hiprint-printPaper hidroppable design") || i.target.className.includes("hiprint-printPaper-content")) && (t.mouseRect = new ht(
|
|
10530
10530
|
i.pageX,
|
|
10531
10531
|
i.pageY,
|
|
10532
|
-
s.a.instance.dragLengthCNum(i.pageX - t.designPaper.getTarget().offset().left,
|
|
10533
|
-
s.a.instance.dragLengthCNum(i.pageY - t.designPaper.getTarget().offset().top,
|
|
10532
|
+
s.a.instance.dragLengthCNum(i.pageX - t.designPaper.getTarget().offset().left, I.a.instance.movingDistance),
|
|
10533
|
+
s.a.instance.dragLengthCNum(i.pageY - t.designPaper.getTarget().offset().top, I.a.instance.movingDistance)
|
|
10534
10534
|
))));
|
|
10535
10535
|
}).on("mouseup", function(i) {
|
|
10536
10536
|
s.a.instance.rectDraging && t.mouseRect && x(".mouseRect").length && (x(".mouseRect").height() > 10 || x(".mouseRect").width() > 10) && setTimeout(function() {
|
|
@@ -10559,7 +10559,7 @@ var At = function(q) {
|
|
|
10559
10559
|
}), i.mouseRect.lastLeft = it / f, i.mouseRect.lastTop = K / f, s.a.instance.changed = !0;
|
|
10560
10560
|
},
|
|
10561
10561
|
moveUnit: "pt",
|
|
10562
|
-
minMove:
|
|
10562
|
+
minMove: I.a.instance.movingDistance,
|
|
10563
10563
|
onBeforeDrag: function(O) {
|
|
10564
10564
|
i.mouseRect.target.focus(), s.a.instance.draging = !0, i.mouseRect.mouseRectSelectedElement || (i.mouseRect.mouseRectSelectedElement = i.getElementInRect(i.mouseRect)), i.mouseRect.target.css({
|
|
10565
10565
|
transform: "unset"
|
|
@@ -10859,23 +10859,23 @@ var At = function(q) {
|
|
|
10859
10859
|
}), E.a.event.trigger("clearSettingContainer");
|
|
10860
10860
|
break;
|
|
10861
10861
|
case 37:
|
|
10862
|
-
i.mouseRect.updatePositionByMultipleSelect(0 -
|
|
10863
|
-
U.updatePositionByMultipleSelect(0 -
|
|
10862
|
+
i.mouseRect.updatePositionByMultipleSelect(0 - I.a.instance.movingDistance, 0), f.forEach(function(U) {
|
|
10863
|
+
U.updatePositionByMultipleSelect(0 - I.a.instance.movingDistance, 0);
|
|
10864
10864
|
}), p.preventDefault();
|
|
10865
10865
|
break;
|
|
10866
10866
|
case 38:
|
|
10867
|
-
i.mouseRect.updatePositionByMultipleSelect(0, 0 -
|
|
10868
|
-
U.updatePositionByMultipleSelect(0, 0 -
|
|
10867
|
+
i.mouseRect.updatePositionByMultipleSelect(0, 0 - I.a.instance.movingDistance), f.forEach(function(U) {
|
|
10868
|
+
U.updatePositionByMultipleSelect(0, 0 - I.a.instance.movingDistance);
|
|
10869
10869
|
}), p.preventDefault();
|
|
10870
10870
|
break;
|
|
10871
10871
|
case 39:
|
|
10872
|
-
i.mouseRect.updatePositionByMultipleSelect(
|
|
10873
|
-
U.updatePositionByMultipleSelect(
|
|
10872
|
+
i.mouseRect.updatePositionByMultipleSelect(I.a.instance.movingDistance, 0), f.forEach(function(U) {
|
|
10873
|
+
U.updatePositionByMultipleSelect(I.a.instance.movingDistance, 0);
|
|
10874
10874
|
}), p.preventDefault();
|
|
10875
10875
|
break;
|
|
10876
10876
|
case 40:
|
|
10877
|
-
i.mouseRect.updatePositionByMultipleSelect(0,
|
|
10878
|
-
U.updatePositionByMultipleSelect(0,
|
|
10877
|
+
i.mouseRect.updatePositionByMultipleSelect(0, I.a.instance.movingDistance), f.forEach(function(U) {
|
|
10878
|
+
U.updatePositionByMultipleSelect(0, I.a.instance.movingDistance);
|
|
10879
10879
|
}), p.preventDefault();
|
|
10880
10880
|
}
|
|
10881
10881
|
[37, 38, 39, 40].includes(p.keyCode) && E.a.event.trigger("hiprintTemplateDataChanged_" + i.templateId, "\u6846\u9009\u79FB\u52A8");
|
|
@@ -10994,7 +10994,7 @@ var At = function(q) {
|
|
|
10994
10994
|
this.clearLastPrintElement();
|
|
10995
10995
|
var f = i || this.settingContainer;
|
|
10996
10996
|
i || this.settingContainer.html("");
|
|
10997
|
-
var U = [], k =
|
|
10997
|
+
var U = [], k = I.a.instance.panel.supportOptions.filter(function(it) {
|
|
10998
10998
|
return !it.hidden;
|
|
10999
10999
|
}).map(function(it) {
|
|
11000
11000
|
return it.name;
|
|
@@ -11093,7 +11093,7 @@ var At = function(q) {
|
|
|
11093
11093
|
i || (i = {});
|
|
11094
11094
|
var f = x('<div class="hiprint-printTemplate"></div>');
|
|
11095
11095
|
if (p.editingPanel) {
|
|
11096
|
-
var U = "height:" + p.editingPanel.height + "mm;", k = "width:" + p.editingPanel.width + "mm;";
|
|
11096
|
+
var U = "height:" + (p.editingPanel.height - I.a.instance.paperHeightTrim) + "mm;", k = "width:" + p.editingPanel.width + "mm;";
|
|
11097
11097
|
f = x('<div class="hiprint-printTemplate" style="' + U + k + '"></div>');
|
|
11098
11098
|
}
|
|
11099
11099
|
return t && t.constructor === Array ? t.forEach(function(G) {
|
|
@@ -11184,7 +11184,7 @@ var At = function(q) {
|
|
|
11184
11184
|
}, y.prototype.print = function(t, i, p) {
|
|
11185
11185
|
var f = this;
|
|
11186
11186
|
t || (t = {});
|
|
11187
|
-
var U = this.getHtml(t, i), k =
|
|
11187
|
+
var U = this.getHtml(t, i), k = I.a.instance.getHooks("beforePrint");
|
|
11188
11188
|
k && k.forEach((G) => {
|
|
11189
11189
|
var { template: O, info: it, opts: K } = G.run({
|
|
11190
11190
|
template: f,
|
|
@@ -11233,7 +11233,7 @@ var At = function(q) {
|
|
|
11233
11233
|
f.imgToBase64 = !0;
|
|
11234
11234
|
var U = t + this.getHtml(i, f)[0].outerHTML;
|
|
11235
11235
|
f.id = s.a.instance.guid(), f.html = U, f.templateId = this.id;
|
|
11236
|
-
var k = this, G =
|
|
11236
|
+
var k = this, G = I.a.instance.getHooks("beforePrint2");
|
|
11237
11237
|
G && G.forEach((O) => {
|
|
11238
11238
|
var { template: it, info: K } = O.run({ template: k, info: f });
|
|
11239
11239
|
k = it != null ? it : k, f = K != null ? K : f;
|
|
@@ -11544,20 +11544,20 @@ var At = function(q) {
|
|
|
11544
11544
|
}), t;
|
|
11545
11545
|
}
|
|
11546
11546
|
function Bt(y) {
|
|
11547
|
-
|
|
11547
|
+
I.a.instance.init(y), I.a.instance.providers && I.a.instance.providers.forEach(function(t) {
|
|
11548
11548
|
t.addElementTypes(l.instance);
|
|
11549
11549
|
});
|
|
11550
11550
|
}
|
|
11551
11551
|
function Ut(y) {
|
|
11552
|
-
|
|
11552
|
+
I.a.instance.register(y);
|
|
11553
11553
|
}
|
|
11554
11554
|
function Zt(y) {
|
|
11555
11555
|
y ? y && Object.keys(y).forEach(function(t) {
|
|
11556
|
-
if (t == "optionItems" && y.optionItems && y.optionItems.length &&
|
|
11556
|
+
if (t == "optionItems" && y.optionItems && y.optionItems.length && I.a.instance.registerItems(y.optionItems), y[t].tabs && y[t].tabs.length && (y[t].tabs.forEach(function(f, U) {
|
|
11557
11557
|
if (f.replace)
|
|
11558
|
-
x.extend(
|
|
11558
|
+
x.extend(I.a.instance[t].tabs[U], f);
|
|
11559
11559
|
else {
|
|
11560
|
-
var k = f.options, G =
|
|
11560
|
+
var k = f.options, G = I.a.instance[t].tabs[U].options;
|
|
11561
11561
|
k.forEach(function(O) {
|
|
11562
11562
|
var it = G.findIndex(function(K) {
|
|
11563
11563
|
return K.name == O.name;
|
|
@@ -11565,13 +11565,13 @@ var At = function(q) {
|
|
|
11565
11565
|
it > -1 ? G[it].hidden = O.hidden : O.after ? (it = G.findIndex(function(K) {
|
|
11566
11566
|
return K.name == O.after;
|
|
11567
11567
|
}), it > -1 && G.splice(it + 1, 0, O)) : G.push(O);
|
|
11568
|
-
}), x.extend(
|
|
11568
|
+
}), x.extend(I.a.instance[t].tabs[U], {
|
|
11569
11569
|
name: f.name,
|
|
11570
11570
|
options: G
|
|
11571
11571
|
});
|
|
11572
11572
|
}
|
|
11573
11573
|
}), delete y[t].tabs), y[t].supportOptions) {
|
|
11574
|
-
var i = y[t].supportOptions, p =
|
|
11574
|
+
var i = y[t].supportOptions, p = I.a.instance[t].supportOptions;
|
|
11575
11575
|
i.forEach(function(f) {
|
|
11576
11576
|
var U = p.findIndex(function(k) {
|
|
11577
11577
|
return k.name == f.name;
|
|
@@ -11579,25 +11579,25 @@ var At = function(q) {
|
|
|
11579
11579
|
U > -1 ? p[U].hidden = f.hidden : f.after ? (U = p.findIndex(function(k) {
|
|
11580
11580
|
return k.name == f.after;
|
|
11581
11581
|
}), U > -1 && p.splice(U + 1, 0, f)) : p.push(f);
|
|
11582
|
-
}), x.extend(
|
|
11582
|
+
}), x.extend(I.a.instance[t].supportOptions, p), delete y[t].supportOptions;
|
|
11583
11583
|
}
|
|
11584
|
-
x.extend(
|
|
11585
|
-
}) : x.extend(
|
|
11584
|
+
x.extend(I.a.instance[t], y[t]);
|
|
11585
|
+
}) : x.extend(I.a.instance, HIPRINT_CONFIG);
|
|
11586
11586
|
}
|
|
11587
11587
|
function Lt(y, t) {
|
|
11588
11588
|
return l.instance.updateElementType(y, t);
|
|
11589
11589
|
}
|
|
11590
11590
|
function zt(y) {
|
|
11591
|
-
|
|
11591
|
+
I.a.instance.clear("printerList"), I.a.instance.on("printerList", y), hiwebSocket.refreshPrinterList();
|
|
11592
11592
|
}
|
|
11593
11593
|
function Wt(y, t, ...i) {
|
|
11594
|
-
|
|
11594
|
+
I.a.instance.clear("address_" + y), I.a.instance.on("address_" + y, t), hiwebSocket.getAddress(y, ...i);
|
|
11595
11595
|
}
|
|
11596
11596
|
function Gt(y, t, i) {
|
|
11597
|
-
|
|
11597
|
+
I.a.instance.clear("ippPrinterCallback"), I.a.instance.on("ippPrinterCallback", t), I.a.instance.clear("ippPrinterConnected"), I.a.instance.on("ippPrinterConnected", i), hiwebSocket.ippPrint(y);
|
|
11598
11598
|
}
|
|
11599
11599
|
function kt(y, t) {
|
|
11600
|
-
|
|
11600
|
+
I.a.instance.clear("ippRequestCallback"), I.a.instance.on("ippRequestCallback", t), hiwebSocket.ippRequest(y);
|
|
11601
11601
|
}
|
|
11602
11602
|
g.d(F, "register", function() {
|
|
11603
11603
|
return Ut;
|
|
@@ -11633,9 +11633,9 @@ var At = function(q) {
|
|
|
11633
11633
|
return Et;
|
|
11634
11634
|
}), x(document).ready(function() {
|
|
11635
11635
|
console.log("document ready"), console.log(window.autoConnect);
|
|
11636
|
-
var y =
|
|
11636
|
+
var y = I.a.instance.getHooks("ready");
|
|
11637
11637
|
y && y.forEach((t) => {
|
|
11638
|
-
t.run({ p:
|
|
11638
|
+
t.run({ p: I, window });
|
|
11639
11639
|
}), hiwebSocket.hasIo() && window.autoConnect && hiwebSocket.start();
|
|
11640
11640
|
});
|
|
11641
11641
|
}
|
|
@@ -11645,13 +11645,13 @@ let Re = Ue(At);
|
|
|
11645
11645
|
q.fn.hiwprint = function(b) {
|
|
11646
11646
|
var l = document.getElementById("hiwprint_iframe");
|
|
11647
11647
|
l && l.parentNode.removeChild(l);
|
|
11648
|
-
var
|
|
11649
|
-
|
|
11648
|
+
var I = q.extend({}, q.fn.hiwprint.defaults, b), s = this, w = q('<iframe id="hiwprint_iframe" style="visibility: hidden; height: 0; width: 0; position: absolute;"></iframe>'), C = "";
|
|
11649
|
+
I.importCss && (I.styleHandler && (C += I.styleHandler()), q("link[media=print]").length > 0 && q("link[media=print]").each(function() {
|
|
11650
11650
|
q(this).attr("href").indexOf("print-lock.css") >= 0 && (C += '<link rel="stylesheet" type="text/css" media="print" href="' + q(this).attr("href") + '">', C += '<link rel="stylesheet" type="text/css" href="' + q(this).attr("href") + '">');
|
|
11651
11651
|
})), w[0].srcdoc = '<!DOCTYPE html><html><head><title></title><meta charset="UTF-8">' + C + "</head><body></body></html>", w[0].onload = function() {
|
|
11652
11652
|
var N = w[0].contentWindow || w[0].contentDocument;
|
|
11653
|
-
N.document && (N = N.document), w.attr("srcdoc") || N.write('<!DOCTYPE html><html><head><title></title><meta charset="UTF-8">' + C + "</head><body></body></html>"),
|
|
11654
|
-
F(w[0],
|
|
11653
|
+
N.document && (N = N.document), w.attr("srcdoc") || N.write('<!DOCTYPE html><html><head><title></title><meta charset="UTF-8">' + C + "</head><body></body></html>"), I.printContainer ? N.body.innerHTML = s[0].outerHTML : N.body.innerHTML = s.html(), E(N, function() {
|
|
11654
|
+
F(w[0], I);
|
|
11655
11655
|
});
|
|
11656
11656
|
}, w.appendTo("body");
|
|
11657
11657
|
}, q.fn.hiwprint.defaults = {
|
|
@@ -11671,8 +11671,8 @@ let Re = Ue(At);
|
|
|
11671
11671
|
else
|
|
11672
11672
|
b.contentWindow.print();
|
|
11673
11673
|
l.callback && l.callback();
|
|
11674
|
-
} catch (
|
|
11675
|
-
console.log(
|
|
11674
|
+
} catch (I) {
|
|
11675
|
+
console.log(I);
|
|
11676
11676
|
}
|
|
11677
11677
|
}
|
|
11678
11678
|
function g() {
|
|
@@ -11681,20 +11681,20 @@ let Re = Ue(At);
|
|
|
11681
11681
|
function W() {
|
|
11682
11682
|
return !g() && !!window.StyleMedia;
|
|
11683
11683
|
}
|
|
11684
|
-
function E(b, l,
|
|
11685
|
-
|
|
11684
|
+
function E(b, l, I) {
|
|
11685
|
+
I === void 0 && (I = 0);
|
|
11686
11686
|
for (var s = b.getElementsByTagName("img"), w = !0, C = 0; C < s.length; C++) {
|
|
11687
11687
|
var N = s[C];
|
|
11688
11688
|
N.src && N.src !== window.location.href && N.src.indexOf("base64") == -1 && (!N || typeof N.naturalWidth > "u" || N.naturalWidth === 0 || !N.complete) && (N.complete || (w = !1));
|
|
11689
11689
|
}
|
|
11690
|
-
|
|
11691
|
-
E(b, l,
|
|
11690
|
+
I++, !w && I < 10 ? setTimeout(function() {
|
|
11691
|
+
E(b, l, I);
|
|
11692
11692
|
}, 500) : l();
|
|
11693
11693
|
}
|
|
11694
11694
|
})(jQuery);
|
|
11695
11695
|
(function() {
|
|
11696
11696
|
window.HIPRINT_CONFIG = {
|
|
11697
|
-
version: "0.1.7-
|
|
11697
|
+
version: "0.1.7-beta5",
|
|
11698
11698
|
movingDistance: 1.5,
|
|
11699
11699
|
paperHeightTrim: 1,
|
|
11700
11700
|
showPosition: !0,
|