hlrender 0.0.188 → 0.0.199
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/FileSaver.min-b57403e6.js +103 -0
- package/{barcode-widget-1c352999.js → JsBarcode-e0a8837b.js} +760 -810
- package/{_pdf-b6d89756.js → _pdf-5693a3a5.js} +6 -6
- package/{_txt-ef25fa8a.js → _txt-cc9ff6a4.js} +6 -6
- package/{_unsupport-6bb1dc32.js → _unsupport-fec00214.js} +1 -1
- package/{slot-140ccbe1.js → acorn-a3705767.js} +835 -1104
- package/{affix-widget-0b74d368.js → affix-widget-e83690e6.js} +16 -16
- package/{alert-widget-8aef5ff3.js → alert-widget-6e4122a0.js} +16 -16
- package/{anchor-widget-9bae8353.js → anchor-widget-433cca12.js} +13 -13
- package/{auto-complete-widget-7e327986.js → auto-complete-widget-94f0bf82.js} +16 -16
- package/{avatar-widget-b0245c49.js → avatar-widget-0373b089.js} +16 -16
- package/{backtop-widget-be5390eb.js → backtop-widget-ee4874e4.js} +16 -16
- package/{badge-widget-90e6e302.js → badge-widget-56550313.js} +16 -16
- package/barcode-widget-3ac11e9e.js +79 -0
- package/baseImp-79376d04.js +11727 -0
- package/{breadcrumb-widget-b6cc077f.js → breadcrumb-widget-d6a3ea52.js} +13 -13
- package/browser-195dd18b.js +1486 -0
- package/{button-widget-ab8550bf.js → button-widget-aa311e6c.js} +16 -16
- package/{cache-widget-06c4c6a1.js → cache-widget-feac9f7d.js} +15 -15
- package/{card-widget-958d5ba7.js → card-widget-18cd6661.js} +14 -14
- package/{carousel-widget-dcbd6928.js → carousel-widget-0f89e75b.js} +14 -14
- package/{cascader-widget-8a597e5a.js → cascader-widget-bd8f686f.js} +15 -15
- package/{chart-widget-e824462a.js → chart-widget-df52a80e.js} +13 -13
- package/{checkbox-widget-0fb9b15c.js → checkbox-widget-49d4c657.js} +15 -15
- package/{collapse-widget-5dfffa1e.js → collapse-widget-b874885b.js} +14 -14
- package/{color-picker-widget-bc739cca.js → color-picker-widget-df3ff6db.js} +15 -15
- package/{cont-cell-widget-83ce16db.js → cont-cell-widget-159e50ef.js} +1 -1
- package/{cont-cell-widget.vue_vue_type_script_setup_true_name_cont-cell-widget_lang-968c8704.js → cont-cell-widget.vue_vue_type_script_setup_true_name_cont-cell-widget_lang-abcba0d4.js} +5 -5
- package/{cont-widget-95888af2.js → cont-widget-47e8d275.js} +5 -5
- package/{content-wrapper-19479765.js → content-wrapper-21a9e51b.js} +7 -7
- package/{content-wrapper.vue_vue_type_script_setup_true_lang-f191a101.js → content-wrapper.vue_vue_type_script_setup_true_lang-159b5487.js} +3 -3
- package/{date-picker-range-widget-d90a03c1.js → date-picker-range-widget-b05d4879.js} +15 -15
- package/{date-picker-widget-b359485e.js → date-picker-widget-f7bba7ad.js} +15 -15
- package/default-slot-widget-64643481.js +26 -0
- package/{default-slot-widget.vue_vue_type_script_setup_true_name_default-slot-widget_lang-0db55efe.js → default-slot-widget.vue_vue_type_script_setup_true_name_default-slot-widget_lang-8343af69.js} +7 -7
- package/{descriptions-widget-b58f145b.js → descriptions-widget-181e7daa.js} +14 -14
- package/{dialog-265a6e9e.js → dialog-0acb2540.js} +2 -2
- package/{dialog-widget-b4acb5ab.js → dialog-widget-1dd9299a.js} +15 -15
- package/{divider-widget-b498aa6d.js → divider-widget-6d4d7b57.js} +16 -16
- package/{drag-wrapper-c4f125d8.js → drag-wrapper-571e1bf5.js} +6 -6
- package/{drawer-widget-2b582946.js → drawer-widget-d8ac79e3.js} +15 -15
- package/{dropdown-widget-e303a1c8.js → dropdown-widget-06ab98de.js} +14 -14
- package/{empty-widget-11666b01.js → empty-widget-13baa871.js} +16 -16
- package/{enum-type-c44af727.js → enum-type-4aac0ead.js} +1 -1
- package/{enum-type-5eeafa5c.js → enum-type-523bc2b7.js} +1 -0
- package/{expression-d0123c5e.js → expression-8dec47fe.js} +2 -2
- package/feedback-widget-170e748c.js +26 -0
- package/{feedback-widget.vue_vue_type_script_setup_true_name_feedback-widget_lang-e319c24f.js → feedback-widget.vue_vue_type_script_setup_true_name_feedback-widget_lang-8af4ae9f.js} +5 -5
- package/{fieldobj-8b1bd2cd.js → fieldobj-b9dc0fa4.js} +1 -1
- package/{file-upload-widget-4be15b09.js → file-upload-widget-962de378.js} +20 -20
- package/{form-item-wrapper-bee9059a.js → form-item-wrapper-d3ad2de0.js} +11 -11
- package/{form-widget-abd5c0a8.js → form-widget-ef09a16a.js} +10 -10
- package/{grid-col-widget-bc5c7221.js → grid-col-widget-d4acebd9.js} +1 -1
- package/{grid-col-widget.vue_vue_type_script_setup_true_name_grid-col-widget_lang-0879986f.js → grid-col-widget.vue_vue_type_script_setup_true_name_grid-col-widget_lang-9f4143f4.js} +5 -5
- package/{grid-widget-62509704.js → grid-widget-59dc4c39.js} +5 -5
- package/{html-text-widget-0bdbd573.js → html-text-widget-3b6ee038.js} +14 -14
- package/{icon-widget-ec62f2d7.js → icon-widget-a66d9a02.js} +13 -13
- package/{iframe-widget-69e1cfc0.js → iframe-widget-c0fab6c8.js} +13 -13
- package/{image-widget-58f98209.js → image-widget-80426cea.js} +13 -13
- package/{index-1f875a7a.js → index-87d3b375.js} +466 -458
- package/{index-5a2da8b2.js → index-b82fc973.js} +1 -1
- package/{index-d7f361c6.js → index-c5927286.js} +4 -4
- package/{input-number-widget-0c99d6ce.js → input-number-widget-f44c8ebc.js} +15 -15
- package/{input-widget-9b476df3.js → input-widget-ace0300e.js} +26 -26
- package/{label-wrapper-ce4b9bdd.js → label-wrapper-b294182f.js} +5 -5
- package/{label-wrapper.vue_vue_type_style_index_0_lang-ca9edd3a.js → label-wrapper.vue_vue_type_style_index_0_lang-a68fc27e.js} +3 -3
- package/{link-widget-2f2b6b52.js → link-widget-ec449bd6.js} +16 -16
- package/{ltable-col-widget-ad03beff.js → ltable-col-widget-51e07713.js} +1 -1
- package/{ltable-col-widget.vue_vue_type_script_setup_true_name_ltable-col-widget_lang-714a8bbd.js → ltable-col-widget.vue_vue_type_script_setup_true_name_ltable-col-widget_lang-369d758f.js} +9 -9
- package/{ltable-widget-37047d58.js → ltable-widget-14580904.js} +5 -5
- package/menu-widget-efb62411.js +154 -0
- package/{model-widget-90c39c6a.js → model-widget-b8188485.js} +13 -13
- package/{multirow-a90a02fe.js → multirow-169e628f.js} +77 -77
- package/{multirow-widget-634a0d82.js → multirow-widget-fffaa309.js} +59 -59
- package/package.json +1 -1
- package/{pagination-widget-99bb260a.js → pagination-widget-749ab51c.js} +13 -13
- package/{picture-upload-widget-59ccd0ea.js → picture-upload-widget-870997b0.js} +16 -16
- package/{progress-widget-c33d7e61.js → progress-widget-0fdf11d5.js} +14 -14
- package/{propresult-9ceda396.js → propresult-10fa007b.js} +1 -1
- package/qrcode-widget-4f8af10a.js +69 -0
- package/{radio-widget-df1b657d.js → radio-widget-8693eb03.js} +15 -15
- package/{range-widget-335f0dd9.js → range-widget-6cf5b012.js} +16 -16
- package/{rate-widget-083c03c8.js → rate-widget-ae480517.js} +15 -15
- package/render.es.js +32 -32
- package/render.style.css +1 -1
- package/render.umd.js +621 -611
- package/{result-widget-1be3b291.js → result-widget-312936cf.js} +14 -14
- package/{rich-editor-widget-2b72cb03.js → rich-editor-widget-0b382b09.js} +15 -15
- package/{router-widget-9e4f59cd.js → router-widget-554e8fd9.js} +13 -13
- package/{select-widget-03f605b8.js → select-widget-53daaec3.js} +15 -15
- package/{sfc-a4a07b79.js → sfc-39e2a132.js} +10 -10
- package/{sfcview-e9165868.js → sfcview-d2924e26.js} +7 -7
- package/{share-field-05cfce0a.js → share-field-227e573a.js} +8 -8
- package/{share-file-94351ee0.js → share-file-97683189.js} +6 -6
- package/{slider-widget-033a247b.js → slider-widget-11f6773b.js} +15 -15
- package/slot-da3b397f.js +313 -0
- package/{static-text-widget-116b6909.js → static-text-widget-46f29a58.js} +14 -14
- package/{steps-widget-709a0c2a.js → steps-widget-c694f349.js} +13 -13
- package/{subMenu-widget-bba667f0.js → subMenu-widget-db1f3b9c.js} +8 -8
- package/subMenu-widget.vue_vue_type_script_setup_true_lang-02e8aaee.js +81 -0
- package/{switch-widget-c3a4c3c8.js → switch-widget-8f21f942.js} +15 -15
- package/{tab-pane-widget-c2b8bf3a.js → tab-pane-widget-c45db025.js} +1 -1
- package/{tab-pane-widget.vue_vue_type_script_setup_true_name_tab-pane-widget_lang-ae3d9295.js → tab-pane-widget.vue_vue_type_script_setup_true_name_tab-pane-widget_lang-0352bf40.js} +5 -5
- package/table-col-widget-4228d3c2.js +22 -0
- package/{table-col-widget.vue_vue_type_script_setup_true_name_table-col-widget_lang-ee3bb132.js → table-col-widget.vue_vue_type_script_setup_true_name_table-col-widget_lang-5623617e.js} +6 -6
- package/{table-widget-b1738910.js → table-widget-eac0c746.js} +15 -15
- package/{tabs-widget-dd5e607f.js → tabs-widget-1ddf6535.js} +7 -7
- package/{tag-widget-ee1c258e.js → tag-widget-33cde894.js} +16 -16
- package/{text-widget-c7447356.js → text-widget-eec191a3.js} +16 -16
- package/{textarea-widget-c6022f67.js → textarea-widget-617f4408.js} +15 -15
- package/{time-picker-range-widget-7bfa6157.js → time-picker-range-widget-f0fe2eea.js} +15 -15
- package/{time-picker-widget-cab8b63c.js → time-picker-widget-80a02857.js} +15 -15
- package/{time-select-widget-8a293fb1.js → time-select-widget-1c52c4ba.js} +15 -15
- package/{tmpl-widget-be8e304f.js → tmpl-widget-6a99246c.js} +14 -14
- package/{tree-select-widget-94a57892.js → tree-select-widget-ffee176b.js} +15 -15
- package/{tree-widget-18c5a5ac.js → tree-widget-3f55b5e2.js} +13 -13
- package/{uuid-f9e11f04.js → uuid-de039332.js} +1 -1
- package/{verifycode-widget-e5005804.js → verifycode-widget-fa1e1b23.js} +13 -13
- package/{widget-wrapper.vue_vue_type_script_setup_true_name_form-item-wrapper_lang-b949474e.js → widget-wrapper.vue_vue_type_script_setup_true_name_form-item-wrapper_lang-4c03293b.js} +7 -7
- package/{wrapper-widget-80383b71.js → wrapper-widget-b770069e.js} +6 -6
- package/xlsx-999c0f09.js +25068 -0
- package/baseImp-4ac8debd.js +0 -27791
- package/default-slot-widget-e3e37cf0.js +0 -26
- package/feedback-widget-7b634e31.js +0 -26
- package/menu-widget-a1b75613.js +0 -127
- package/qrcode-widget-c921c781.js +0 -1525
- package/subMenu-widget.vue_vue_type_script_setup_true_lang-11c27b67.js +0 -84
- package/table-col-widget-90ed2b0b.js +0 -22
|
@@ -1,42 +1,36 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
import "./slot-140ccbe1.js";
|
|
20
|
-
import "./index-5a2da8b2.js";
|
|
21
|
-
import "./_plugin-vue_export-helper-dad06003.js";
|
|
22
|
-
import "./fieldobj-8b1bd2cd.js";
|
|
23
|
-
var ge = {}, Z = {}, l = {};
|
|
24
|
-
Object.defineProperty(l, "__esModule", {
|
|
1
|
+
function jt(t, e) {
|
|
2
|
+
for (var r = 0; r < e.length; r++) {
|
|
3
|
+
const n = e[r];
|
|
4
|
+
if (typeof n != "string" && !Array.isArray(n)) {
|
|
5
|
+
for (const a in n)
|
|
6
|
+
if (a !== "default" && !(a in t)) {
|
|
7
|
+
const i = Object.getOwnPropertyDescriptor(n, a);
|
|
8
|
+
i && Object.defineProperty(t, a, i.get ? i : {
|
|
9
|
+
enumerable: !0,
|
|
10
|
+
get: () => n[a]
|
|
11
|
+
});
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
}
|
|
15
|
+
return Object.freeze(Object.defineProperty(t, Symbol.toStringTag, { value: "Module" }));
|
|
16
|
+
}
|
|
17
|
+
var ve = {}, J = {}, c = {};
|
|
18
|
+
Object.defineProperty(c, "__esModule", {
|
|
25
19
|
value: !0
|
|
26
20
|
});
|
|
27
|
-
function
|
|
21
|
+
function Bt(t, e) {
|
|
28
22
|
if (!(t instanceof e))
|
|
29
23
|
throw new TypeError("Cannot call a class as a function");
|
|
30
24
|
}
|
|
31
|
-
var
|
|
32
|
-
|
|
25
|
+
var Lt = function t(e, r) {
|
|
26
|
+
Bt(this, t), this.data = e, this.text = r.text || e, this.options = r;
|
|
33
27
|
};
|
|
34
|
-
|
|
35
|
-
Object.defineProperty(
|
|
28
|
+
c.default = Lt;
|
|
29
|
+
Object.defineProperty(J, "__esModule", {
|
|
36
30
|
value: !0
|
|
37
31
|
});
|
|
38
|
-
|
|
39
|
-
var
|
|
32
|
+
J.CODE39 = void 0;
|
|
33
|
+
var Ct = function() {
|
|
40
34
|
function t(e, r) {
|
|
41
35
|
for (var n = 0; n < r.length; n++) {
|
|
42
36
|
var a = r[n];
|
|
@@ -46,35 +40,35 @@ var en = function() {
|
|
|
46
40
|
return function(e, r, n) {
|
|
47
41
|
return r && t(e.prototype, r), n && t(e, n), e;
|
|
48
42
|
};
|
|
49
|
-
}(),
|
|
50
|
-
function
|
|
43
|
+
}(), Nt = c, Gt = Ft(Nt);
|
|
44
|
+
function Ft(t) {
|
|
51
45
|
return t && t.__esModule ? t : { default: t };
|
|
52
46
|
}
|
|
53
|
-
function
|
|
47
|
+
function Ht(t, e) {
|
|
54
48
|
if (!(t instanceof e))
|
|
55
49
|
throw new TypeError("Cannot call a class as a function");
|
|
56
50
|
}
|
|
57
|
-
function
|
|
51
|
+
function Xt(t, e) {
|
|
58
52
|
if (!t)
|
|
59
53
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
60
54
|
return e && (typeof e == "object" || typeof e == "function") ? e : t;
|
|
61
55
|
}
|
|
62
|
-
function
|
|
56
|
+
function zt(t, e) {
|
|
63
57
|
if (typeof e != "function" && e !== null)
|
|
64
58
|
throw new TypeError("Super expression must either be null or a function, not " + typeof e);
|
|
65
59
|
t.prototype = Object.create(e && e.prototype, { constructor: { value: t, enumerable: !1, writable: !0, configurable: !0 } }), e && (Object.setPrototypeOf ? Object.setPrototypeOf(t, e) : t.__proto__ = e);
|
|
66
60
|
}
|
|
67
|
-
var
|
|
68
|
-
|
|
61
|
+
var Ut = function(t) {
|
|
62
|
+
zt(e, t);
|
|
69
63
|
function e(r, n) {
|
|
70
|
-
return
|
|
64
|
+
return Ht(this, e), r = r.toUpperCase(), n.mod43 && (r += Jt(Yt(r))), Xt(this, (e.__proto__ || Object.getPrototypeOf(e)).call(this, r, n));
|
|
71
65
|
}
|
|
72
|
-
return
|
|
66
|
+
return Ct(e, [{
|
|
73
67
|
key: "encode",
|
|
74
68
|
value: function() {
|
|
75
|
-
for (var n =
|
|
76
|
-
n +=
|
|
77
|
-
return n +=
|
|
69
|
+
for (var n = ie("*"), a = 0; a < this.data.length; a++)
|
|
70
|
+
n += ie(this.data[a]) + "0";
|
|
71
|
+
return n += ie("*"), {
|
|
78
72
|
data: n,
|
|
79
73
|
text: this.text
|
|
80
74
|
};
|
|
@@ -85,44 +79,44 @@ var fn = function(t) {
|
|
|
85
79
|
return this.data.search(/^[0-9A-Z\-\.\ \$\/\+\%]+$/) !== -1;
|
|
86
80
|
}
|
|
87
81
|
}]), e;
|
|
88
|
-
}(
|
|
89
|
-
function
|
|
90
|
-
return
|
|
82
|
+
}(Gt.default), ft = ["0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "A", "B", "C", "D", "E", "F", "G", "H", "I", "J", "K", "L", "M", "N", "O", "P", "Q", "R", "S", "T", "U", "V", "W", "X", "Y", "Z", "-", ".", " ", "$", "/", "+", "%", "*"], Vt = [20957, 29783, 23639, 30485, 20951, 29813, 23669, 20855, 29789, 23645, 29975, 23831, 30533, 22295, 30149, 24005, 21623, 29981, 23837, 22301, 30023, 23879, 30545, 22343, 30161, 24017, 21959, 30065, 23921, 22385, 29015, 18263, 29141, 17879, 29045, 18293, 17783, 29021, 18269, 17477, 17489, 17681, 20753, 35770];
|
|
83
|
+
function ie(t) {
|
|
84
|
+
return qt(ct(t));
|
|
91
85
|
}
|
|
92
|
-
function
|
|
93
|
-
return
|
|
86
|
+
function qt(t) {
|
|
87
|
+
return Vt[t].toString(2);
|
|
94
88
|
}
|
|
95
|
-
function
|
|
96
|
-
return
|
|
89
|
+
function Jt(t) {
|
|
90
|
+
return ft[t];
|
|
97
91
|
}
|
|
98
|
-
function
|
|
99
|
-
return
|
|
92
|
+
function ct(t) {
|
|
93
|
+
return ft.indexOf(t);
|
|
100
94
|
}
|
|
101
|
-
function
|
|
95
|
+
function Yt(t) {
|
|
102
96
|
for (var e = 0, r = 0; r < t.length; r++)
|
|
103
|
-
e +=
|
|
97
|
+
e += ct(t[r]);
|
|
104
98
|
return e = e % 43, e;
|
|
105
99
|
}
|
|
106
|
-
|
|
107
|
-
var
|
|
100
|
+
J.CODE39 = Ut;
|
|
101
|
+
var s = {}, ye = {}, T = {}, f = {};
|
|
108
102
|
Object.defineProperty(f, "__esModule", {
|
|
109
103
|
value: !0
|
|
110
104
|
});
|
|
111
|
-
var
|
|
112
|
-
function
|
|
105
|
+
var D;
|
|
106
|
+
function oe(t, e, r) {
|
|
113
107
|
return e in t ? Object.defineProperty(t, e, { value: r, enumerable: !0, configurable: !0, writable: !0 }) : t[e] = r, t;
|
|
114
108
|
}
|
|
115
|
-
var
|
|
109
|
+
var lt = f.SET_A = 0, ht = f.SET_B = 1, dt = f.SET_C = 2;
|
|
116
110
|
f.SHIFT = 98;
|
|
117
|
-
var
|
|
111
|
+
var Qt = f.START_A = 103, Wt = f.START_B = 104, Zt = f.START_C = 105;
|
|
118
112
|
f.MODULO = 103;
|
|
119
113
|
f.STOP = 106;
|
|
120
114
|
f.FNC1 = 207;
|
|
121
|
-
f.SET_BY_CODE = (
|
|
115
|
+
f.SET_BY_CODE = (D = {}, oe(D, Qt, lt), oe(D, Wt, ht), oe(D, Zt, dt), D);
|
|
122
116
|
f.SWAP = {
|
|
123
|
-
101:
|
|
124
|
-
100:
|
|
125
|
-
99:
|
|
117
|
+
101: lt,
|
|
118
|
+
100: ht,
|
|
119
|
+
99: dt
|
|
126
120
|
};
|
|
127
121
|
f.A_START_CHAR = String.fromCharCode(208);
|
|
128
122
|
f.B_START_CHAR = String.fromCharCode(209);
|
|
@@ -131,10 +125,10 @@ f.A_CHARS = "[\0-_È-Ï]";
|
|
|
131
125
|
f.B_CHARS = "[ -È-Ï]";
|
|
132
126
|
f.C_CHARS = "(Ï*[0-9]{2}Ï*)";
|
|
133
127
|
f.BARS = [11011001100, 11001101100, 11001100110, 10010011e3, 10010001100, 10001001100, 10011001e3, 10011000100, 10001100100, 11001001e3, 11001000100, 11000100100, 10110011100, 10011011100, 10011001110, 10111001100, 10011101100, 10011100110, 11001110010, 11001011100, 11001001110, 11011100100, 11001110100, 11101101110, 11101001100, 11100101100, 11100100110, 11101100100, 11100110100, 11100110010, 11011011e3, 11011000110, 11000110110, 10100011e3, 10001011e3, 10001000110, 10110001e3, 10001101e3, 10001100010, 11010001e3, 11000101e3, 11000100010, 10110111e3, 10110001110, 10001101110, 10111011e3, 10111000110, 10001110110, 11101110110, 11010001110, 11000101110, 11011101e3, 11011100010, 11011101110, 11101011e3, 11101000110, 11100010110, 11101101e3, 11101100010, 11100011010, 11101111010, 11001000010, 11110001010, 1010011e4, 10100001100, 1001011e4, 10010000110, 10000101100, 10000100110, 1011001e4, 10110000100, 1001101e4, 10011000010, 10000110100, 10000110010, 11000010010, 1100101e4, 11110111010, 11000010100, 10001111010, 10100111100, 10010111100, 10010011110, 10111100100, 10011110100, 10011110010, 11110100100, 11110010100, 11110010010, 11011011110, 11011110110, 11110110110, 10101111e3, 10100011110, 10001011110, 10111101e3, 10111100010, 11110101e3, 11110100010, 10111011110, 10111101110, 11101011110, 11110101110, 11010000100, 1101001e4, 11010011100, 1100011101011];
|
|
134
|
-
Object.defineProperty(
|
|
128
|
+
Object.defineProperty(T, "__esModule", {
|
|
135
129
|
value: !0
|
|
136
130
|
});
|
|
137
|
-
var
|
|
131
|
+
var Kt = function() {
|
|
138
132
|
function t(e, r) {
|
|
139
133
|
for (var n = 0; n < r.length; n++) {
|
|
140
134
|
var a = r[n];
|
|
@@ -144,34 +138,34 @@ var yn = function() {
|
|
|
144
138
|
return function(e, r, n) {
|
|
145
139
|
return r && t(e.prototype, r), n && t(e, n), e;
|
|
146
140
|
};
|
|
147
|
-
}(),
|
|
148
|
-
function
|
|
141
|
+
}(), en = c, tn = nn(en), h = f;
|
|
142
|
+
function nn(t) {
|
|
149
143
|
return t && t.__esModule ? t : { default: t };
|
|
150
144
|
}
|
|
151
|
-
function
|
|
145
|
+
function rn(t, e) {
|
|
152
146
|
if (!(t instanceof e))
|
|
153
147
|
throw new TypeError("Cannot call a class as a function");
|
|
154
148
|
}
|
|
155
|
-
function
|
|
149
|
+
function an(t, e) {
|
|
156
150
|
if (!t)
|
|
157
151
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
158
152
|
return e && (typeof e == "object" || typeof e == "function") ? e : t;
|
|
159
153
|
}
|
|
160
|
-
function
|
|
154
|
+
function on(t, e) {
|
|
161
155
|
if (typeof e != "function" && e !== null)
|
|
162
156
|
throw new TypeError("Super expression must either be null or a function, not " + typeof e);
|
|
163
157
|
t.prototype = Object.create(e && e.prototype, { constructor: { value: t, enumerable: !1, writable: !0, configurable: !0 } }), e && (Object.setPrototypeOf ? Object.setPrototypeOf(t, e) : t.__proto__ = e);
|
|
164
158
|
}
|
|
165
|
-
var
|
|
166
|
-
|
|
159
|
+
var un = function(t) {
|
|
160
|
+
on(e, t);
|
|
167
161
|
function e(r, n) {
|
|
168
|
-
|
|
169
|
-
var a =
|
|
162
|
+
rn(this, e);
|
|
163
|
+
var a = an(this, (e.__proto__ || Object.getPrototypeOf(e)).call(this, r.substring(1), n));
|
|
170
164
|
return a.bytes = r.split("").map(function(i) {
|
|
171
165
|
return i.charCodeAt(0);
|
|
172
166
|
}), a;
|
|
173
167
|
}
|
|
174
|
-
return
|
|
168
|
+
return Kt(e, [{
|
|
175
169
|
key: "valid",
|
|
176
170
|
value: function() {
|
|
177
171
|
return /^[\x00-\x7F\xC8-\xD3]+$/.test(this.data);
|
|
@@ -180,10 +174,10 @@ var wn = function(t) {
|
|
|
180
174
|
}, {
|
|
181
175
|
key: "encode",
|
|
182
176
|
value: function() {
|
|
183
|
-
var n = this.bytes, a = n.shift() - 105, i =
|
|
177
|
+
var n = this.bytes, a = n.shift() - 105, i = h.SET_BY_CODE[a];
|
|
184
178
|
if (i === void 0)
|
|
185
179
|
throw new RangeError("The encoding does not start with a start character.");
|
|
186
|
-
this.shouldEncodeAsEan128() === !0 && n.unshift(
|
|
180
|
+
this.shouldEncodeAsEan128() === !0 && n.unshift(h.FNC1);
|
|
187
181
|
var o = e.next(n, 1, i);
|
|
188
182
|
return {
|
|
189
183
|
text: this.text === this.data ? this.text.replace(/[^\x20-\x7E]/g, "") : this.text,
|
|
@@ -191,8 +185,8 @@ var wn = function(t) {
|
|
|
191
185
|
// Add the start bits
|
|
192
186
|
e.getBar(a) + // Add the encoded bits
|
|
193
187
|
o.result + // Add the checksum
|
|
194
|
-
e.getBar((o.checksum + a) %
|
|
195
|
-
e.getBar(
|
|
188
|
+
e.getBar((o.checksum + a) % h.MODULO) + // Add the end bits
|
|
189
|
+
e.getBar(h.STOP)
|
|
196
190
|
)
|
|
197
191
|
};
|
|
198
192
|
}
|
|
@@ -207,17 +201,17 @@ var wn = function(t) {
|
|
|
207
201
|
}], [{
|
|
208
202
|
key: "getBar",
|
|
209
203
|
value: function(n) {
|
|
210
|
-
return
|
|
204
|
+
return h.BARS[n] ? h.BARS[n].toString() : "";
|
|
211
205
|
}
|
|
212
206
|
// Correct an index by a set and shift it from the bytes array
|
|
213
207
|
}, {
|
|
214
208
|
key: "correctIndex",
|
|
215
209
|
value: function(n, a) {
|
|
216
|
-
if (a ===
|
|
210
|
+
if (a === h.SET_A) {
|
|
217
211
|
var i = n.shift();
|
|
218
212
|
return i < 32 ? i + 64 : i - 32;
|
|
219
213
|
} else
|
|
220
|
-
return a ===
|
|
214
|
+
return a === h.SET_B ? n.shift() - 32 : (n.shift() - 48) * 10 + n.shift() - 48;
|
|
221
215
|
}
|
|
222
216
|
}, {
|
|
223
217
|
key: "next",
|
|
@@ -227,52 +221,52 @@ var wn = function(t) {
|
|
|
227
221
|
var o = void 0, u = void 0;
|
|
228
222
|
if (n[0] >= 200) {
|
|
229
223
|
u = n.shift() - 105;
|
|
230
|
-
var
|
|
231
|
-
|
|
224
|
+
var y = h.SWAP[u];
|
|
225
|
+
y !== void 0 ? o = e.next(n, a + 1, y) : ((i === h.SET_A || i === h.SET_B) && u === h.SHIFT && (n[0] = i === h.SET_A ? n[0] > 95 ? n[0] - 96 : n[0] : n[0] < 32 ? n[0] + 96 : n[0]), o = e.next(n, a + 1, i));
|
|
232
226
|
} else
|
|
233
227
|
u = e.correctIndex(n, i), o = e.next(n, a + 1, i);
|
|
234
|
-
var
|
|
228
|
+
var g = e.getBar(u), Dt = u * a;
|
|
235
229
|
return {
|
|
236
|
-
result:
|
|
237
|
-
checksum:
|
|
230
|
+
result: g + o.result,
|
|
231
|
+
checksum: Dt + o.checksum
|
|
238
232
|
};
|
|
239
233
|
}
|
|
240
234
|
}]), e;
|
|
241
|
-
}(
|
|
242
|
-
|
|
243
|
-
var
|
|
244
|
-
Object.defineProperty(
|
|
235
|
+
}(tn.default);
|
|
236
|
+
T.default = un;
|
|
237
|
+
var se = {};
|
|
238
|
+
Object.defineProperty(se, "__esModule", {
|
|
245
239
|
value: !0
|
|
246
240
|
});
|
|
247
|
-
var O = f,
|
|
241
|
+
var O = f, _t = function(e) {
|
|
248
242
|
return e.match(new RegExp("^" + O.A_CHARS + "*"))[0].length;
|
|
249
|
-
},
|
|
243
|
+
}, vt = function(e) {
|
|
250
244
|
return e.match(new RegExp("^" + O.B_CHARS + "*"))[0].length;
|
|
251
|
-
},
|
|
245
|
+
}, yt = function(e) {
|
|
252
246
|
return e.match(new RegExp("^" + O.C_CHARS + "*"))[0];
|
|
253
247
|
};
|
|
254
|
-
function
|
|
248
|
+
function pe(t, e) {
|
|
255
249
|
var r = e ? O.A_CHARS : O.B_CHARS, n = t.match(new RegExp("^(" + r + "+?)(([0-9]{2}){2,})([^0-9]|$)"));
|
|
256
250
|
if (n)
|
|
257
|
-
return n[1] + String.fromCharCode(204) +
|
|
251
|
+
return n[1] + String.fromCharCode(204) + st(t.substring(n[1].length));
|
|
258
252
|
var a = t.match(new RegExp("^" + r + "+"))[0];
|
|
259
|
-
return a.length === t.length ? t : a + String.fromCharCode(e ? 205 : 206) +
|
|
253
|
+
return a.length === t.length ? t : a + String.fromCharCode(e ? 205 : 206) + pe(t.substring(a.length), !e);
|
|
260
254
|
}
|
|
261
|
-
function
|
|
262
|
-
var e =
|
|
255
|
+
function st(t) {
|
|
256
|
+
var e = yt(t), r = e.length;
|
|
263
257
|
if (r === t.length)
|
|
264
258
|
return t;
|
|
265
259
|
t = t.substring(r);
|
|
266
|
-
var n =
|
|
267
|
-
return e + String.fromCharCode(n ? 206 : 205) +
|
|
260
|
+
var n = _t(t) >= vt(t);
|
|
261
|
+
return e + String.fromCharCode(n ? 206 : 205) + pe(t, n);
|
|
268
262
|
}
|
|
269
|
-
|
|
270
|
-
var e = void 0, r =
|
|
263
|
+
se.default = function(t) {
|
|
264
|
+
var e = void 0, r = yt(t).length;
|
|
271
265
|
if (r >= 2)
|
|
272
|
-
e = O.C_START_CHAR +
|
|
266
|
+
e = O.C_START_CHAR + st(t);
|
|
273
267
|
else {
|
|
274
|
-
var n =
|
|
275
|
-
e = (n ? O.A_START_CHAR : O.B_START_CHAR) +
|
|
268
|
+
var n = _t(t) > vt(t);
|
|
269
|
+
e = (n ? O.A_START_CHAR : O.B_START_CHAR) + pe(t, n);
|
|
276
270
|
}
|
|
277
271
|
return e.replace(
|
|
278
272
|
/[\xCD\xCE]([^])[\xCD\xCE]/,
|
|
@@ -282,44 +276,44 @@ Ee.default = function(t) {
|
|
|
282
276
|
}
|
|
283
277
|
);
|
|
284
278
|
};
|
|
285
|
-
Object.defineProperty(
|
|
279
|
+
Object.defineProperty(ye, "__esModule", {
|
|
286
280
|
value: !0
|
|
287
281
|
});
|
|
288
|
-
var
|
|
289
|
-
function
|
|
282
|
+
var fn = T, cn = pt(fn), ln = se, hn = pt(ln);
|
|
283
|
+
function pt(t) {
|
|
290
284
|
return t && t.__esModule ? t : { default: t };
|
|
291
285
|
}
|
|
292
|
-
function
|
|
286
|
+
function dn(t, e) {
|
|
293
287
|
if (!(t instanceof e))
|
|
294
288
|
throw new TypeError("Cannot call a class as a function");
|
|
295
289
|
}
|
|
296
|
-
function
|
|
290
|
+
function ue(t, e) {
|
|
297
291
|
if (!t)
|
|
298
292
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
299
293
|
return e && (typeof e == "object" || typeof e == "function") ? e : t;
|
|
300
294
|
}
|
|
301
|
-
function
|
|
295
|
+
function _n(t, e) {
|
|
302
296
|
if (typeof e != "function" && e !== null)
|
|
303
297
|
throw new TypeError("Super expression must either be null or a function, not " + typeof e);
|
|
304
298
|
t.prototype = Object.create(e && e.prototype, { constructor: { value: t, enumerable: !1, writable: !0, configurable: !0 } }), e && (Object.setPrototypeOf ? Object.setPrototypeOf(t, e) : t.__proto__ = e);
|
|
305
299
|
}
|
|
306
|
-
var
|
|
307
|
-
|
|
300
|
+
var vn = function(t) {
|
|
301
|
+
_n(e, t);
|
|
308
302
|
function e(r, n) {
|
|
309
|
-
if (
|
|
310
|
-
var a =
|
|
303
|
+
if (dn(this, e), /^[\x00-\x7F\xC8-\xD3]+$/.test(r))
|
|
304
|
+
var a = ue(this, (e.__proto__ || Object.getPrototypeOf(e)).call(this, (0, hn.default)(r), n));
|
|
311
305
|
else
|
|
312
|
-
var a =
|
|
313
|
-
return
|
|
306
|
+
var a = ue(this, (e.__proto__ || Object.getPrototypeOf(e)).call(this, r, n));
|
|
307
|
+
return ue(a);
|
|
314
308
|
}
|
|
315
309
|
return e;
|
|
316
|
-
}(
|
|
317
|
-
|
|
318
|
-
var
|
|
319
|
-
Object.defineProperty(
|
|
310
|
+
}(cn.default);
|
|
311
|
+
ye.default = vn;
|
|
312
|
+
var ge = {};
|
|
313
|
+
Object.defineProperty(ge, "__esModule", {
|
|
320
314
|
value: !0
|
|
321
315
|
});
|
|
322
|
-
var
|
|
316
|
+
var yn = function() {
|
|
323
317
|
function t(e, r) {
|
|
324
318
|
for (var n = 0; n < r.length; n++) {
|
|
325
319
|
var a = r[n];
|
|
@@ -329,42 +323,42 @@ var Mn = function() {
|
|
|
329
323
|
return function(e, r, n) {
|
|
330
324
|
return r && t(e.prototype, r), n && t(e, n), e;
|
|
331
325
|
};
|
|
332
|
-
}(),
|
|
333
|
-
function
|
|
326
|
+
}(), sn = T, pn = gn(sn), Ve = f;
|
|
327
|
+
function gn(t) {
|
|
334
328
|
return t && t.__esModule ? t : { default: t };
|
|
335
329
|
}
|
|
336
|
-
function
|
|
330
|
+
function On(t, e) {
|
|
337
331
|
if (!(t instanceof e))
|
|
338
332
|
throw new TypeError("Cannot call a class as a function");
|
|
339
333
|
}
|
|
340
|
-
function
|
|
334
|
+
function En(t, e) {
|
|
341
335
|
if (!t)
|
|
342
336
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
343
337
|
return e && (typeof e == "object" || typeof e == "function") ? e : t;
|
|
344
338
|
}
|
|
345
|
-
function
|
|
339
|
+
function bn(t, e) {
|
|
346
340
|
if (typeof e != "function" && e !== null)
|
|
347
341
|
throw new TypeError("Super expression must either be null or a function, not " + typeof e);
|
|
348
342
|
t.prototype = Object.create(e && e.prototype, { constructor: { value: t, enumerable: !1, writable: !0, configurable: !0 } }), e && (Object.setPrototypeOf ? Object.setPrototypeOf(t, e) : t.__proto__ = e);
|
|
349
343
|
}
|
|
350
|
-
var
|
|
351
|
-
|
|
344
|
+
var wn = function(t) {
|
|
345
|
+
bn(e, t);
|
|
352
346
|
function e(r, n) {
|
|
353
|
-
return
|
|
347
|
+
return On(this, e), En(this, (e.__proto__ || Object.getPrototypeOf(e)).call(this, Ve.A_START_CHAR + r, n));
|
|
354
348
|
}
|
|
355
|
-
return
|
|
349
|
+
return yn(e, [{
|
|
356
350
|
key: "valid",
|
|
357
351
|
value: function() {
|
|
358
|
-
return new RegExp("^" +
|
|
352
|
+
return new RegExp("^" + Ve.A_CHARS + "+$").test(this.data);
|
|
359
353
|
}
|
|
360
354
|
}]), e;
|
|
361
|
-
}(
|
|
362
|
-
|
|
363
|
-
var
|
|
364
|
-
Object.defineProperty(
|
|
355
|
+
}(pn.default);
|
|
356
|
+
ge.default = wn;
|
|
357
|
+
var Oe = {};
|
|
358
|
+
Object.defineProperty(Oe, "__esModule", {
|
|
365
359
|
value: !0
|
|
366
360
|
});
|
|
367
|
-
var
|
|
361
|
+
var mn = function() {
|
|
368
362
|
function t(e, r) {
|
|
369
363
|
for (var n = 0; n < r.length; n++) {
|
|
370
364
|
var a = r[n];
|
|
@@ -374,42 +368,42 @@ var Nn = function() {
|
|
|
374
368
|
return function(e, r, n) {
|
|
375
369
|
return r && t(e.prototype, r), n && t(e, n), e;
|
|
376
370
|
};
|
|
377
|
-
}(),
|
|
378
|
-
function
|
|
371
|
+
}(), $n = T, xn = Sn($n), qe = f;
|
|
372
|
+
function Sn(t) {
|
|
379
373
|
return t && t.__esModule ? t : { default: t };
|
|
380
374
|
}
|
|
381
|
-
function
|
|
375
|
+
function An(t, e) {
|
|
382
376
|
if (!(t instanceof e))
|
|
383
377
|
throw new TypeError("Cannot call a class as a function");
|
|
384
378
|
}
|
|
385
|
-
function
|
|
379
|
+
function Rn(t, e) {
|
|
386
380
|
if (!t)
|
|
387
381
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
388
382
|
return e && (typeof e == "object" || typeof e == "function") ? e : t;
|
|
389
383
|
}
|
|
390
|
-
function
|
|
384
|
+
function Pn(t, e) {
|
|
391
385
|
if (typeof e != "function" && e !== null)
|
|
392
386
|
throw new TypeError("Super expression must either be null or a function, not " + typeof e);
|
|
393
387
|
t.prototype = Object.create(e && e.prototype, { constructor: { value: t, enumerable: !1, writable: !0, configurable: !0 } }), e && (Object.setPrototypeOf ? Object.setPrototypeOf(t, e) : t.__proto__ = e);
|
|
394
388
|
}
|
|
395
|
-
var
|
|
396
|
-
|
|
389
|
+
var Tn = function(t) {
|
|
390
|
+
Pn(e, t);
|
|
397
391
|
function e(r, n) {
|
|
398
|
-
return
|
|
392
|
+
return An(this, e), Rn(this, (e.__proto__ || Object.getPrototypeOf(e)).call(this, qe.B_START_CHAR + r, n));
|
|
399
393
|
}
|
|
400
|
-
return
|
|
394
|
+
return mn(e, [{
|
|
401
395
|
key: "valid",
|
|
402
396
|
value: function() {
|
|
403
|
-
return new RegExp("^" +
|
|
397
|
+
return new RegExp("^" + qe.B_CHARS + "+$").test(this.data);
|
|
404
398
|
}
|
|
405
399
|
}]), e;
|
|
406
|
-
}(
|
|
407
|
-
|
|
408
|
-
var
|
|
409
|
-
Object.defineProperty(
|
|
400
|
+
}(xn.default);
|
|
401
|
+
Oe.default = Tn;
|
|
402
|
+
var Ee = {};
|
|
403
|
+
Object.defineProperty(Ee, "__esModule", {
|
|
410
404
|
value: !0
|
|
411
405
|
});
|
|
412
|
-
var
|
|
406
|
+
var Mn = function() {
|
|
413
407
|
function t(e, r) {
|
|
414
408
|
for (var n = 0; n < r.length; n++) {
|
|
415
409
|
var a = r[n];
|
|
@@ -419,56 +413,56 @@ var qn = function() {
|
|
|
419
413
|
return function(e, r, n) {
|
|
420
414
|
return r && t(e.prototype, r), n && t(e, n), e;
|
|
421
415
|
};
|
|
422
|
-
}(),
|
|
423
|
-
function
|
|
416
|
+
}(), In = T, kn = Dn(In), Je = f;
|
|
417
|
+
function Dn(t) {
|
|
424
418
|
return t && t.__esModule ? t : { default: t };
|
|
425
419
|
}
|
|
426
|
-
function
|
|
420
|
+
function jn(t, e) {
|
|
427
421
|
if (!(t instanceof e))
|
|
428
422
|
throw new TypeError("Cannot call a class as a function");
|
|
429
423
|
}
|
|
430
|
-
function
|
|
424
|
+
function Bn(t, e) {
|
|
431
425
|
if (!t)
|
|
432
426
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
433
427
|
return e && (typeof e == "object" || typeof e == "function") ? e : t;
|
|
434
428
|
}
|
|
435
|
-
function
|
|
429
|
+
function Ln(t, e) {
|
|
436
430
|
if (typeof e != "function" && e !== null)
|
|
437
431
|
throw new TypeError("Super expression must either be null or a function, not " + typeof e);
|
|
438
432
|
t.prototype = Object.create(e && e.prototype, { constructor: { value: t, enumerable: !1, writable: !0, configurable: !0 } }), e && (Object.setPrototypeOf ? Object.setPrototypeOf(t, e) : t.__proto__ = e);
|
|
439
433
|
}
|
|
440
|
-
var
|
|
441
|
-
|
|
434
|
+
var Cn = function(t) {
|
|
435
|
+
Ln(e, t);
|
|
442
436
|
function e(r, n) {
|
|
443
|
-
return
|
|
437
|
+
return jn(this, e), Bn(this, (e.__proto__ || Object.getPrototypeOf(e)).call(this, Je.C_START_CHAR + r, n));
|
|
444
438
|
}
|
|
445
|
-
return
|
|
439
|
+
return Mn(e, [{
|
|
446
440
|
key: "valid",
|
|
447
441
|
value: function() {
|
|
448
|
-
return new RegExp("^" +
|
|
442
|
+
return new RegExp("^" + Je.C_CHARS + "+$").test(this.data);
|
|
449
443
|
}
|
|
450
444
|
}]), e;
|
|
451
|
-
}(
|
|
452
|
-
|
|
453
|
-
Object.defineProperty(
|
|
445
|
+
}(kn.default);
|
|
446
|
+
Ee.default = Cn;
|
|
447
|
+
Object.defineProperty(s, "__esModule", {
|
|
454
448
|
value: !0
|
|
455
449
|
});
|
|
456
|
-
|
|
457
|
-
var
|
|
458
|
-
function
|
|
450
|
+
s.CODE128C = s.CODE128B = s.CODE128A = s.CODE128 = void 0;
|
|
451
|
+
var Nn = ye, Gn = Y(Nn), Fn = ge, Hn = Y(Fn), Xn = Oe, zn = Y(Xn), Un = Ee, Vn = Y(Un);
|
|
452
|
+
function Y(t) {
|
|
459
453
|
return t && t.__esModule ? t : { default: t };
|
|
460
454
|
}
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
var
|
|
466
|
-
Object.defineProperty(
|
|
455
|
+
s.CODE128 = Gn.default;
|
|
456
|
+
s.CODE128A = Hn.default;
|
|
457
|
+
s.CODE128B = zn.default;
|
|
458
|
+
s.CODE128C = Vn.default;
|
|
459
|
+
var l = {}, be = {}, v = {};
|
|
460
|
+
Object.defineProperty(v, "__esModule", {
|
|
467
461
|
value: !0
|
|
468
462
|
});
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
463
|
+
v.SIDE_BIN = "101";
|
|
464
|
+
v.MIDDLE_BIN = "01010";
|
|
465
|
+
v.BINARIES = {
|
|
472
466
|
L: [
|
|
473
467
|
// The L (left) type of encoding
|
|
474
468
|
"0001101",
|
|
@@ -535,16 +529,16 @@ y.BINARIES = {
|
|
|
535
529
|
"0010111"
|
|
536
530
|
]
|
|
537
531
|
};
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
var
|
|
532
|
+
v.EAN2_STRUCTURE = ["LL", "LG", "GL", "GG"];
|
|
533
|
+
v.EAN5_STRUCTURE = ["GGLLL", "GLGLL", "GLLGL", "GLLLG", "LGGLL", "LLGGL", "LLLGG", "LGLGL", "LGLLG", "LLGLG"];
|
|
534
|
+
v.EAN13_STRUCTURE = ["LLLLLL", "LLGLGG", "LLGGLG", "LLGGGL", "LGLLGG", "LGGLLG", "LGGGLL", "LGLGLG", "LGLGGL", "LGGLGL"];
|
|
535
|
+
var Q = {}, w = {};
|
|
542
536
|
Object.defineProperty(w, "__esModule", {
|
|
543
537
|
value: !0
|
|
544
538
|
});
|
|
545
|
-
var
|
|
539
|
+
var qn = v, Jn = function(e, r, n) {
|
|
546
540
|
var a = e.split("").map(function(o, u) {
|
|
547
|
-
return
|
|
541
|
+
return qn.BINARIES[r[u]];
|
|
548
542
|
}).map(function(o, u) {
|
|
549
543
|
return o ? o[e[u]] : "";
|
|
550
544
|
});
|
|
@@ -556,11 +550,11 @@ var cr = y, lr = function(e, r, n) {
|
|
|
556
550
|
}
|
|
557
551
|
return a.join("");
|
|
558
552
|
};
|
|
559
|
-
w.default =
|
|
560
|
-
Object.defineProperty(
|
|
553
|
+
w.default = Jn;
|
|
554
|
+
Object.defineProperty(Q, "__esModule", {
|
|
561
555
|
value: !0
|
|
562
556
|
});
|
|
563
|
-
var
|
|
557
|
+
var Yn = function() {
|
|
564
558
|
function t(e, r) {
|
|
565
559
|
for (var n = 0; n < r.length; n++) {
|
|
566
560
|
var a = r[n];
|
|
@@ -570,32 +564,32 @@ var hr = function() {
|
|
|
570
564
|
return function(e, r, n) {
|
|
571
565
|
return r && t(e.prototype, r), n && t(e, n), e;
|
|
572
566
|
};
|
|
573
|
-
}(),
|
|
574
|
-
function
|
|
567
|
+
}(), x = v, Qn = w, Ye = gt(Qn), Wn = c, Zn = gt(Wn);
|
|
568
|
+
function gt(t) {
|
|
575
569
|
return t && t.__esModule ? t : { default: t };
|
|
576
570
|
}
|
|
577
|
-
function
|
|
571
|
+
function Kn(t, e) {
|
|
578
572
|
if (!(t instanceof e))
|
|
579
573
|
throw new TypeError("Cannot call a class as a function");
|
|
580
574
|
}
|
|
581
|
-
function
|
|
575
|
+
function er(t, e) {
|
|
582
576
|
if (!t)
|
|
583
577
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
584
578
|
return e && (typeof e == "object" || typeof e == "function") ? e : t;
|
|
585
579
|
}
|
|
586
|
-
function
|
|
580
|
+
function tr(t, e) {
|
|
587
581
|
if (typeof e != "function" && e !== null)
|
|
588
582
|
throw new TypeError("Super expression must either be null or a function, not " + typeof e);
|
|
589
583
|
t.prototype = Object.create(e && e.prototype, { constructor: { value: t, enumerable: !1, writable: !0, configurable: !0 } }), e && (Object.setPrototypeOf ? Object.setPrototypeOf(t, e) : t.__proto__ = e);
|
|
590
584
|
}
|
|
591
|
-
var
|
|
592
|
-
|
|
585
|
+
var nr = function(t) {
|
|
586
|
+
tr(e, t);
|
|
593
587
|
function e(r, n) {
|
|
594
|
-
|
|
595
|
-
var a =
|
|
588
|
+
Kn(this, e);
|
|
589
|
+
var a = er(this, (e.__proto__ || Object.getPrototypeOf(e)).call(this, r, n));
|
|
596
590
|
return a.fontSize = !n.flat && n.fontSize > n.width * 10 ? n.width * 10 : n.fontSize, a.guardHeight = n.height + a.fontSize / 2 + n.textMargin, a;
|
|
597
591
|
}
|
|
598
|
-
return
|
|
592
|
+
return Yn(e, [{
|
|
599
593
|
key: "encode",
|
|
600
594
|
value: function() {
|
|
601
595
|
return this.options.flat ? this.encodeFlat() : this.encodeGuarded();
|
|
@@ -608,7 +602,7 @@ var gr = function(t) {
|
|
|
608
602
|
}, {
|
|
609
603
|
key: "leftEncode",
|
|
610
604
|
value: function(n, a) {
|
|
611
|
-
return (0,
|
|
605
|
+
return (0, Ye.default)(n, a);
|
|
612
606
|
}
|
|
613
607
|
}, {
|
|
614
608
|
key: "rightText",
|
|
@@ -618,30 +612,30 @@ var gr = function(t) {
|
|
|
618
612
|
}, {
|
|
619
613
|
key: "rightEncode",
|
|
620
614
|
value: function(n, a) {
|
|
621
|
-
return (0,
|
|
615
|
+
return (0, Ye.default)(n, a);
|
|
622
616
|
}
|
|
623
617
|
}, {
|
|
624
618
|
key: "encodeGuarded",
|
|
625
619
|
value: function() {
|
|
626
620
|
var n = { fontSize: this.fontSize }, a = { height: this.guardHeight };
|
|
627
|
-
return [{ data:
|
|
621
|
+
return [{ data: x.SIDE_BIN, options: a }, { data: this.leftEncode(), text: this.leftText(), options: n }, { data: x.MIDDLE_BIN, options: a }, { data: this.rightEncode(), text: this.rightText(), options: n }, { data: x.SIDE_BIN, options: a }];
|
|
628
622
|
}
|
|
629
623
|
}, {
|
|
630
624
|
key: "encodeFlat",
|
|
631
625
|
value: function() {
|
|
632
|
-
var n = [
|
|
626
|
+
var n = [x.SIDE_BIN, this.leftEncode(), x.MIDDLE_BIN, this.rightEncode(), x.SIDE_BIN];
|
|
633
627
|
return {
|
|
634
628
|
data: n.join(""),
|
|
635
629
|
text: this.text
|
|
636
630
|
};
|
|
637
631
|
}
|
|
638
632
|
}]), e;
|
|
639
|
-
}(
|
|
640
|
-
|
|
641
|
-
Object.defineProperty(
|
|
633
|
+
}(Zn.default);
|
|
634
|
+
Q.default = nr;
|
|
635
|
+
Object.defineProperty(be, "__esModule", {
|
|
642
636
|
value: !0
|
|
643
637
|
});
|
|
644
|
-
var
|
|
638
|
+
var rr = function() {
|
|
645
639
|
function t(e, r) {
|
|
646
640
|
for (var n = 0; n < r.length; n++) {
|
|
647
641
|
var a = r[n];
|
|
@@ -651,7 +645,7 @@ var Or = function() {
|
|
|
651
645
|
return function(e, r, n) {
|
|
652
646
|
return r && t(e.prototype, r), n && t(e, n), e;
|
|
653
647
|
};
|
|
654
|
-
}(),
|
|
648
|
+
}(), j = function t(e, r, n) {
|
|
655
649
|
e === null && (e = Function.prototype);
|
|
656
650
|
var a = Object.getOwnPropertyDescriptor(e, r);
|
|
657
651
|
if (a === void 0) {
|
|
@@ -663,70 +657,70 @@ var Or = function() {
|
|
|
663
657
|
var o = a.get;
|
|
664
658
|
return o === void 0 ? void 0 : o.call(n);
|
|
665
659
|
}
|
|
666
|
-
},
|
|
667
|
-
function
|
|
660
|
+
}, ar = v, ir = Q, or = ur(ir);
|
|
661
|
+
function ur(t) {
|
|
668
662
|
return t && t.__esModule ? t : { default: t };
|
|
669
663
|
}
|
|
670
|
-
function
|
|
664
|
+
function fr(t, e) {
|
|
671
665
|
if (!(t instanceof e))
|
|
672
666
|
throw new TypeError("Cannot call a class as a function");
|
|
673
667
|
}
|
|
674
|
-
function
|
|
668
|
+
function cr(t, e) {
|
|
675
669
|
if (!t)
|
|
676
670
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
677
671
|
return e && (typeof e == "object" || typeof e == "function") ? e : t;
|
|
678
672
|
}
|
|
679
|
-
function
|
|
673
|
+
function lr(t, e) {
|
|
680
674
|
if (typeof e != "function" && e !== null)
|
|
681
675
|
throw new TypeError("Super expression must either be null or a function, not " + typeof e);
|
|
682
676
|
t.prototype = Object.create(e && e.prototype, { constructor: { value: t, enumerable: !1, writable: !0, configurable: !0 } }), e && (Object.setPrototypeOf ? Object.setPrototypeOf(t, e) : t.__proto__ = e);
|
|
683
677
|
}
|
|
684
|
-
var
|
|
678
|
+
var Qe = function(e) {
|
|
685
679
|
var r = e.substr(0, 12).split("").map(function(n) {
|
|
686
680
|
return +n;
|
|
687
681
|
}).reduce(function(n, a, i) {
|
|
688
682
|
return i % 2 ? n + a * 3 : n + a;
|
|
689
683
|
}, 0);
|
|
690
684
|
return (10 - r % 10) % 10;
|
|
691
|
-
},
|
|
692
|
-
|
|
685
|
+
}, hr = function(t) {
|
|
686
|
+
lr(e, t);
|
|
693
687
|
function e(r, n) {
|
|
694
|
-
|
|
695
|
-
var a =
|
|
688
|
+
fr(this, e), r.search(/^[0-9]{12}$/) !== -1 && (r += Qe(r));
|
|
689
|
+
var a = cr(this, (e.__proto__ || Object.getPrototypeOf(e)).call(this, r, n));
|
|
696
690
|
return a.lastChar = n.lastChar, a;
|
|
697
691
|
}
|
|
698
|
-
return
|
|
692
|
+
return rr(e, [{
|
|
699
693
|
key: "valid",
|
|
700
694
|
value: function() {
|
|
701
|
-
return this.data.search(/^[0-9]{13}$/) !== -1 && +this.data[12] ===
|
|
695
|
+
return this.data.search(/^[0-9]{13}$/) !== -1 && +this.data[12] === Qe(this.data);
|
|
702
696
|
}
|
|
703
697
|
}, {
|
|
704
698
|
key: "leftText",
|
|
705
699
|
value: function() {
|
|
706
|
-
return
|
|
700
|
+
return j(e.prototype.__proto__ || Object.getPrototypeOf(e.prototype), "leftText", this).call(this, 1, 6);
|
|
707
701
|
}
|
|
708
702
|
}, {
|
|
709
703
|
key: "leftEncode",
|
|
710
704
|
value: function() {
|
|
711
|
-
var n = this.data.substr(1, 6), a =
|
|
712
|
-
return
|
|
705
|
+
var n = this.data.substr(1, 6), a = ar.EAN13_STRUCTURE[this.data[0]];
|
|
706
|
+
return j(e.prototype.__proto__ || Object.getPrototypeOf(e.prototype), "leftEncode", this).call(this, n, a);
|
|
713
707
|
}
|
|
714
708
|
}, {
|
|
715
709
|
key: "rightText",
|
|
716
710
|
value: function() {
|
|
717
|
-
return
|
|
711
|
+
return j(e.prototype.__proto__ || Object.getPrototypeOf(e.prototype), "rightText", this).call(this, 7, 6);
|
|
718
712
|
}
|
|
719
713
|
}, {
|
|
720
714
|
key: "rightEncode",
|
|
721
715
|
value: function() {
|
|
722
716
|
var n = this.data.substr(7, 6);
|
|
723
|
-
return
|
|
717
|
+
return j(e.prototype.__proto__ || Object.getPrototypeOf(e.prototype), "rightEncode", this).call(this, n, "RRRRRR");
|
|
724
718
|
}
|
|
725
719
|
// The "standard" way of printing EAN13 barcodes with guard bars
|
|
726
720
|
}, {
|
|
727
721
|
key: "encodeGuarded",
|
|
728
722
|
value: function() {
|
|
729
|
-
var n =
|
|
723
|
+
var n = j(e.prototype.__proto__ || Object.getPrototypeOf(e.prototype), "encodeGuarded", this).call(this);
|
|
730
724
|
return this.options.displayValue && (n.unshift({
|
|
731
725
|
data: "000000000000",
|
|
732
726
|
text: this.text.substr(0, 1),
|
|
@@ -740,13 +734,13 @@ var et = function(e) {
|
|
|
740
734
|
}))), n;
|
|
741
735
|
}
|
|
742
736
|
}]), e;
|
|
743
|
-
}(
|
|
744
|
-
|
|
745
|
-
var
|
|
746
|
-
Object.defineProperty(
|
|
737
|
+
}(or.default);
|
|
738
|
+
be.default = hr;
|
|
739
|
+
var we = {};
|
|
740
|
+
Object.defineProperty(we, "__esModule", {
|
|
747
741
|
value: !0
|
|
748
742
|
});
|
|
749
|
-
var
|
|
743
|
+
var dr = function() {
|
|
750
744
|
function t(e, r) {
|
|
751
745
|
for (var n = 0; n < r.length; n++) {
|
|
752
746
|
var a = r[n];
|
|
@@ -756,7 +750,7 @@ var Rr = function() {
|
|
|
756
750
|
return function(e, r, n) {
|
|
757
751
|
return r && t(e.prototype, r), n && t(e, n), e;
|
|
758
752
|
};
|
|
759
|
-
}(),
|
|
753
|
+
}(), X = function t(e, r, n) {
|
|
760
754
|
e === null && (e = Function.prototype);
|
|
761
755
|
var a = Object.getOwnPropertyDescriptor(e, r);
|
|
762
756
|
if (a === void 0) {
|
|
@@ -768,71 +762,71 @@ var Rr = function() {
|
|
|
768
762
|
var o = a.get;
|
|
769
763
|
return o === void 0 ? void 0 : o.call(n);
|
|
770
764
|
}
|
|
771
|
-
},
|
|
772
|
-
function
|
|
765
|
+
}, _r = Q, vr = yr(_r);
|
|
766
|
+
function yr(t) {
|
|
773
767
|
return t && t.__esModule ? t : { default: t };
|
|
774
768
|
}
|
|
775
|
-
function
|
|
769
|
+
function sr(t, e) {
|
|
776
770
|
if (!(t instanceof e))
|
|
777
771
|
throw new TypeError("Cannot call a class as a function");
|
|
778
772
|
}
|
|
779
|
-
function
|
|
773
|
+
function pr(t, e) {
|
|
780
774
|
if (!t)
|
|
781
775
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
782
776
|
return e && (typeof e == "object" || typeof e == "function") ? e : t;
|
|
783
777
|
}
|
|
784
|
-
function
|
|
778
|
+
function gr(t, e) {
|
|
785
779
|
if (typeof e != "function" && e !== null)
|
|
786
780
|
throw new TypeError("Super expression must either be null or a function, not " + typeof e);
|
|
787
781
|
t.prototype = Object.create(e && e.prototype, { constructor: { value: t, enumerable: !1, writable: !0, configurable: !0 } }), e && (Object.setPrototypeOf ? Object.setPrototypeOf(t, e) : t.__proto__ = e);
|
|
788
782
|
}
|
|
789
|
-
var
|
|
783
|
+
var We = function(e) {
|
|
790
784
|
var r = e.substr(0, 7).split("").map(function(n) {
|
|
791
785
|
return +n;
|
|
792
786
|
}).reduce(function(n, a, i) {
|
|
793
787
|
return i % 2 ? n + a : n + a * 3;
|
|
794
788
|
}, 0);
|
|
795
789
|
return (10 - r % 10) % 10;
|
|
796
|
-
},
|
|
797
|
-
|
|
790
|
+
}, Or = function(t) {
|
|
791
|
+
gr(e, t);
|
|
798
792
|
function e(r, n) {
|
|
799
|
-
return
|
|
793
|
+
return sr(this, e), r.search(/^[0-9]{7}$/) !== -1 && (r += We(r)), pr(this, (e.__proto__ || Object.getPrototypeOf(e)).call(this, r, n));
|
|
800
794
|
}
|
|
801
|
-
return
|
|
795
|
+
return dr(e, [{
|
|
802
796
|
key: "valid",
|
|
803
797
|
value: function() {
|
|
804
|
-
return this.data.search(/^[0-9]{8}$/) !== -1 && +this.data[7] ===
|
|
798
|
+
return this.data.search(/^[0-9]{8}$/) !== -1 && +this.data[7] === We(this.data);
|
|
805
799
|
}
|
|
806
800
|
}, {
|
|
807
801
|
key: "leftText",
|
|
808
802
|
value: function() {
|
|
809
|
-
return
|
|
803
|
+
return X(e.prototype.__proto__ || Object.getPrototypeOf(e.prototype), "leftText", this).call(this, 0, 4);
|
|
810
804
|
}
|
|
811
805
|
}, {
|
|
812
806
|
key: "leftEncode",
|
|
813
807
|
value: function() {
|
|
814
808
|
var n = this.data.substr(0, 4);
|
|
815
|
-
return
|
|
809
|
+
return X(e.prototype.__proto__ || Object.getPrototypeOf(e.prototype), "leftEncode", this).call(this, n, "LLLL");
|
|
816
810
|
}
|
|
817
811
|
}, {
|
|
818
812
|
key: "rightText",
|
|
819
813
|
value: function() {
|
|
820
|
-
return
|
|
814
|
+
return X(e.prototype.__proto__ || Object.getPrototypeOf(e.prototype), "rightText", this).call(this, 4, 4);
|
|
821
815
|
}
|
|
822
816
|
}, {
|
|
823
817
|
key: "rightEncode",
|
|
824
818
|
value: function() {
|
|
825
819
|
var n = this.data.substr(4, 4);
|
|
826
|
-
return
|
|
820
|
+
return X(e.prototype.__proto__ || Object.getPrototypeOf(e.prototype), "rightEncode", this).call(this, n, "RRRR");
|
|
827
821
|
}
|
|
828
822
|
}]), e;
|
|
829
|
-
}(
|
|
830
|
-
|
|
831
|
-
var
|
|
832
|
-
Object.defineProperty(
|
|
823
|
+
}(vr.default);
|
|
824
|
+
we.default = Or;
|
|
825
|
+
var me = {};
|
|
826
|
+
Object.defineProperty(me, "__esModule", {
|
|
833
827
|
value: !0
|
|
834
828
|
});
|
|
835
|
-
var
|
|
829
|
+
var Er = function() {
|
|
836
830
|
function t(e, r) {
|
|
837
831
|
for (var n = 0; n < r.length; n++) {
|
|
838
832
|
var a = r[n];
|
|
@@ -842,37 +836,37 @@ var Br = function() {
|
|
|
842
836
|
return function(e, r, n) {
|
|
843
837
|
return r && t(e.prototype, r), n && t(e, n), e;
|
|
844
838
|
};
|
|
845
|
-
}(),
|
|
846
|
-
function
|
|
839
|
+
}(), br = v, wr = w, mr = Ot(wr), $r = c, xr = Ot($r);
|
|
840
|
+
function Ot(t) {
|
|
847
841
|
return t && t.__esModule ? t : { default: t };
|
|
848
842
|
}
|
|
849
|
-
function
|
|
843
|
+
function Sr(t, e) {
|
|
850
844
|
if (!(t instanceof e))
|
|
851
845
|
throw new TypeError("Cannot call a class as a function");
|
|
852
846
|
}
|
|
853
|
-
function
|
|
847
|
+
function Ar(t, e) {
|
|
854
848
|
if (!t)
|
|
855
849
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
856
850
|
return e && (typeof e == "object" || typeof e == "function") ? e : t;
|
|
857
851
|
}
|
|
858
|
-
function
|
|
852
|
+
function Rr(t, e) {
|
|
859
853
|
if (typeof e != "function" && e !== null)
|
|
860
854
|
throw new TypeError("Super expression must either be null or a function, not " + typeof e);
|
|
861
855
|
t.prototype = Object.create(e && e.prototype, { constructor: { value: t, enumerable: !1, writable: !0, configurable: !0 } }), e && (Object.setPrototypeOf ? Object.setPrototypeOf(t, e) : t.__proto__ = e);
|
|
862
856
|
}
|
|
863
|
-
var
|
|
857
|
+
var Pr = function(e) {
|
|
864
858
|
var r = e.split("").map(function(n) {
|
|
865
859
|
return +n;
|
|
866
860
|
}).reduce(function(n, a, i) {
|
|
867
861
|
return i % 2 ? n + a * 9 : n + a * 3;
|
|
868
862
|
}, 0);
|
|
869
863
|
return r % 10;
|
|
870
|
-
},
|
|
871
|
-
|
|
864
|
+
}, Tr = function(t) {
|
|
865
|
+
Rr(e, t);
|
|
872
866
|
function e(r, n) {
|
|
873
|
-
return
|
|
867
|
+
return Sr(this, e), Ar(this, (e.__proto__ || Object.getPrototypeOf(e)).call(this, r, n));
|
|
874
868
|
}
|
|
875
|
-
return
|
|
869
|
+
return Er(e, [{
|
|
876
870
|
key: "valid",
|
|
877
871
|
value: function() {
|
|
878
872
|
return this.data.search(/^[0-9]{5}$/) !== -1;
|
|
@@ -880,20 +874,20 @@ var Ur = function(e) {
|
|
|
880
874
|
}, {
|
|
881
875
|
key: "encode",
|
|
882
876
|
value: function() {
|
|
883
|
-
var n =
|
|
877
|
+
var n = br.EAN5_STRUCTURE[Pr(this.data)];
|
|
884
878
|
return {
|
|
885
|
-
data: "1011" + (0,
|
|
879
|
+
data: "1011" + (0, mr.default)(this.data, n, "01"),
|
|
886
880
|
text: this.text
|
|
887
881
|
};
|
|
888
882
|
}
|
|
889
883
|
}]), e;
|
|
890
|
-
}(
|
|
891
|
-
|
|
892
|
-
var
|
|
893
|
-
Object.defineProperty(
|
|
884
|
+
}(xr.default);
|
|
885
|
+
me.default = Tr;
|
|
886
|
+
var $e = {};
|
|
887
|
+
Object.defineProperty($e, "__esModule", {
|
|
894
888
|
value: !0
|
|
895
889
|
});
|
|
896
|
-
var
|
|
890
|
+
var Mr = function() {
|
|
897
891
|
function t(e, r) {
|
|
898
892
|
for (var n = 0; n < r.length; n++) {
|
|
899
893
|
var a = r[n];
|
|
@@ -903,30 +897,30 @@ var qr = function() {
|
|
|
903
897
|
return function(e, r, n) {
|
|
904
898
|
return r && t(e.prototype, r), n && t(e, n), e;
|
|
905
899
|
};
|
|
906
|
-
}(),
|
|
907
|
-
function
|
|
900
|
+
}(), Ir = v, kr = w, Dr = Et(kr), jr = c, Br = Et(jr);
|
|
901
|
+
function Et(t) {
|
|
908
902
|
return t && t.__esModule ? t : { default: t };
|
|
909
903
|
}
|
|
910
|
-
function
|
|
904
|
+
function Lr(t, e) {
|
|
911
905
|
if (!(t instanceof e))
|
|
912
906
|
throw new TypeError("Cannot call a class as a function");
|
|
913
907
|
}
|
|
914
|
-
function
|
|
908
|
+
function Cr(t, e) {
|
|
915
909
|
if (!t)
|
|
916
910
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
917
911
|
return e && (typeof e == "object" || typeof e == "function") ? e : t;
|
|
918
912
|
}
|
|
919
|
-
function
|
|
913
|
+
function Nr(t, e) {
|
|
920
914
|
if (typeof e != "function" && e !== null)
|
|
921
915
|
throw new TypeError("Super expression must either be null or a function, not " + typeof e);
|
|
922
916
|
t.prototype = Object.create(e && e.prototype, { constructor: { value: t, enumerable: !1, writable: !0, configurable: !0 } }), e && (Object.setPrototypeOf ? Object.setPrototypeOf(t, e) : t.__proto__ = e);
|
|
923
917
|
}
|
|
924
|
-
var
|
|
925
|
-
|
|
918
|
+
var Gr = function(t) {
|
|
919
|
+
Nr(e, t);
|
|
926
920
|
function e(r, n) {
|
|
927
|
-
return
|
|
921
|
+
return Lr(this, e), Cr(this, (e.__proto__ || Object.getPrototypeOf(e)).call(this, r, n));
|
|
928
922
|
}
|
|
929
|
-
return
|
|
923
|
+
return Mr(e, [{
|
|
930
924
|
key: "valid",
|
|
931
925
|
value: function() {
|
|
932
926
|
return this.data.search(/^[0-9]{2}$/) !== -1;
|
|
@@ -934,21 +928,21 @@ var na = function(t) {
|
|
|
934
928
|
}, {
|
|
935
929
|
key: "encode",
|
|
936
930
|
value: function() {
|
|
937
|
-
var n =
|
|
931
|
+
var n = Ir.EAN2_STRUCTURE[parseInt(this.data) % 4];
|
|
938
932
|
return {
|
|
939
933
|
// Start bits + Encode the two digits with 01 in between
|
|
940
|
-
data: "1011" + (0,
|
|
934
|
+
data: "1011" + (0, Dr.default)(this.data, n, "01"),
|
|
941
935
|
text: this.text
|
|
942
936
|
};
|
|
943
937
|
}
|
|
944
938
|
}]), e;
|
|
945
|
-
}(
|
|
946
|
-
|
|
947
|
-
var
|
|
948
|
-
Object.defineProperty(
|
|
939
|
+
}(Br.default);
|
|
940
|
+
$e.default = Gr;
|
|
941
|
+
var C = {};
|
|
942
|
+
Object.defineProperty(C, "__esModule", {
|
|
949
943
|
value: !0
|
|
950
944
|
});
|
|
951
|
-
var
|
|
945
|
+
var Fr = function() {
|
|
952
946
|
function t(e, r) {
|
|
953
947
|
for (var n = 0; n < r.length; n++) {
|
|
954
948
|
var a = r[n];
|
|
@@ -959,36 +953,36 @@ var ra = function() {
|
|
|
959
953
|
return r && t(e.prototype, r), n && t(e, n), e;
|
|
960
954
|
};
|
|
961
955
|
}();
|
|
962
|
-
|
|
963
|
-
var
|
|
964
|
-
function
|
|
956
|
+
C.checksum = he;
|
|
957
|
+
var Hr = w, S = bt(Hr), Xr = c, zr = bt(Xr);
|
|
958
|
+
function bt(t) {
|
|
965
959
|
return t && t.__esModule ? t : { default: t };
|
|
966
960
|
}
|
|
967
|
-
function
|
|
961
|
+
function Ur(t, e) {
|
|
968
962
|
if (!(t instanceof e))
|
|
969
963
|
throw new TypeError("Cannot call a class as a function");
|
|
970
964
|
}
|
|
971
|
-
function
|
|
965
|
+
function Vr(t, e) {
|
|
972
966
|
if (!t)
|
|
973
967
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
974
968
|
return e && (typeof e == "object" || typeof e == "function") ? e : t;
|
|
975
969
|
}
|
|
976
|
-
function
|
|
970
|
+
function qr(t, e) {
|
|
977
971
|
if (typeof e != "function" && e !== null)
|
|
978
972
|
throw new TypeError("Super expression must either be null or a function, not " + typeof e);
|
|
979
973
|
t.prototype = Object.create(e && e.prototype, { constructor: { value: t, enumerable: !1, writable: !0, configurable: !0 } }), e && (Object.setPrototypeOf ? Object.setPrototypeOf(t, e) : t.__proto__ = e);
|
|
980
974
|
}
|
|
981
|
-
var
|
|
982
|
-
|
|
975
|
+
var Jr = function(t) {
|
|
976
|
+
qr(e, t);
|
|
983
977
|
function e(r, n) {
|
|
984
|
-
|
|
985
|
-
var a =
|
|
978
|
+
Ur(this, e), r.search(/^[0-9]{11}$/) !== -1 && (r += he(r));
|
|
979
|
+
var a = Vr(this, (e.__proto__ || Object.getPrototypeOf(e)).call(this, r, n));
|
|
986
980
|
return a.displayValue = n.displayValue, n.fontSize > n.width * 10 ? a.fontSize = n.width * 10 : a.fontSize = n.fontSize, a.guardHeight = n.height + a.fontSize / 2 + n.textMargin, a;
|
|
987
981
|
}
|
|
988
|
-
return
|
|
982
|
+
return Fr(e, [{
|
|
989
983
|
key: "valid",
|
|
990
984
|
value: function() {
|
|
991
|
-
return this.data.search(/^[0-9]{12}$/) !== -1 && this.data[11] ==
|
|
985
|
+
return this.data.search(/^[0-9]{12}$/) !== -1 && this.data[11] == he(this.data);
|
|
992
986
|
}
|
|
993
987
|
}, {
|
|
994
988
|
key: "encode",
|
|
@@ -999,7 +993,7 @@ var la = function(t) {
|
|
|
999
993
|
key: "flatEncoding",
|
|
1000
994
|
value: function() {
|
|
1001
995
|
var n = "";
|
|
1002
|
-
return n += "101", n += (0,
|
|
996
|
+
return n += "101", n += (0, S.default)(this.data.substr(0, 6), "LLLLLL"), n += "01010", n += (0, S.default)(this.data.substr(6, 6), "RRRRRR"), n += "101", {
|
|
1003
997
|
data: n,
|
|
1004
998
|
text: this.text
|
|
1005
999
|
};
|
|
@@ -1013,21 +1007,21 @@ var la = function(t) {
|
|
|
1013
1007
|
text: this.text.substr(0, 1),
|
|
1014
1008
|
options: { textAlign: "left", fontSize: this.fontSize }
|
|
1015
1009
|
}), n.push({
|
|
1016
|
-
data: "101" + (0,
|
|
1010
|
+
data: "101" + (0, S.default)(this.data[0], "L"),
|
|
1017
1011
|
options: { height: this.guardHeight }
|
|
1018
1012
|
}), n.push({
|
|
1019
|
-
data: (0,
|
|
1013
|
+
data: (0, S.default)(this.data.substr(1, 5), "LLLLL"),
|
|
1020
1014
|
text: this.text.substr(1, 5),
|
|
1021
1015
|
options: { fontSize: this.fontSize }
|
|
1022
1016
|
}), n.push({
|
|
1023
1017
|
data: "01010",
|
|
1024
1018
|
options: { height: this.guardHeight }
|
|
1025
1019
|
}), n.push({
|
|
1026
|
-
data: (0,
|
|
1020
|
+
data: (0, S.default)(this.data.substr(6, 5), "RRRRR"),
|
|
1027
1021
|
text: this.text.substr(6, 5),
|
|
1028
1022
|
options: { fontSize: this.fontSize }
|
|
1029
1023
|
}), n.push({
|
|
1030
|
-
data: (0,
|
|
1024
|
+
data: (0, S.default)(this.data[11], "R") + "101",
|
|
1031
1025
|
options: { height: this.guardHeight }
|
|
1032
1026
|
}), this.displayValue && n.push({
|
|
1033
1027
|
data: "00000000",
|
|
@@ -1036,8 +1030,8 @@ var la = function(t) {
|
|
|
1036
1030
|
}), n;
|
|
1037
1031
|
}
|
|
1038
1032
|
}]), e;
|
|
1039
|
-
}(
|
|
1040
|
-
function
|
|
1033
|
+
}(zr.default);
|
|
1034
|
+
function he(t) {
|
|
1041
1035
|
var e = 0, r;
|
|
1042
1036
|
for (r = 1; r < 11; r += 2)
|
|
1043
1037
|
e += parseInt(t[r]);
|
|
@@ -1045,12 +1039,12 @@ function se(t) {
|
|
|
1045
1039
|
e += parseInt(t[r]) * 3;
|
|
1046
1040
|
return (10 - e % 10) % 10;
|
|
1047
1041
|
}
|
|
1048
|
-
|
|
1049
|
-
var
|
|
1050
|
-
Object.defineProperty(
|
|
1042
|
+
C.default = Jr;
|
|
1043
|
+
var xe = {};
|
|
1044
|
+
Object.defineProperty(xe, "__esModule", {
|
|
1051
1045
|
value: !0
|
|
1052
1046
|
});
|
|
1053
|
-
var
|
|
1047
|
+
var Yr = function() {
|
|
1054
1048
|
function t(e, r) {
|
|
1055
1049
|
for (var n = 0; n < r.length; n++) {
|
|
1056
1050
|
var a = r[n];
|
|
@@ -1060,41 +1054,41 @@ var ha = function() {
|
|
|
1060
1054
|
return function(e, r, n) {
|
|
1061
1055
|
return r && t(e.prototype, r), n && t(e, n), e;
|
|
1062
1056
|
};
|
|
1063
|
-
}(),
|
|
1064
|
-
function
|
|
1057
|
+
}(), Qr = w, Wr = wt(Qr), Zr = c, Kr = wt(Zr), ea = C;
|
|
1058
|
+
function wt(t) {
|
|
1065
1059
|
return t && t.__esModule ? t : { default: t };
|
|
1066
1060
|
}
|
|
1067
|
-
function
|
|
1061
|
+
function ta(t, e) {
|
|
1068
1062
|
if (!(t instanceof e))
|
|
1069
1063
|
throw new TypeError("Cannot call a class as a function");
|
|
1070
1064
|
}
|
|
1071
|
-
function
|
|
1065
|
+
function fe(t, e) {
|
|
1072
1066
|
if (!t)
|
|
1073
1067
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
1074
1068
|
return e && (typeof e == "object" || typeof e == "function") ? e : t;
|
|
1075
1069
|
}
|
|
1076
|
-
function
|
|
1070
|
+
function na(t, e) {
|
|
1077
1071
|
if (typeof e != "function" && e !== null)
|
|
1078
1072
|
throw new TypeError("Super expression must either be null or a function, not " + typeof e);
|
|
1079
1073
|
t.prototype = Object.create(e && e.prototype, { constructor: { value: t, enumerable: !1, writable: !0, configurable: !0 } }), e && (Object.setPrototypeOf ? Object.setPrototypeOf(t, e) : t.__proto__ = e);
|
|
1080
1074
|
}
|
|
1081
|
-
var
|
|
1082
|
-
|
|
1075
|
+
var ra = ["XX00000XXX", "XX10000XXX", "XX20000XXX", "XXX00000XX", "XXXX00000X", "XXXXX00005", "XXXXX00006", "XXXXX00007", "XXXXX00008", "XXXXX00009"], aa = [["EEEOOO", "OOOEEE"], ["EEOEOO", "OOEOEE"], ["EEOOEO", "OOEEOE"], ["EEOOOE", "OOEEEO"], ["EOEEOO", "OEOOEE"], ["EOOEEO", "OEEOOE"], ["EOOOEE", "OEEEOO"], ["EOEOEO", "OEOEOE"], ["EOEOOE", "OEOEEO"], ["EOOEOE", "OEEOEO"]], ia = function(t) {
|
|
1076
|
+
na(e, t);
|
|
1083
1077
|
function e(r, n) {
|
|
1084
|
-
|
|
1085
|
-
var a =
|
|
1078
|
+
ta(this, e);
|
|
1079
|
+
var a = fe(this, (e.__proto__ || Object.getPrototypeOf(e)).call(this, r, n));
|
|
1086
1080
|
if (a.isValid = !1, r.search(/^[0-9]{6}$/) !== -1)
|
|
1087
|
-
a.middleDigits = r, a.upcA =
|
|
1081
|
+
a.middleDigits = r, a.upcA = Ze(r, "0"), a.text = n.text || "" + a.upcA[0] + r + a.upcA[a.upcA.length - 1], a.isValid = !0;
|
|
1088
1082
|
else if (r.search(/^[01][0-9]{7}$/) !== -1)
|
|
1089
|
-
if (a.middleDigits = r.substring(1, r.length - 1), a.upcA =
|
|
1083
|
+
if (a.middleDigits = r.substring(1, r.length - 1), a.upcA = Ze(a.middleDigits, r[0]), a.upcA[a.upcA.length - 1] === r[r.length - 1])
|
|
1090
1084
|
a.isValid = !0;
|
|
1091
1085
|
else
|
|
1092
|
-
return
|
|
1086
|
+
return fe(a);
|
|
1093
1087
|
else
|
|
1094
|
-
return
|
|
1088
|
+
return fe(a);
|
|
1095
1089
|
return a.displayValue = n.displayValue, n.fontSize > n.width * 10 ? a.fontSize = n.width * 10 : a.fontSize = n.fontSize, a.guardHeight = n.height + a.fontSize / 2 + n.textMargin, a;
|
|
1096
1090
|
}
|
|
1097
|
-
return
|
|
1091
|
+
return Yr(e, [{
|
|
1098
1092
|
key: "valid",
|
|
1099
1093
|
value: function() {
|
|
1100
1094
|
return this.isValid;
|
|
@@ -1140,44 +1134,44 @@ var Oa = ["XX00000XXX", "XX10000XXX", "XX20000XXX", "XXX00000XX", "XXXX00000X",
|
|
|
1140
1134
|
}, {
|
|
1141
1135
|
key: "encodeMiddleDigits",
|
|
1142
1136
|
value: function() {
|
|
1143
|
-
var n = this.upcA[0], a = this.upcA[this.upcA.length - 1], i =
|
|
1144
|
-
return (0,
|
|
1137
|
+
var n = this.upcA[0], a = this.upcA[this.upcA.length - 1], i = aa[parseInt(a)][parseInt(n)];
|
|
1138
|
+
return (0, Wr.default)(this.middleDigits, i);
|
|
1145
1139
|
}
|
|
1146
1140
|
}]), e;
|
|
1147
|
-
}(
|
|
1148
|
-
function
|
|
1149
|
-
for (var r = parseInt(t[t.length - 1]), n =
|
|
1141
|
+
}(Kr.default);
|
|
1142
|
+
function Ze(t, e) {
|
|
1143
|
+
for (var r = parseInt(t[t.length - 1]), n = ra[r], a = "", i = 0, o = 0; o < n.length; o++) {
|
|
1150
1144
|
var u = n[o];
|
|
1151
1145
|
u === "X" ? a += t[i++] : a += u;
|
|
1152
1146
|
}
|
|
1153
|
-
return a = "" + e + a, "" + a + (0,
|
|
1147
|
+
return a = "" + e + a, "" + a + (0, ea.checksum)(a);
|
|
1154
1148
|
}
|
|
1155
|
-
|
|
1156
|
-
Object.defineProperty(
|
|
1149
|
+
xe.default = ia;
|
|
1150
|
+
Object.defineProperty(l, "__esModule", {
|
|
1157
1151
|
value: !0
|
|
1158
1152
|
});
|
|
1159
|
-
|
|
1160
|
-
var
|
|
1161
|
-
function
|
|
1153
|
+
l.UPCE = l.UPC = l.EAN2 = l.EAN5 = l.EAN8 = l.EAN13 = void 0;
|
|
1154
|
+
var oa = be, ua = M(oa), fa = we, ca = M(fa), la = me, ha = M(la), da = $e, _a = M(da), va = C, ya = M(va), sa = xe, pa = M(sa);
|
|
1155
|
+
function M(t) {
|
|
1162
1156
|
return t && t.__esModule ? t : { default: t };
|
|
1163
1157
|
}
|
|
1164
|
-
|
|
1165
|
-
|
|
1166
|
-
|
|
1167
|
-
|
|
1168
|
-
|
|
1169
|
-
|
|
1170
|
-
var
|
|
1171
|
-
Object.defineProperty(
|
|
1158
|
+
l.EAN13 = ua.default;
|
|
1159
|
+
l.EAN8 = ca.default;
|
|
1160
|
+
l.EAN5 = ha.default;
|
|
1161
|
+
l.EAN2 = _a.default;
|
|
1162
|
+
l.UPC = ya.default;
|
|
1163
|
+
l.UPCE = pa.default;
|
|
1164
|
+
var R = {}, W = {}, N = {};
|
|
1165
|
+
Object.defineProperty(N, "__esModule", {
|
|
1172
1166
|
value: !0
|
|
1173
1167
|
});
|
|
1174
|
-
|
|
1175
|
-
|
|
1176
|
-
|
|
1177
|
-
Object.defineProperty(
|
|
1168
|
+
N.START_BIN = "1010";
|
|
1169
|
+
N.END_BIN = "11101";
|
|
1170
|
+
N.BINARIES = ["00110", "10001", "01001", "11000", "00101", "10100", "01100", "00011", "10010", "01010"];
|
|
1171
|
+
Object.defineProperty(W, "__esModule", {
|
|
1178
1172
|
value: !0
|
|
1179
1173
|
});
|
|
1180
|
-
var
|
|
1174
|
+
var ga = function() {
|
|
1181
1175
|
function t(e, r) {
|
|
1182
1176
|
for (var n = 0; n < r.length; n++) {
|
|
1183
1177
|
var a = r[n];
|
|
@@ -1187,30 +1181,30 @@ var Da = function() {
|
|
|
1187
1181
|
return function(e, r, n) {
|
|
1188
1182
|
return r && t(e.prototype, r), n && t(e, n), e;
|
|
1189
1183
|
};
|
|
1190
|
-
}(),
|
|
1191
|
-
function
|
|
1184
|
+
}(), z = N, Oa = c, Ea = ba(Oa);
|
|
1185
|
+
function ba(t) {
|
|
1192
1186
|
return t && t.__esModule ? t : { default: t };
|
|
1193
1187
|
}
|
|
1194
|
-
function
|
|
1188
|
+
function wa(t, e) {
|
|
1195
1189
|
if (!(t instanceof e))
|
|
1196
1190
|
throw new TypeError("Cannot call a class as a function");
|
|
1197
1191
|
}
|
|
1198
|
-
function
|
|
1192
|
+
function ma(t, e) {
|
|
1199
1193
|
if (!t)
|
|
1200
1194
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
1201
1195
|
return e && (typeof e == "object" || typeof e == "function") ? e : t;
|
|
1202
1196
|
}
|
|
1203
|
-
function
|
|
1197
|
+
function $a(t, e) {
|
|
1204
1198
|
if (typeof e != "function" && e !== null)
|
|
1205
1199
|
throw new TypeError("Super expression must either be null or a function, not " + typeof e);
|
|
1206
1200
|
t.prototype = Object.create(e && e.prototype, { constructor: { value: t, enumerable: !1, writable: !0, configurable: !0 } }), e && (Object.setPrototypeOf ? Object.setPrototypeOf(t, e) : t.__proto__ = e);
|
|
1207
1201
|
}
|
|
1208
|
-
var
|
|
1209
|
-
|
|
1202
|
+
var xa = function(t) {
|
|
1203
|
+
$a(e, t);
|
|
1210
1204
|
function e() {
|
|
1211
|
-
return
|
|
1205
|
+
return wa(this, e), ma(this, (e.__proto__ || Object.getPrototypeOf(e)).apply(this, arguments));
|
|
1212
1206
|
}
|
|
1213
|
-
return
|
|
1207
|
+
return ga(e, [{
|
|
1214
1208
|
key: "valid",
|
|
1215
1209
|
value: function() {
|
|
1216
1210
|
return this.data.search(/^([0-9]{2})+$/) !== -1;
|
|
@@ -1222,7 +1216,7 @@ var Fa = function(t) {
|
|
|
1222
1216
|
return n.encodePair(i);
|
|
1223
1217
|
}).join("");
|
|
1224
1218
|
return {
|
|
1225
|
-
data:
|
|
1219
|
+
data: z.START_BIN + a + z.END_BIN,
|
|
1226
1220
|
text: this.text
|
|
1227
1221
|
};
|
|
1228
1222
|
}
|
|
@@ -1230,19 +1224,19 @@ var Fa = function(t) {
|
|
|
1230
1224
|
}, {
|
|
1231
1225
|
key: "encodePair",
|
|
1232
1226
|
value: function(n) {
|
|
1233
|
-
var a =
|
|
1234
|
-
return
|
|
1227
|
+
var a = z.BINARIES[n[1]];
|
|
1228
|
+
return z.BINARIES[n[0]].split("").map(function(i, o) {
|
|
1235
1229
|
return (i === "1" ? "111" : "1") + (a[o] === "1" ? "000" : "0");
|
|
1236
1230
|
}).join("");
|
|
1237
1231
|
}
|
|
1238
1232
|
}]), e;
|
|
1239
|
-
}(
|
|
1240
|
-
|
|
1241
|
-
var
|
|
1242
|
-
Object.defineProperty(
|
|
1233
|
+
}(Ea.default);
|
|
1234
|
+
W.default = xa;
|
|
1235
|
+
var Se = {};
|
|
1236
|
+
Object.defineProperty(Se, "__esModule", {
|
|
1243
1237
|
value: !0
|
|
1244
1238
|
});
|
|
1245
|
-
var
|
|
1239
|
+
var Sa = function() {
|
|
1246
1240
|
function t(e, r) {
|
|
1247
1241
|
for (var n = 0; n < r.length; n++) {
|
|
1248
1242
|
var a = r[n];
|
|
@@ -1252,59 +1246,59 @@ var Ha = function() {
|
|
|
1252
1246
|
return function(e, r, n) {
|
|
1253
1247
|
return r && t(e.prototype, r), n && t(e, n), e;
|
|
1254
1248
|
};
|
|
1255
|
-
}(),
|
|
1256
|
-
function
|
|
1249
|
+
}(), Aa = W, Ra = Pa(Aa);
|
|
1250
|
+
function Pa(t) {
|
|
1257
1251
|
return t && t.__esModule ? t : { default: t };
|
|
1258
1252
|
}
|
|
1259
|
-
function
|
|
1253
|
+
function Ta(t, e) {
|
|
1260
1254
|
if (!(t instanceof e))
|
|
1261
1255
|
throw new TypeError("Cannot call a class as a function");
|
|
1262
1256
|
}
|
|
1263
|
-
function
|
|
1257
|
+
function Ma(t, e) {
|
|
1264
1258
|
if (!t)
|
|
1265
1259
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
1266
1260
|
return e && (typeof e == "object" || typeof e == "function") ? e : t;
|
|
1267
1261
|
}
|
|
1268
|
-
function
|
|
1262
|
+
function Ia(t, e) {
|
|
1269
1263
|
if (typeof e != "function" && e !== null)
|
|
1270
1264
|
throw new TypeError("Super expression must either be null or a function, not " + typeof e);
|
|
1271
1265
|
t.prototype = Object.create(e && e.prototype, { constructor: { value: t, enumerable: !1, writable: !0, configurable: !0 } }), e && (Object.setPrototypeOf ? Object.setPrototypeOf(t, e) : t.__proto__ = e);
|
|
1272
1266
|
}
|
|
1273
|
-
var
|
|
1267
|
+
var Ke = function(e) {
|
|
1274
1268
|
var r = e.substr(0, 13).split("").map(function(n) {
|
|
1275
1269
|
return parseInt(n, 10);
|
|
1276
1270
|
}).reduce(function(n, a, i) {
|
|
1277
1271
|
return n + a * (3 - i % 2 * 2);
|
|
1278
1272
|
}, 0);
|
|
1279
1273
|
return Math.ceil(r / 10) * 10 - r;
|
|
1280
|
-
},
|
|
1281
|
-
|
|
1274
|
+
}, ka = function(t) {
|
|
1275
|
+
Ia(e, t);
|
|
1282
1276
|
function e(r, n) {
|
|
1283
|
-
return
|
|
1277
|
+
return Ta(this, e), r.search(/^[0-9]{13}$/) !== -1 && (r += Ke(r)), Ma(this, (e.__proto__ || Object.getPrototypeOf(e)).call(this, r, n));
|
|
1284
1278
|
}
|
|
1285
|
-
return
|
|
1279
|
+
return Sa(e, [{
|
|
1286
1280
|
key: "valid",
|
|
1287
1281
|
value: function() {
|
|
1288
|
-
return this.data.search(/^[0-9]{14}$/) !== -1 && +this.data[13] ===
|
|
1282
|
+
return this.data.search(/^[0-9]{14}$/) !== -1 && +this.data[13] === Ke(this.data);
|
|
1289
1283
|
}
|
|
1290
1284
|
}]), e;
|
|
1291
|
-
}(
|
|
1292
|
-
|
|
1293
|
-
Object.defineProperty(
|
|
1285
|
+
}(Ra.default);
|
|
1286
|
+
Se.default = ka;
|
|
1287
|
+
Object.defineProperty(R, "__esModule", {
|
|
1294
1288
|
value: !0
|
|
1295
1289
|
});
|
|
1296
|
-
|
|
1297
|
-
var
|
|
1298
|
-
function
|
|
1290
|
+
R.ITF14 = R.ITF = void 0;
|
|
1291
|
+
var Da = W, ja = mt(Da), Ba = Se, La = mt(Ba);
|
|
1292
|
+
function mt(t) {
|
|
1299
1293
|
return t && t.__esModule ? t : { default: t };
|
|
1300
1294
|
}
|
|
1301
|
-
|
|
1302
|
-
|
|
1303
|
-
var
|
|
1304
|
-
Object.defineProperty(
|
|
1295
|
+
R.ITF = ja.default;
|
|
1296
|
+
R.ITF14 = La.default;
|
|
1297
|
+
var _ = {}, m = {};
|
|
1298
|
+
Object.defineProperty(m, "__esModule", {
|
|
1305
1299
|
value: !0
|
|
1306
1300
|
});
|
|
1307
|
-
var
|
|
1301
|
+
var Ca = function() {
|
|
1308
1302
|
function t(e, r) {
|
|
1309
1303
|
for (var n = 0; n < r.length; n++) {
|
|
1310
1304
|
var a = r[n];
|
|
@@ -1314,35 +1308,35 @@ var ei = function() {
|
|
|
1314
1308
|
return function(e, r, n) {
|
|
1315
1309
|
return r && t(e.prototype, r), n && t(e, n), e;
|
|
1316
1310
|
};
|
|
1317
|
-
}(),
|
|
1318
|
-
function
|
|
1311
|
+
}(), Na = c, Ga = Fa(Na);
|
|
1312
|
+
function Fa(t) {
|
|
1319
1313
|
return t && t.__esModule ? t : { default: t };
|
|
1320
1314
|
}
|
|
1321
|
-
function
|
|
1315
|
+
function Ha(t, e) {
|
|
1322
1316
|
if (!(t instanceof e))
|
|
1323
1317
|
throw new TypeError("Cannot call a class as a function");
|
|
1324
1318
|
}
|
|
1325
|
-
function
|
|
1319
|
+
function Xa(t, e) {
|
|
1326
1320
|
if (!t)
|
|
1327
1321
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
1328
1322
|
return e && (typeof e == "object" || typeof e == "function") ? e : t;
|
|
1329
1323
|
}
|
|
1330
|
-
function
|
|
1324
|
+
function za(t, e) {
|
|
1331
1325
|
if (typeof e != "function" && e !== null)
|
|
1332
1326
|
throw new TypeError("Super expression must either be null or a function, not " + typeof e);
|
|
1333
1327
|
t.prototype = Object.create(e && e.prototype, { constructor: { value: t, enumerable: !1, writable: !0, configurable: !0 } }), e && (Object.setPrototypeOf ? Object.setPrototypeOf(t, e) : t.__proto__ = e);
|
|
1334
1328
|
}
|
|
1335
|
-
var
|
|
1336
|
-
|
|
1329
|
+
var Ua = function(t) {
|
|
1330
|
+
za(e, t);
|
|
1337
1331
|
function e(r, n) {
|
|
1338
|
-
return
|
|
1332
|
+
return Ha(this, e), Xa(this, (e.__proto__ || Object.getPrototypeOf(e)).call(this, r, n));
|
|
1339
1333
|
}
|
|
1340
|
-
return
|
|
1334
|
+
return Ca(e, [{
|
|
1341
1335
|
key: "encode",
|
|
1342
1336
|
value: function() {
|
|
1343
1337
|
for (var n = "110", a = 0; a < this.data.length; a++) {
|
|
1344
1338
|
var i = parseInt(this.data[a]), o = i.toString(2);
|
|
1345
|
-
o =
|
|
1339
|
+
o = Va(o, 4 - o.length);
|
|
1346
1340
|
for (var u = 0; u < o.length; u++)
|
|
1347
1341
|
n += o[u] == "0" ? "100" : "110";
|
|
1348
1342
|
}
|
|
@@ -1357,171 +1351,171 @@ var ui = function(t) {
|
|
|
1357
1351
|
return this.data.search(/^[0-9]+$/) !== -1;
|
|
1358
1352
|
}
|
|
1359
1353
|
}]), e;
|
|
1360
|
-
}(
|
|
1361
|
-
function
|
|
1354
|
+
}(Ga.default);
|
|
1355
|
+
function Va(t, e) {
|
|
1362
1356
|
for (var r = 0; r < e; r++)
|
|
1363
1357
|
t = "0" + t;
|
|
1364
1358
|
return t;
|
|
1365
1359
|
}
|
|
1366
|
-
|
|
1367
|
-
var
|
|
1368
|
-
Object.defineProperty(
|
|
1360
|
+
m.default = Ua;
|
|
1361
|
+
var Ae = {}, $ = {};
|
|
1362
|
+
Object.defineProperty($, "__esModule", {
|
|
1369
1363
|
value: !0
|
|
1370
1364
|
});
|
|
1371
|
-
|
|
1372
|
-
|
|
1373
|
-
function
|
|
1365
|
+
$.mod10 = qa;
|
|
1366
|
+
$.mod11 = Ja;
|
|
1367
|
+
function qa(t) {
|
|
1374
1368
|
for (var e = 0, r = 0; r < t.length; r++) {
|
|
1375
1369
|
var n = parseInt(t[r]);
|
|
1376
1370
|
(r + t.length) % 2 === 0 ? e += n : e += n * 2 % 10 + Math.floor(n * 2 / 10);
|
|
1377
1371
|
}
|
|
1378
1372
|
return (10 - e % 10) % 10;
|
|
1379
1373
|
}
|
|
1380
|
-
function
|
|
1374
|
+
function Ja(t) {
|
|
1381
1375
|
for (var e = 0, r = [2, 3, 4, 5, 6, 7], n = 0; n < t.length; n++) {
|
|
1382
1376
|
var a = parseInt(t[t.length - 1 - n]);
|
|
1383
1377
|
e += r[n % r.length] * a;
|
|
1384
1378
|
}
|
|
1385
1379
|
return (11 - e % 11) % 11;
|
|
1386
1380
|
}
|
|
1387
|
-
Object.defineProperty(
|
|
1381
|
+
Object.defineProperty(Ae, "__esModule", {
|
|
1388
1382
|
value: !0
|
|
1389
1383
|
});
|
|
1390
|
-
var
|
|
1391
|
-
function
|
|
1384
|
+
var Ya = m, Qa = Za(Ya), Wa = $;
|
|
1385
|
+
function Za(t) {
|
|
1392
1386
|
return t && t.__esModule ? t : { default: t };
|
|
1393
1387
|
}
|
|
1394
|
-
function
|
|
1388
|
+
function Ka(t, e) {
|
|
1395
1389
|
if (!(t instanceof e))
|
|
1396
1390
|
throw new TypeError("Cannot call a class as a function");
|
|
1397
1391
|
}
|
|
1398
|
-
function
|
|
1392
|
+
function ei(t, e) {
|
|
1399
1393
|
if (!t)
|
|
1400
1394
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
1401
1395
|
return e && (typeof e == "object" || typeof e == "function") ? e : t;
|
|
1402
1396
|
}
|
|
1403
|
-
function
|
|
1397
|
+
function ti(t, e) {
|
|
1404
1398
|
if (typeof e != "function" && e !== null)
|
|
1405
1399
|
throw new TypeError("Super expression must either be null or a function, not " + typeof e);
|
|
1406
1400
|
t.prototype = Object.create(e && e.prototype, { constructor: { value: t, enumerable: !1, writable: !0, configurable: !0 } }), e && (Object.setPrototypeOf ? Object.setPrototypeOf(t, e) : t.__proto__ = e);
|
|
1407
1401
|
}
|
|
1408
|
-
var
|
|
1409
|
-
|
|
1402
|
+
var ni = function(t) {
|
|
1403
|
+
ti(e, t);
|
|
1410
1404
|
function e(r, n) {
|
|
1411
|
-
return
|
|
1405
|
+
return Ka(this, e), ei(this, (e.__proto__ || Object.getPrototypeOf(e)).call(this, r + (0, Wa.mod10)(r), n));
|
|
1412
1406
|
}
|
|
1413
1407
|
return e;
|
|
1414
|
-
}(
|
|
1415
|
-
|
|
1416
|
-
var
|
|
1417
|
-
Object.defineProperty(
|
|
1408
|
+
}(Qa.default);
|
|
1409
|
+
Ae.default = ni;
|
|
1410
|
+
var Re = {};
|
|
1411
|
+
Object.defineProperty(Re, "__esModule", {
|
|
1418
1412
|
value: !0
|
|
1419
1413
|
});
|
|
1420
|
-
var
|
|
1421
|
-
function
|
|
1414
|
+
var ri = m, ai = oi(ri), ii = $;
|
|
1415
|
+
function oi(t) {
|
|
1422
1416
|
return t && t.__esModule ? t : { default: t };
|
|
1423
1417
|
}
|
|
1424
|
-
function
|
|
1418
|
+
function ui(t, e) {
|
|
1425
1419
|
if (!(t instanceof e))
|
|
1426
1420
|
throw new TypeError("Cannot call a class as a function");
|
|
1427
1421
|
}
|
|
1428
|
-
function
|
|
1422
|
+
function fi(t, e) {
|
|
1429
1423
|
if (!t)
|
|
1430
1424
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
1431
1425
|
return e && (typeof e == "object" || typeof e == "function") ? e : t;
|
|
1432
1426
|
}
|
|
1433
|
-
function
|
|
1427
|
+
function ci(t, e) {
|
|
1434
1428
|
if (typeof e != "function" && e !== null)
|
|
1435
1429
|
throw new TypeError("Super expression must either be null or a function, not " + typeof e);
|
|
1436
1430
|
t.prototype = Object.create(e && e.prototype, { constructor: { value: t, enumerable: !1, writable: !0, configurable: !0 } }), e && (Object.setPrototypeOf ? Object.setPrototypeOf(t, e) : t.__proto__ = e);
|
|
1437
1431
|
}
|
|
1438
|
-
var
|
|
1439
|
-
|
|
1432
|
+
var li = function(t) {
|
|
1433
|
+
ci(e, t);
|
|
1440
1434
|
function e(r, n) {
|
|
1441
|
-
return
|
|
1435
|
+
return ui(this, e), fi(this, (e.__proto__ || Object.getPrototypeOf(e)).call(this, r + (0, ii.mod11)(r), n));
|
|
1442
1436
|
}
|
|
1443
1437
|
return e;
|
|
1444
|
-
}(
|
|
1445
|
-
|
|
1446
|
-
var
|
|
1447
|
-
Object.defineProperty(
|
|
1438
|
+
}(ai.default);
|
|
1439
|
+
Re.default = li;
|
|
1440
|
+
var Pe = {};
|
|
1441
|
+
Object.defineProperty(Pe, "__esModule", {
|
|
1448
1442
|
value: !0
|
|
1449
1443
|
});
|
|
1450
|
-
var
|
|
1451
|
-
function
|
|
1444
|
+
var hi = m, di = _i(hi), et = $;
|
|
1445
|
+
function _i(t) {
|
|
1452
1446
|
return t && t.__esModule ? t : { default: t };
|
|
1453
1447
|
}
|
|
1454
|
-
function
|
|
1448
|
+
function vi(t, e) {
|
|
1455
1449
|
if (!(t instanceof e))
|
|
1456
1450
|
throw new TypeError("Cannot call a class as a function");
|
|
1457
1451
|
}
|
|
1458
|
-
function
|
|
1452
|
+
function yi(t, e) {
|
|
1459
1453
|
if (!t)
|
|
1460
1454
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
1461
1455
|
return e && (typeof e == "object" || typeof e == "function") ? e : t;
|
|
1462
1456
|
}
|
|
1463
|
-
function
|
|
1457
|
+
function si(t, e) {
|
|
1464
1458
|
if (typeof e != "function" && e !== null)
|
|
1465
1459
|
throw new TypeError("Super expression must either be null or a function, not " + typeof e);
|
|
1466
1460
|
t.prototype = Object.create(e && e.prototype, { constructor: { value: t, enumerable: !1, writable: !0, configurable: !0 } }), e && (Object.setPrototypeOf ? Object.setPrototypeOf(t, e) : t.__proto__ = e);
|
|
1467
1461
|
}
|
|
1468
|
-
var
|
|
1469
|
-
|
|
1462
|
+
var pi = function(t) {
|
|
1463
|
+
si(e, t);
|
|
1470
1464
|
function e(r, n) {
|
|
1471
|
-
return
|
|
1465
|
+
return vi(this, e), r += (0, et.mod10)(r), r += (0, et.mod10)(r), yi(this, (e.__proto__ || Object.getPrototypeOf(e)).call(this, r, n));
|
|
1472
1466
|
}
|
|
1473
1467
|
return e;
|
|
1474
|
-
}(
|
|
1475
|
-
|
|
1476
|
-
var
|
|
1477
|
-
Object.defineProperty(
|
|
1468
|
+
}(di.default);
|
|
1469
|
+
Pe.default = pi;
|
|
1470
|
+
var Te = {};
|
|
1471
|
+
Object.defineProperty(Te, "__esModule", {
|
|
1478
1472
|
value: !0
|
|
1479
1473
|
});
|
|
1480
|
-
var
|
|
1481
|
-
function
|
|
1474
|
+
var gi = m, Oi = Ei(gi), tt = $;
|
|
1475
|
+
function Ei(t) {
|
|
1482
1476
|
return t && t.__esModule ? t : { default: t };
|
|
1483
1477
|
}
|
|
1484
|
-
function
|
|
1478
|
+
function bi(t, e) {
|
|
1485
1479
|
if (!(t instanceof e))
|
|
1486
1480
|
throw new TypeError("Cannot call a class as a function");
|
|
1487
1481
|
}
|
|
1488
|
-
function
|
|
1482
|
+
function wi(t, e) {
|
|
1489
1483
|
if (!t)
|
|
1490
1484
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
1491
1485
|
return e && (typeof e == "object" || typeof e == "function") ? e : t;
|
|
1492
1486
|
}
|
|
1493
|
-
function
|
|
1487
|
+
function mi(t, e) {
|
|
1494
1488
|
if (typeof e != "function" && e !== null)
|
|
1495
1489
|
throw new TypeError("Super expression must either be null or a function, not " + typeof e);
|
|
1496
1490
|
t.prototype = Object.create(e && e.prototype, { constructor: { value: t, enumerable: !1, writable: !0, configurable: !0 } }), e && (Object.setPrototypeOf ? Object.setPrototypeOf(t, e) : t.__proto__ = e);
|
|
1497
1491
|
}
|
|
1498
|
-
var
|
|
1499
|
-
|
|
1492
|
+
var $i = function(t) {
|
|
1493
|
+
mi(e, t);
|
|
1500
1494
|
function e(r, n) {
|
|
1501
|
-
return
|
|
1495
|
+
return bi(this, e), r += (0, tt.mod11)(r), r += (0, tt.mod10)(r), wi(this, (e.__proto__ || Object.getPrototypeOf(e)).call(this, r, n));
|
|
1502
1496
|
}
|
|
1503
1497
|
return e;
|
|
1504
|
-
}(
|
|
1505
|
-
|
|
1506
|
-
Object.defineProperty(
|
|
1498
|
+
}(Oi.default);
|
|
1499
|
+
Te.default = $i;
|
|
1500
|
+
Object.defineProperty(_, "__esModule", {
|
|
1507
1501
|
value: !0
|
|
1508
1502
|
});
|
|
1509
|
-
|
|
1510
|
-
var
|
|
1511
|
-
function
|
|
1503
|
+
_.MSI1110 = _.MSI1010 = _.MSI11 = _.MSI10 = _.MSI = void 0;
|
|
1504
|
+
var xi = m, Si = G(xi), Ai = Ae, Ri = G(Ai), Pi = Re, Ti = G(Pi), Mi = Pe, Ii = G(Mi), ki = Te, Di = G(ki);
|
|
1505
|
+
function G(t) {
|
|
1512
1506
|
return t && t.__esModule ? t : { default: t };
|
|
1513
1507
|
}
|
|
1514
|
-
|
|
1515
|
-
|
|
1516
|
-
|
|
1517
|
-
|
|
1518
|
-
|
|
1519
|
-
var
|
|
1520
|
-
Object.defineProperty(
|
|
1508
|
+
_.MSI = Si.default;
|
|
1509
|
+
_.MSI10 = Ri.default;
|
|
1510
|
+
_.MSI11 = Ti.default;
|
|
1511
|
+
_.MSI1010 = Ii.default;
|
|
1512
|
+
_.MSI1110 = Di.default;
|
|
1513
|
+
var Z = {};
|
|
1514
|
+
Object.defineProperty(Z, "__esModule", {
|
|
1521
1515
|
value: !0
|
|
1522
1516
|
});
|
|
1523
|
-
|
|
1524
|
-
var
|
|
1517
|
+
Z.pharmacode = void 0;
|
|
1518
|
+
var ji = function() {
|
|
1525
1519
|
function t(e, r) {
|
|
1526
1520
|
for (var n = 0; n < r.length; n++) {
|
|
1527
1521
|
var a = r[n];
|
|
@@ -1531,32 +1525,32 @@ var Qi = function() {
|
|
|
1531
1525
|
return function(e, r, n) {
|
|
1532
1526
|
return r && t(e.prototype, r), n && t(e, n), e;
|
|
1533
1527
|
};
|
|
1534
|
-
}(),
|
|
1535
|
-
function
|
|
1528
|
+
}(), Bi = c, Li = Ci(Bi);
|
|
1529
|
+
function Ci(t) {
|
|
1536
1530
|
return t && t.__esModule ? t : { default: t };
|
|
1537
1531
|
}
|
|
1538
|
-
function
|
|
1532
|
+
function Ni(t, e) {
|
|
1539
1533
|
if (!(t instanceof e))
|
|
1540
1534
|
throw new TypeError("Cannot call a class as a function");
|
|
1541
1535
|
}
|
|
1542
|
-
function
|
|
1536
|
+
function Gi(t, e) {
|
|
1543
1537
|
if (!t)
|
|
1544
1538
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
1545
1539
|
return e && (typeof e == "object" || typeof e == "function") ? e : t;
|
|
1546
1540
|
}
|
|
1547
|
-
function
|
|
1541
|
+
function Fi(t, e) {
|
|
1548
1542
|
if (typeof e != "function" && e !== null)
|
|
1549
1543
|
throw new TypeError("Super expression must either be null or a function, not " + typeof e);
|
|
1550
1544
|
t.prototype = Object.create(e && e.prototype, { constructor: { value: t, enumerable: !1, writable: !0, configurable: !0 } }), e && (Object.setPrototypeOf ? Object.setPrototypeOf(t, e) : t.__proto__ = e);
|
|
1551
1545
|
}
|
|
1552
|
-
var
|
|
1553
|
-
|
|
1546
|
+
var Hi = function(t) {
|
|
1547
|
+
Fi(e, t);
|
|
1554
1548
|
function e(r, n) {
|
|
1555
|
-
|
|
1556
|
-
var a =
|
|
1549
|
+
Ni(this, e);
|
|
1550
|
+
var a = Gi(this, (e.__proto__ || Object.getPrototypeOf(e)).call(this, r, n));
|
|
1557
1551
|
return a.number = parseInt(r, 10), a;
|
|
1558
1552
|
}
|
|
1559
|
-
return
|
|
1553
|
+
return ji(e, [{
|
|
1560
1554
|
key: "encode",
|
|
1561
1555
|
value: function() {
|
|
1562
1556
|
for (var n = this.number, a = ""; !isNaN(n) && n != 0; )
|
|
@@ -1572,14 +1566,14 @@ var ao = function(t) {
|
|
|
1572
1566
|
return this.number >= 3 && this.number <= 131070;
|
|
1573
1567
|
}
|
|
1574
1568
|
}]), e;
|
|
1575
|
-
}(
|
|
1576
|
-
|
|
1577
|
-
var
|
|
1578
|
-
Object.defineProperty(
|
|
1569
|
+
}(Li.default);
|
|
1570
|
+
Z.pharmacode = Hi;
|
|
1571
|
+
var K = {};
|
|
1572
|
+
Object.defineProperty(K, "__esModule", {
|
|
1579
1573
|
value: !0
|
|
1580
1574
|
});
|
|
1581
|
-
|
|
1582
|
-
var
|
|
1575
|
+
K.codabar = void 0;
|
|
1576
|
+
var Xi = function() {
|
|
1583
1577
|
function t(e, r) {
|
|
1584
1578
|
for (var n = 0; n < r.length; n++) {
|
|
1585
1579
|
var a = r[n];
|
|
@@ -1589,32 +1583,32 @@ var io = function() {
|
|
|
1589
1583
|
return function(e, r, n) {
|
|
1590
1584
|
return r && t(e.prototype, r), n && t(e, n), e;
|
|
1591
1585
|
};
|
|
1592
|
-
}(),
|
|
1593
|
-
function
|
|
1586
|
+
}(), zi = c, Ui = Vi(zi);
|
|
1587
|
+
function Vi(t) {
|
|
1594
1588
|
return t && t.__esModule ? t : { default: t };
|
|
1595
1589
|
}
|
|
1596
|
-
function
|
|
1590
|
+
function qi(t, e) {
|
|
1597
1591
|
if (!(t instanceof e))
|
|
1598
1592
|
throw new TypeError("Cannot call a class as a function");
|
|
1599
1593
|
}
|
|
1600
|
-
function
|
|
1594
|
+
function Ji(t, e) {
|
|
1601
1595
|
if (!t)
|
|
1602
1596
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
1603
1597
|
return e && (typeof e == "object" || typeof e == "function") ? e : t;
|
|
1604
1598
|
}
|
|
1605
|
-
function
|
|
1599
|
+
function Yi(t, e) {
|
|
1606
1600
|
if (typeof e != "function" && e !== null)
|
|
1607
1601
|
throw new TypeError("Super expression must either be null or a function, not " + typeof e);
|
|
1608
1602
|
t.prototype = Object.create(e && e.prototype, { constructor: { value: t, enumerable: !1, writable: !0, configurable: !0 } }), e && (Object.setPrototypeOf ? Object.setPrototypeOf(t, e) : t.__proto__ = e);
|
|
1609
1603
|
}
|
|
1610
|
-
var
|
|
1611
|
-
|
|
1604
|
+
var Qi = function(t) {
|
|
1605
|
+
Yi(e, t);
|
|
1612
1606
|
function e(r, n) {
|
|
1613
|
-
|
|
1614
|
-
var a =
|
|
1607
|
+
qi(this, e), r.search(/^[0-9\-\$\:\.\+\/]+$/) === 0 && (r = "A" + r + "A");
|
|
1608
|
+
var a = Ji(this, (e.__proto__ || Object.getPrototypeOf(e)).call(this, r.toUpperCase(), n));
|
|
1615
1609
|
return a.text = a.options.text || a.text.replace(/[A-D]/g, ""), a;
|
|
1616
1610
|
}
|
|
1617
|
-
return
|
|
1611
|
+
return Xi(e, [{
|
|
1618
1612
|
key: "valid",
|
|
1619
1613
|
value: function() {
|
|
1620
1614
|
return this.data.search(/^[A-D][0-9\-\$\:\.\+\/]+[A-D]$/) !== -1;
|
|
@@ -1656,13 +1650,13 @@ var _o = function(t) {
|
|
|
1656
1650
|
};
|
|
1657
1651
|
}
|
|
1658
1652
|
}]), e;
|
|
1659
|
-
}(
|
|
1660
|
-
|
|
1661
|
-
var
|
|
1662
|
-
Object.defineProperty(
|
|
1653
|
+
}(Ui.default);
|
|
1654
|
+
K.codabar = Qi;
|
|
1655
|
+
var P = {}, ee = {}, F = {};
|
|
1656
|
+
Object.defineProperty(F, "__esModule", {
|
|
1663
1657
|
value: !0
|
|
1664
1658
|
});
|
|
1665
|
-
|
|
1659
|
+
F.SYMBOLS = [
|
|
1666
1660
|
"0",
|
|
1667
1661
|
"1",
|
|
1668
1662
|
"2",
|
|
@@ -1714,8 +1708,8 @@ X.SYMBOLS = [
|
|
|
1714
1708
|
// Start/Stop
|
|
1715
1709
|
"ÿ"
|
|
1716
1710
|
];
|
|
1717
|
-
|
|
1718
|
-
|
|
1711
|
+
F.BINARIES = ["100010100", "101001000", "101000100", "101000010", "100101000", "100100100", "100100010", "101010000", "100010010", "100001010", "110101000", "110100100", "110100010", "110010100", "110010010", "110001010", "101101000", "101100100", "101100010", "100110100", "100011010", "101011000", "101001100", "101000110", "100101100", "100010110", "110110100", "110110010", "110101100", "110100110", "110010110", "110011010", "101101100", "101100110", "100110110", "100111010", "100101110", "111010100", "111010010", "111001010", "101101110", "101110110", "110101110", "100100110", "111011010", "111010110", "100110010", "101011110"];
|
|
1712
|
+
F.MULTI_SYMBOLS = {
|
|
1719
1713
|
"\0": ["(%)", "U"],
|
|
1720
1714
|
"": ["($)", "A"],
|
|
1721
1715
|
"": ["($)", "B"],
|
|
@@ -1802,10 +1796,10 @@ X.MULTI_SYMBOLS = {
|
|
|
1802
1796
|
"~": ["(%)", "S"],
|
|
1803
1797
|
"": ["(%)", "T"]
|
|
1804
1798
|
};
|
|
1805
|
-
Object.defineProperty(
|
|
1799
|
+
Object.defineProperty(ee, "__esModule", {
|
|
1806
1800
|
value: !0
|
|
1807
1801
|
});
|
|
1808
|
-
var
|
|
1802
|
+
var Wi = function() {
|
|
1809
1803
|
function t(e, r) {
|
|
1810
1804
|
for (var n = 0; n < r.length; n++) {
|
|
1811
1805
|
var a = r[n];
|
|
@@ -1815,30 +1809,30 @@ var vo = function() {
|
|
|
1815
1809
|
return function(e, r, n) {
|
|
1816
1810
|
return r && t(e.prototype, r), n && t(e, n), e;
|
|
1817
1811
|
};
|
|
1818
|
-
}(),
|
|
1819
|
-
function
|
|
1812
|
+
}(), U = F, Zi = c, Ki = eo(Zi);
|
|
1813
|
+
function eo(t) {
|
|
1820
1814
|
return t && t.__esModule ? t : { default: t };
|
|
1821
1815
|
}
|
|
1822
|
-
function
|
|
1816
|
+
function to(t, e) {
|
|
1823
1817
|
if (!(t instanceof e))
|
|
1824
1818
|
throw new TypeError("Cannot call a class as a function");
|
|
1825
1819
|
}
|
|
1826
|
-
function
|
|
1820
|
+
function no(t, e) {
|
|
1827
1821
|
if (!t)
|
|
1828
1822
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
1829
1823
|
return e && (typeof e == "object" || typeof e == "function") ? e : t;
|
|
1830
1824
|
}
|
|
1831
|
-
function
|
|
1825
|
+
function ro(t, e) {
|
|
1832
1826
|
if (typeof e != "function" && e !== null)
|
|
1833
1827
|
throw new TypeError("Super expression must either be null or a function, not " + typeof e);
|
|
1834
1828
|
t.prototype = Object.create(e && e.prototype, { constructor: { value: t, enumerable: !1, writable: !0, configurable: !0 } }), e && (Object.setPrototypeOf ? Object.setPrototypeOf(t, e) : t.__proto__ = e);
|
|
1835
1829
|
}
|
|
1836
|
-
var
|
|
1837
|
-
|
|
1830
|
+
var ao = function(t) {
|
|
1831
|
+
ro(e, t);
|
|
1838
1832
|
function e(r, n) {
|
|
1839
|
-
return
|
|
1833
|
+
return to(this, e), no(this, (e.__proto__ || Object.getPrototypeOf(e)).call(this, r, n));
|
|
1840
1834
|
}
|
|
1841
|
-
return
|
|
1835
|
+
return Wi(e, [{
|
|
1842
1836
|
key: "valid",
|
|
1843
1837
|
value: function() {
|
|
1844
1838
|
return /^[0-9A-Z\-. $/+%]+$/.test(this.data);
|
|
@@ -1847,7 +1841,7 @@ var bo = function(t) {
|
|
|
1847
1841
|
key: "encode",
|
|
1848
1842
|
value: function() {
|
|
1849
1843
|
var n = this.data.split("").flatMap(function(u) {
|
|
1850
|
-
return
|
|
1844
|
+
return U.MULTI_SYMBOLS[u] || u;
|
|
1851
1845
|
}), a = n.map(function(u) {
|
|
1852
1846
|
return e.getEncoding(u);
|
|
1853
1847
|
}).join(""), i = e.checksum(n, 20), o = e.checksum(n.concat(i), 15);
|
|
@@ -1867,38 +1861,38 @@ var bo = function(t) {
|
|
|
1867
1861
|
}], [{
|
|
1868
1862
|
key: "getEncoding",
|
|
1869
1863
|
value: function(n) {
|
|
1870
|
-
return
|
|
1864
|
+
return U.BINARIES[e.symbolValue(n)];
|
|
1871
1865
|
}
|
|
1872
1866
|
// Get the symbol for a symbol value
|
|
1873
1867
|
}, {
|
|
1874
1868
|
key: "getSymbol",
|
|
1875
1869
|
value: function(n) {
|
|
1876
|
-
return
|
|
1870
|
+
return U.SYMBOLS[n];
|
|
1877
1871
|
}
|
|
1878
1872
|
// Get the symbol value of a symbol
|
|
1879
1873
|
}, {
|
|
1880
1874
|
key: "symbolValue",
|
|
1881
1875
|
value: function(n) {
|
|
1882
|
-
return
|
|
1876
|
+
return U.SYMBOLS.indexOf(n);
|
|
1883
1877
|
}
|
|
1884
1878
|
// Calculate a checksum symbol
|
|
1885
1879
|
}, {
|
|
1886
1880
|
key: "checksum",
|
|
1887
1881
|
value: function(n, a) {
|
|
1888
|
-
var i = n.slice().reverse().reduce(function(o, u,
|
|
1889
|
-
var
|
|
1890
|
-
return o + e.symbolValue(u) *
|
|
1882
|
+
var i = n.slice().reverse().reduce(function(o, u, y) {
|
|
1883
|
+
var g = y % a + 1;
|
|
1884
|
+
return o + e.symbolValue(u) * g;
|
|
1891
1885
|
}, 0);
|
|
1892
1886
|
return e.getSymbol(i % 47);
|
|
1893
1887
|
}
|
|
1894
1888
|
}]), e;
|
|
1895
|
-
}(
|
|
1896
|
-
|
|
1897
|
-
var
|
|
1898
|
-
Object.defineProperty(
|
|
1889
|
+
}(Ki.default);
|
|
1890
|
+
ee.default = ao;
|
|
1891
|
+
var Me = {};
|
|
1892
|
+
Object.defineProperty(Me, "__esModule", {
|
|
1899
1893
|
value: !0
|
|
1900
1894
|
});
|
|
1901
|
-
var
|
|
1895
|
+
var io = function() {
|
|
1902
1896
|
function t(e, r) {
|
|
1903
1897
|
for (var n = 0; n < r.length; n++) {
|
|
1904
1898
|
var a = r[n];
|
|
@@ -1908,53 +1902,53 @@ var mo = function() {
|
|
|
1908
1902
|
return function(e, r, n) {
|
|
1909
1903
|
return r && t(e.prototype, r), n && t(e, n), e;
|
|
1910
1904
|
};
|
|
1911
|
-
}(),
|
|
1912
|
-
function
|
|
1905
|
+
}(), oo = ee, uo = fo(oo);
|
|
1906
|
+
function fo(t) {
|
|
1913
1907
|
return t && t.__esModule ? t : { default: t };
|
|
1914
1908
|
}
|
|
1915
|
-
function
|
|
1909
|
+
function co(t, e) {
|
|
1916
1910
|
if (!(t instanceof e))
|
|
1917
1911
|
throw new TypeError("Cannot call a class as a function");
|
|
1918
1912
|
}
|
|
1919
|
-
function
|
|
1913
|
+
function lo(t, e) {
|
|
1920
1914
|
if (!t)
|
|
1921
1915
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
1922
1916
|
return e && (typeof e == "object" || typeof e == "function") ? e : t;
|
|
1923
1917
|
}
|
|
1924
|
-
function
|
|
1918
|
+
function ho(t, e) {
|
|
1925
1919
|
if (typeof e != "function" && e !== null)
|
|
1926
1920
|
throw new TypeError("Super expression must either be null or a function, not " + typeof e);
|
|
1927
1921
|
t.prototype = Object.create(e && e.prototype, { constructor: { value: t, enumerable: !1, writable: !0, configurable: !0 } }), e && (Object.setPrototypeOf ? Object.setPrototypeOf(t, e) : t.__proto__ = e);
|
|
1928
1922
|
}
|
|
1929
|
-
var
|
|
1930
|
-
|
|
1923
|
+
var _o = function(t) {
|
|
1924
|
+
ho(e, t);
|
|
1931
1925
|
function e(r, n) {
|
|
1932
|
-
return
|
|
1926
|
+
return co(this, e), lo(this, (e.__proto__ || Object.getPrototypeOf(e)).call(this, r, n));
|
|
1933
1927
|
}
|
|
1934
|
-
return
|
|
1928
|
+
return io(e, [{
|
|
1935
1929
|
key: "valid",
|
|
1936
1930
|
value: function() {
|
|
1937
1931
|
return /^[\x00-\x7f]+$/.test(this.data);
|
|
1938
1932
|
}
|
|
1939
1933
|
}]), e;
|
|
1940
|
-
}(
|
|
1941
|
-
|
|
1942
|
-
Object.defineProperty(
|
|
1934
|
+
}(uo.default);
|
|
1935
|
+
Me.default = _o;
|
|
1936
|
+
Object.defineProperty(P, "__esModule", {
|
|
1943
1937
|
value: !0
|
|
1944
1938
|
});
|
|
1945
|
-
|
|
1946
|
-
var
|
|
1947
|
-
function
|
|
1939
|
+
P.CODE93FullASCII = P.CODE93 = void 0;
|
|
1940
|
+
var vo = ee, yo = $t(vo), so = Me, po = $t(so);
|
|
1941
|
+
function $t(t) {
|
|
1948
1942
|
return t && t.__esModule ? t : { default: t };
|
|
1949
1943
|
}
|
|
1950
|
-
|
|
1951
|
-
|
|
1952
|
-
var
|
|
1953
|
-
Object.defineProperty(
|
|
1944
|
+
P.CODE93 = yo.default;
|
|
1945
|
+
P.CODE93FullASCII = po.default;
|
|
1946
|
+
var te = {};
|
|
1947
|
+
Object.defineProperty(te, "__esModule", {
|
|
1954
1948
|
value: !0
|
|
1955
1949
|
});
|
|
1956
|
-
|
|
1957
|
-
var
|
|
1950
|
+
te.GenericBarcode = void 0;
|
|
1951
|
+
var go = function() {
|
|
1958
1952
|
function t(e, r) {
|
|
1959
1953
|
for (var n = 0; n < r.length; n++) {
|
|
1960
1954
|
var a = r[n];
|
|
@@ -1964,30 +1958,30 @@ var Do = function() {
|
|
|
1964
1958
|
return function(e, r, n) {
|
|
1965
1959
|
return r && t(e.prototype, r), n && t(e, n), e;
|
|
1966
1960
|
};
|
|
1967
|
-
}(),
|
|
1968
|
-
function
|
|
1961
|
+
}(), Oo = c, Eo = bo(Oo);
|
|
1962
|
+
function bo(t) {
|
|
1969
1963
|
return t && t.__esModule ? t : { default: t };
|
|
1970
1964
|
}
|
|
1971
|
-
function
|
|
1965
|
+
function wo(t, e) {
|
|
1972
1966
|
if (!(t instanceof e))
|
|
1973
1967
|
throw new TypeError("Cannot call a class as a function");
|
|
1974
1968
|
}
|
|
1975
|
-
function
|
|
1969
|
+
function mo(t, e) {
|
|
1976
1970
|
if (!t)
|
|
1977
1971
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
1978
1972
|
return e && (typeof e == "object" || typeof e == "function") ? e : t;
|
|
1979
1973
|
}
|
|
1980
|
-
function
|
|
1974
|
+
function $o(t, e) {
|
|
1981
1975
|
if (typeof e != "function" && e !== null)
|
|
1982
1976
|
throw new TypeError("Super expression must either be null or a function, not " + typeof e);
|
|
1983
1977
|
t.prototype = Object.create(e && e.prototype, { constructor: { value: t, enumerable: !1, writable: !0, configurable: !0 } }), e && (Object.setPrototypeOf ? Object.setPrototypeOf(t, e) : t.__proto__ = e);
|
|
1984
1978
|
}
|
|
1985
|
-
var
|
|
1986
|
-
|
|
1979
|
+
var xo = function(t) {
|
|
1980
|
+
$o(e, t);
|
|
1987
1981
|
function e(r, n) {
|
|
1988
|
-
return
|
|
1982
|
+
return wo(this, e), mo(this, (e.__proto__ || Object.getPrototypeOf(e)).call(this, r, n));
|
|
1989
1983
|
}
|
|
1990
|
-
return
|
|
1984
|
+
return go(e, [{
|
|
1991
1985
|
key: "encode",
|
|
1992
1986
|
value: function() {
|
|
1993
1987
|
return {
|
|
@@ -2002,42 +1996,42 @@ var Fo = function(t) {
|
|
|
2002
1996
|
return !0;
|
|
2003
1997
|
}
|
|
2004
1998
|
}]), e;
|
|
2005
|
-
}(
|
|
2006
|
-
|
|
2007
|
-
Object.defineProperty(
|
|
1999
|
+
}(Eo.default);
|
|
2000
|
+
te.GenericBarcode = xo;
|
|
2001
|
+
Object.defineProperty(ve, "__esModule", {
|
|
2008
2002
|
value: !0
|
|
2009
2003
|
});
|
|
2010
|
-
var
|
|
2011
|
-
|
|
2012
|
-
CODE39:
|
|
2013
|
-
CODE128:
|
|
2014
|
-
CODE128A:
|
|
2015
|
-
CODE128B:
|
|
2016
|
-
CODE128C:
|
|
2017
|
-
EAN13:
|
|
2018
|
-
EAN8:
|
|
2019
|
-
EAN5:
|
|
2020
|
-
EAN2:
|
|
2021
|
-
UPC:
|
|
2022
|
-
UPCE:
|
|
2023
|
-
ITF14:
|
|
2024
|
-
ITF:
|
|
2025
|
-
MSI:
|
|
2026
|
-
MSI10:
|
|
2027
|
-
MSI11:
|
|
2028
|
-
MSI1010:
|
|
2029
|
-
MSI1110:
|
|
2030
|
-
pharmacode:
|
|
2031
|
-
codabar:
|
|
2032
|
-
CODE93:
|
|
2033
|
-
CODE93FullASCII:
|
|
2034
|
-
GenericBarcode:
|
|
2004
|
+
var So = J, V = s, A = l, nt = R, B = _, Ao = Z, Ro = K, rt = P, Po = te;
|
|
2005
|
+
ve.default = {
|
|
2006
|
+
CODE39: So.CODE39,
|
|
2007
|
+
CODE128: V.CODE128,
|
|
2008
|
+
CODE128A: V.CODE128A,
|
|
2009
|
+
CODE128B: V.CODE128B,
|
|
2010
|
+
CODE128C: V.CODE128C,
|
|
2011
|
+
EAN13: A.EAN13,
|
|
2012
|
+
EAN8: A.EAN8,
|
|
2013
|
+
EAN5: A.EAN5,
|
|
2014
|
+
EAN2: A.EAN2,
|
|
2015
|
+
UPC: A.UPC,
|
|
2016
|
+
UPCE: A.UPCE,
|
|
2017
|
+
ITF14: nt.ITF14,
|
|
2018
|
+
ITF: nt.ITF,
|
|
2019
|
+
MSI: B.MSI,
|
|
2020
|
+
MSI10: B.MSI10,
|
|
2021
|
+
MSI11: B.MSI11,
|
|
2022
|
+
MSI1010: B.MSI1010,
|
|
2023
|
+
MSI1110: B.MSI1110,
|
|
2024
|
+
pharmacode: Ao.pharmacode,
|
|
2025
|
+
codabar: Ro.codabar,
|
|
2026
|
+
CODE93: rt.CODE93,
|
|
2027
|
+
CODE93FullASCII: rt.CODE93FullASCII,
|
|
2028
|
+
GenericBarcode: Po.GenericBarcode
|
|
2035
2029
|
};
|
|
2036
|
-
var
|
|
2037
|
-
Object.defineProperty(
|
|
2030
|
+
var I = {};
|
|
2031
|
+
Object.defineProperty(I, "__esModule", {
|
|
2038
2032
|
value: !0
|
|
2039
2033
|
});
|
|
2040
|
-
var
|
|
2034
|
+
var To = Object.assign || function(t) {
|
|
2041
2035
|
for (var e = 1; e < arguments.length; e++) {
|
|
2042
2036
|
var r = arguments[e];
|
|
2043
2037
|
for (var n in r)
|
|
@@ -2045,15 +2039,15 @@ var Vo = Object.assign || function(t) {
|
|
|
2045
2039
|
}
|
|
2046
2040
|
return t;
|
|
2047
2041
|
};
|
|
2048
|
-
|
|
2049
|
-
return
|
|
2042
|
+
I.default = function(t, e) {
|
|
2043
|
+
return To({}, t, e);
|
|
2050
2044
|
};
|
|
2051
|
-
var
|
|
2052
|
-
Object.defineProperty(
|
|
2045
|
+
var Ie = {};
|
|
2046
|
+
Object.defineProperty(Ie, "__esModule", {
|
|
2053
2047
|
value: !0
|
|
2054
2048
|
});
|
|
2055
|
-
|
|
2056
|
-
function
|
|
2049
|
+
Ie.default = Mo;
|
|
2050
|
+
function Mo(t) {
|
|
2057
2051
|
var e = [];
|
|
2058
2052
|
function r(n) {
|
|
2059
2053
|
if (Array.isArray(n))
|
|
@@ -2064,30 +2058,30 @@ function qo(t) {
|
|
|
2064
2058
|
}
|
|
2065
2059
|
return r(t), e;
|
|
2066
2060
|
}
|
|
2067
|
-
var
|
|
2068
|
-
Object.defineProperty(
|
|
2061
|
+
var ke = {};
|
|
2062
|
+
Object.defineProperty(ke, "__esModule", {
|
|
2069
2063
|
value: !0
|
|
2070
2064
|
});
|
|
2071
|
-
|
|
2072
|
-
function
|
|
2065
|
+
ke.default = Io;
|
|
2066
|
+
function Io(t) {
|
|
2073
2067
|
return t.marginTop = t.marginTop || t.margin, t.marginBottom = t.marginBottom || t.margin, t.marginRight = t.marginRight || t.margin, t.marginLeft = t.marginLeft || t.margin, t;
|
|
2074
2068
|
}
|
|
2075
|
-
var
|
|
2076
|
-
Object.defineProperty(
|
|
2069
|
+
var De = {}, je = {}, ne = {};
|
|
2070
|
+
Object.defineProperty(ne, "__esModule", {
|
|
2077
2071
|
value: !0
|
|
2078
2072
|
});
|
|
2079
|
-
|
|
2080
|
-
function
|
|
2073
|
+
ne.default = ko;
|
|
2074
|
+
function ko(t) {
|
|
2081
2075
|
var e = ["width", "height", "textMargin", "fontSize", "margin", "marginTop", "marginBottom", "marginLeft", "marginRight"];
|
|
2082
2076
|
for (var r in e)
|
|
2083
2077
|
e.hasOwnProperty(r) && (r = e[r], typeof t[r] == "string" && (t[r] = parseInt(t[r], 10)));
|
|
2084
2078
|
return typeof t.displayValue == "string" && (t.displayValue = t.displayValue != "false"), t;
|
|
2085
2079
|
}
|
|
2086
|
-
var
|
|
2087
|
-
Object.defineProperty(
|
|
2080
|
+
var re = {};
|
|
2081
|
+
Object.defineProperty(re, "__esModule", {
|
|
2088
2082
|
value: !0
|
|
2089
2083
|
});
|
|
2090
|
-
var
|
|
2084
|
+
var Do = {
|
|
2091
2085
|
width: 2,
|
|
2092
2086
|
height: 100,
|
|
2093
2087
|
format: "auto",
|
|
@@ -2109,34 +2103,34 @@ var Wo = {
|
|
|
2109
2103
|
valid: function() {
|
|
2110
2104
|
}
|
|
2111
2105
|
};
|
|
2112
|
-
|
|
2113
|
-
Object.defineProperty(
|
|
2106
|
+
re.default = Do;
|
|
2107
|
+
Object.defineProperty(je, "__esModule", {
|
|
2114
2108
|
value: !0
|
|
2115
2109
|
});
|
|
2116
|
-
var
|
|
2117
|
-
function
|
|
2110
|
+
var jo = ne, Bo = xt(jo), Lo = re, at = xt(Lo);
|
|
2111
|
+
function xt(t) {
|
|
2118
2112
|
return t && t.__esModule ? t : { default: t };
|
|
2119
2113
|
}
|
|
2120
|
-
function
|
|
2114
|
+
function Co(t) {
|
|
2121
2115
|
var e = {};
|
|
2122
|
-
for (var r in
|
|
2123
|
-
|
|
2124
|
-
return e.value = t.getAttribute("jsbarcode-value") || t.getAttribute("data-value"), e = (0,
|
|
2116
|
+
for (var r in at.default)
|
|
2117
|
+
at.default.hasOwnProperty(r) && (t.hasAttribute("jsbarcode-" + r.toLowerCase()) && (e[r] = t.getAttribute("jsbarcode-" + r.toLowerCase())), t.hasAttribute("data-" + r.toLowerCase()) && (e[r] = t.getAttribute("data-" + r.toLowerCase())));
|
|
2118
|
+
return e.value = t.getAttribute("jsbarcode-value") || t.getAttribute("data-value"), e = (0, Bo.default)(e), e;
|
|
2125
2119
|
}
|
|
2126
|
-
|
|
2127
|
-
var
|
|
2128
|
-
Object.defineProperty(
|
|
2120
|
+
je.default = Co;
|
|
2121
|
+
var Be = {}, Le = {}, d = {};
|
|
2122
|
+
Object.defineProperty(d, "__esModule", {
|
|
2129
2123
|
value: !0
|
|
2130
2124
|
});
|
|
2131
|
-
|
|
2132
|
-
var
|
|
2133
|
-
function
|
|
2125
|
+
d.getTotalWidthOfEncodings = d.calculateEncodingAttributes = d.getBarcodePadding = d.getEncodingHeight = d.getMaximumHeightOfEncodings = void 0;
|
|
2126
|
+
var No = I, Go = Fo(No);
|
|
2127
|
+
function Fo(t) {
|
|
2134
2128
|
return t && t.__esModule ? t : { default: t };
|
|
2135
2129
|
}
|
|
2136
|
-
function
|
|
2130
|
+
function St(t, e) {
|
|
2137
2131
|
return e.height + (e.displayValue && t.text.length > 0 ? e.fontSize + e.textMargin : 0) + e.marginTop + e.marginBottom;
|
|
2138
2132
|
}
|
|
2139
|
-
function
|
|
2133
|
+
function At(t, e, r) {
|
|
2140
2134
|
if (r.displayValue && e < t) {
|
|
2141
2135
|
if (r.textAlign == "center")
|
|
2142
2136
|
return Math.floor((t - e) / 2);
|
|
@@ -2147,25 +2141,25 @@ function Mt(t, e, r) {
|
|
|
2147
2141
|
}
|
|
2148
2142
|
return 0;
|
|
2149
2143
|
}
|
|
2150
|
-
function
|
|
2144
|
+
function Ho(t, e, r) {
|
|
2151
2145
|
for (var n = 0; n < t.length; n++) {
|
|
2152
|
-
var a = t[n], i = (0,
|
|
2153
|
-
i.displayValue ? o =
|
|
2146
|
+
var a = t[n], i = (0, Go.default)(e, a.options), o;
|
|
2147
|
+
i.displayValue ? o = Uo(a.text, i, r) : o = 0;
|
|
2154
2148
|
var u = a.data.length * i.width;
|
|
2155
|
-
a.width = Math.ceil(Math.max(o, u)), a.height =
|
|
2149
|
+
a.width = Math.ceil(Math.max(o, u)), a.height = St(a, i), a.barcodePadding = At(o, u, i);
|
|
2156
2150
|
}
|
|
2157
2151
|
}
|
|
2158
|
-
function
|
|
2152
|
+
function Xo(t) {
|
|
2159
2153
|
for (var e = 0, r = 0; r < t.length; r++)
|
|
2160
2154
|
e += t[r].width;
|
|
2161
2155
|
return e;
|
|
2162
2156
|
}
|
|
2163
|
-
function
|
|
2157
|
+
function zo(t) {
|
|
2164
2158
|
for (var e = 0, r = 0; r < t.length; r++)
|
|
2165
2159
|
t[r].height > e && (e = t[r].height);
|
|
2166
2160
|
return e;
|
|
2167
2161
|
}
|
|
2168
|
-
function
|
|
2162
|
+
function Uo(t, e, r) {
|
|
2169
2163
|
var n;
|
|
2170
2164
|
if (r)
|
|
2171
2165
|
n = r;
|
|
@@ -2180,15 +2174,15 @@ function uu(t, e, r) {
|
|
|
2180
2174
|
var i = a.width;
|
|
2181
2175
|
return i;
|
|
2182
2176
|
}
|
|
2183
|
-
|
|
2184
|
-
|
|
2185
|
-
|
|
2186
|
-
|
|
2187
|
-
|
|
2188
|
-
Object.defineProperty(
|
|
2177
|
+
d.getMaximumHeightOfEncodings = zo;
|
|
2178
|
+
d.getEncodingHeight = St;
|
|
2179
|
+
d.getBarcodePadding = At;
|
|
2180
|
+
d.calculateEncodingAttributes = Ho;
|
|
2181
|
+
d.getTotalWidthOfEncodings = Xo;
|
|
2182
|
+
Object.defineProperty(Le, "__esModule", {
|
|
2189
2183
|
value: !0
|
|
2190
2184
|
});
|
|
2191
|
-
var
|
|
2185
|
+
var Vo = function() {
|
|
2192
2186
|
function t(e, r) {
|
|
2193
2187
|
for (var n = 0; n < r.length; n++) {
|
|
2194
2188
|
var a = r[n];
|
|
@@ -2198,26 +2192,26 @@ var fu = function() {
|
|
|
2198
2192
|
return function(e, r, n) {
|
|
2199
2193
|
return r && t(e.prototype, r), n && t(e, n), e;
|
|
2200
2194
|
};
|
|
2201
|
-
}(),
|
|
2202
|
-
function
|
|
2195
|
+
}(), qo = I, Jo = Yo(qo), ce = d;
|
|
2196
|
+
function Yo(t) {
|
|
2203
2197
|
return t && t.__esModule ? t : { default: t };
|
|
2204
2198
|
}
|
|
2205
|
-
function
|
|
2199
|
+
function Qo(t, e) {
|
|
2206
2200
|
if (!(t instanceof e))
|
|
2207
2201
|
throw new TypeError("Cannot call a class as a function");
|
|
2208
2202
|
}
|
|
2209
|
-
var
|
|
2203
|
+
var Wo = function() {
|
|
2210
2204
|
function t(e, r, n) {
|
|
2211
|
-
|
|
2205
|
+
Qo(this, t), this.canvas = e, this.encodings = r, this.options = n;
|
|
2212
2206
|
}
|
|
2213
|
-
return
|
|
2207
|
+
return Vo(t, [{
|
|
2214
2208
|
key: "render",
|
|
2215
2209
|
value: function() {
|
|
2216
2210
|
if (!this.canvas.getContext)
|
|
2217
2211
|
throw new Error("The browser does not support canvas.");
|
|
2218
2212
|
this.prepareCanvas();
|
|
2219
2213
|
for (var r = 0; r < this.encodings.length; r++) {
|
|
2220
|
-
var n = (0,
|
|
2214
|
+
var n = (0, Jo.default)(this.options, this.encodings[r].options);
|
|
2221
2215
|
this.drawCanvasBarcode(n, this.encodings[r]), this.drawCanvasText(n, this.encodings[r]), this.moveCanvasDrawing(this.encodings[r]);
|
|
2222
2216
|
}
|
|
2223
2217
|
this.restoreCanvas();
|
|
@@ -2226,8 +2220,8 @@ var _u = function() {
|
|
|
2226
2220
|
key: "prepareCanvas",
|
|
2227
2221
|
value: function() {
|
|
2228
2222
|
var r = this.canvas.getContext("2d");
|
|
2229
|
-
r.save(), (0,
|
|
2230
|
-
var n = (0,
|
|
2223
|
+
r.save(), (0, ce.calculateEncodingAttributes)(this.encodings, this.options, r);
|
|
2224
|
+
var n = (0, ce.getTotalWidthOfEncodings)(this.encodings), a = (0, ce.getMaximumHeightOfEncodings)(this.encodings);
|
|
2231
2225
|
this.canvas.width = n + this.options.marginLeft + this.options.marginRight, this.canvas.height = a, r.clearRect(0, 0, this.canvas.width, this.canvas.height), this.options.background && (r.fillStyle = this.options.background, r.fillRect(0, 0, this.canvas.width, this.canvas.height)), r.translate(this.options.marginLeft, 0);
|
|
2232
2226
|
}
|
|
2233
2227
|
}, {
|
|
@@ -2236,8 +2230,8 @@ var _u = function() {
|
|
|
2236
2230
|
var a = this.canvas.getContext("2d"), i = n.data, o;
|
|
2237
2231
|
r.textPosition == "top" ? o = r.marginTop + r.fontSize + r.textMargin : o = r.marginTop, a.fillStyle = r.lineColor;
|
|
2238
2232
|
for (var u = 0; u < i.length; u++) {
|
|
2239
|
-
var
|
|
2240
|
-
i[u] === "1" ? a.fillRect(
|
|
2233
|
+
var y = u * r.width + n.barcodePadding;
|
|
2234
|
+
i[u] === "1" ? a.fillRect(y, o, r.width, r.height) : i[u] && a.fillRect(y, o, r.width, r.height * i[u]);
|
|
2241
2235
|
}
|
|
2242
2236
|
}
|
|
2243
2237
|
}, {
|
|
@@ -2263,12 +2257,12 @@ var _u = function() {
|
|
|
2263
2257
|
}
|
|
2264
2258
|
}]), t;
|
|
2265
2259
|
}();
|
|
2266
|
-
|
|
2267
|
-
var
|
|
2268
|
-
Object.defineProperty(
|
|
2260
|
+
Le.default = Wo;
|
|
2261
|
+
var Ce = {};
|
|
2262
|
+
Object.defineProperty(Ce, "__esModule", {
|
|
2269
2263
|
value: !0
|
|
2270
2264
|
});
|
|
2271
|
-
var
|
|
2265
|
+
var Zo = function() {
|
|
2272
2266
|
function t(e, r) {
|
|
2273
2267
|
for (var n = 0; n < r.length; n++) {
|
|
2274
2268
|
var a = r[n];
|
|
@@ -2278,25 +2272,25 @@ var vu = function() {
|
|
|
2278
2272
|
return function(e, r, n) {
|
|
2279
2273
|
return r && t(e.prototype, r), n && t(e, n), e;
|
|
2280
2274
|
};
|
|
2281
|
-
}(),
|
|
2282
|
-
function
|
|
2275
|
+
}(), Ko = I, eu = tu(Ko), le = d;
|
|
2276
|
+
function tu(t) {
|
|
2283
2277
|
return t && t.__esModule ? t : { default: t };
|
|
2284
2278
|
}
|
|
2285
|
-
function
|
|
2279
|
+
function nu(t, e) {
|
|
2286
2280
|
if (!(t instanceof e))
|
|
2287
2281
|
throw new TypeError("Cannot call a class as a function");
|
|
2288
2282
|
}
|
|
2289
|
-
var
|
|
2283
|
+
var q = "http://www.w3.org/2000/svg", ru = function() {
|
|
2290
2284
|
function t(e, r, n) {
|
|
2291
|
-
|
|
2285
|
+
nu(this, t), this.svg = e, this.encodings = r, this.options = n, this.document = n.xmlDocument || document;
|
|
2292
2286
|
}
|
|
2293
|
-
return
|
|
2287
|
+
return Zo(t, [{
|
|
2294
2288
|
key: "render",
|
|
2295
2289
|
value: function() {
|
|
2296
2290
|
var r = this.options.marginLeft;
|
|
2297
2291
|
this.prepareSVG();
|
|
2298
2292
|
for (var n = 0; n < this.encodings.length; n++) {
|
|
2299
|
-
var a = this.encodings[n], i = (0,
|
|
2293
|
+
var a = this.encodings[n], i = (0, eu.default)(this.options, a.options), o = this.createGroup(r, i.marginTop, this.svg);
|
|
2300
2294
|
this.setGroupOptions(o, i), this.drawSvgBarcode(o, i, a), this.drawSVGText(o, i, a), r += a.width;
|
|
2301
2295
|
}
|
|
2302
2296
|
}
|
|
@@ -2305,8 +2299,8 @@ var Q = "http://www.w3.org/2000/svg", Ou = function() {
|
|
|
2305
2299
|
value: function() {
|
|
2306
2300
|
for (; this.svg.firstChild; )
|
|
2307
2301
|
this.svg.removeChild(this.svg.firstChild);
|
|
2308
|
-
(0,
|
|
2309
|
-
var r = (0,
|
|
2302
|
+
(0, le.calculateEncodingAttributes)(this.encodings, this.options);
|
|
2303
|
+
var r = (0, le.getTotalWidthOfEncodings)(this.encodings), n = (0, le.getMaximumHeightOfEncodings)(this.encodings), a = r + this.options.marginLeft + this.options.marginRight;
|
|
2310
2304
|
this.setSvgAttributes(a, n), this.options.background && this.drawRect(0, 0, a, n, this.svg).setAttribute("style", "fill:" + this.options.background + ";");
|
|
2311
2305
|
}
|
|
2312
2306
|
}, {
|
|
@@ -2314,14 +2308,14 @@ var Q = "http://www.w3.org/2000/svg", Ou = function() {
|
|
|
2314
2308
|
value: function(r, n, a) {
|
|
2315
2309
|
var i = a.data, o;
|
|
2316
2310
|
n.textPosition == "top" ? o = n.fontSize + n.textMargin : o = 0;
|
|
2317
|
-
for (var u = 0,
|
|
2318
|
-
|
|
2319
|
-
u > 0 && this.drawRect(
|
|
2311
|
+
for (var u = 0, y = 0, g = 0; g < i.length; g++)
|
|
2312
|
+
y = g * n.width + a.barcodePadding, i[g] === "1" ? u++ : u > 0 && (this.drawRect(y - n.width * u, o, n.width * u, n.height, r), u = 0);
|
|
2313
|
+
u > 0 && this.drawRect(y - n.width * (u - 1), o, n.width * u, n.height, r);
|
|
2320
2314
|
}
|
|
2321
2315
|
}, {
|
|
2322
2316
|
key: "drawSVGText",
|
|
2323
2317
|
value: function(r, n, a) {
|
|
2324
|
-
var i = this.document.createElementNS(
|
|
2318
|
+
var i = this.document.createElementNS(q, "text");
|
|
2325
2319
|
if (n.displayValue) {
|
|
2326
2320
|
var o, u;
|
|
2327
2321
|
i.setAttribute("style", "font:" + n.fontOptions + " " + n.fontSize + "px " + n.font), n.textPosition == "top" ? u = n.fontSize - n.textMargin : u = n.height + n.textMargin + n.fontSize, n.textAlign == "left" || a.barcodePadding > 0 ? (o = 0, i.setAttribute("text-anchor", "start")) : n.textAlign == "right" ? (o = a.width - 1, i.setAttribute("text-anchor", "end")) : (o = a.width / 2, i.setAttribute("text-anchor", "middle")), i.setAttribute("x", o), i.setAttribute("y", u), i.appendChild(this.document.createTextNode(a.text)), r.appendChild(i);
|
|
@@ -2331,12 +2325,12 @@ var Q = "http://www.w3.org/2000/svg", Ou = function() {
|
|
|
2331
2325
|
key: "setSvgAttributes",
|
|
2332
2326
|
value: function(r, n) {
|
|
2333
2327
|
var a = this.svg;
|
|
2334
|
-
a.setAttribute("width", r + "px"), a.setAttribute("height", n + "px"), a.setAttribute("x", "0px"), a.setAttribute("y", "0px"), a.setAttribute("viewBox", "0 0 " + r + " " + n), a.setAttribute("xmlns",
|
|
2328
|
+
a.setAttribute("width", r + "px"), a.setAttribute("height", n + "px"), a.setAttribute("x", "0px"), a.setAttribute("y", "0px"), a.setAttribute("viewBox", "0 0 " + r + " " + n), a.setAttribute("xmlns", q), a.setAttribute("version", "1.1"), a.setAttribute("style", "transform: translate(0,0)");
|
|
2335
2329
|
}
|
|
2336
2330
|
}, {
|
|
2337
2331
|
key: "createGroup",
|
|
2338
2332
|
value: function(r, n, a) {
|
|
2339
|
-
var i = this.document.createElementNS(
|
|
2333
|
+
var i = this.document.createElementNS(q, "g");
|
|
2340
2334
|
return i.setAttribute("transform", "translate(" + r + ", " + n + ")"), a.appendChild(i), i;
|
|
2341
2335
|
}
|
|
2342
2336
|
}, {
|
|
@@ -2347,17 +2341,17 @@ var Q = "http://www.w3.org/2000/svg", Ou = function() {
|
|
|
2347
2341
|
}, {
|
|
2348
2342
|
key: "drawRect",
|
|
2349
2343
|
value: function(r, n, a, i, o) {
|
|
2350
|
-
var u = this.document.createElementNS(
|
|
2344
|
+
var u = this.document.createElementNS(q, "rect");
|
|
2351
2345
|
return u.setAttribute("x", r), u.setAttribute("y", n), u.setAttribute("width", a), u.setAttribute("height", i), o.appendChild(u), u;
|
|
2352
2346
|
}
|
|
2353
2347
|
}]), t;
|
|
2354
2348
|
}();
|
|
2355
|
-
|
|
2356
|
-
var
|
|
2357
|
-
Object.defineProperty(
|
|
2349
|
+
Ce.default = ru;
|
|
2350
|
+
var Ne = {};
|
|
2351
|
+
Object.defineProperty(Ne, "__esModule", {
|
|
2358
2352
|
value: !0
|
|
2359
2353
|
});
|
|
2360
|
-
var
|
|
2354
|
+
var au = function() {
|
|
2361
2355
|
function t(e, r) {
|
|
2362
2356
|
for (var n = 0; n < r.length; n++) {
|
|
2363
2357
|
var a = r[n];
|
|
@@ -2368,147 +2362,147 @@ var Eu = function() {
|
|
|
2368
2362
|
return r && t(e.prototype, r), n && t(e, n), e;
|
|
2369
2363
|
};
|
|
2370
2364
|
}();
|
|
2371
|
-
function
|
|
2365
|
+
function iu(t, e) {
|
|
2372
2366
|
if (!(t instanceof e))
|
|
2373
2367
|
throw new TypeError("Cannot call a class as a function");
|
|
2374
2368
|
}
|
|
2375
|
-
var
|
|
2369
|
+
var ou = function() {
|
|
2376
2370
|
function t(e, r, n) {
|
|
2377
|
-
|
|
2371
|
+
iu(this, t), this.object = e, this.encodings = r, this.options = n;
|
|
2378
2372
|
}
|
|
2379
|
-
return
|
|
2373
|
+
return au(t, [{
|
|
2380
2374
|
key: "render",
|
|
2381
2375
|
value: function() {
|
|
2382
2376
|
this.object.encodings = this.encodings;
|
|
2383
2377
|
}
|
|
2384
2378
|
}]), t;
|
|
2385
2379
|
}();
|
|
2386
|
-
|
|
2387
|
-
Object.defineProperty(
|
|
2380
|
+
Ne.default = ou;
|
|
2381
|
+
Object.defineProperty(Be, "__esModule", {
|
|
2388
2382
|
value: !0
|
|
2389
2383
|
});
|
|
2390
|
-
var
|
|
2391
|
-
function
|
|
2384
|
+
var uu = Le, fu = Ge(uu), cu = Ce, lu = Ge(cu), hu = Ne, du = Ge(hu);
|
|
2385
|
+
function Ge(t) {
|
|
2392
2386
|
return t && t.__esModule ? t : { default: t };
|
|
2393
2387
|
}
|
|
2394
|
-
|
|
2395
|
-
var
|
|
2396
|
-
Object.defineProperty(
|
|
2388
|
+
Be.default = { CanvasRenderer: fu.default, SVGRenderer: lu.default, ObjectRenderer: du.default };
|
|
2389
|
+
var k = {};
|
|
2390
|
+
Object.defineProperty(k, "__esModule", {
|
|
2397
2391
|
value: !0
|
|
2398
2392
|
});
|
|
2399
|
-
function
|
|
2393
|
+
function Fe(t, e) {
|
|
2400
2394
|
if (!(t instanceof e))
|
|
2401
2395
|
throw new TypeError("Cannot call a class as a function");
|
|
2402
2396
|
}
|
|
2403
|
-
function
|
|
2397
|
+
function He(t, e) {
|
|
2404
2398
|
if (!t)
|
|
2405
2399
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
2406
2400
|
return e && (typeof e == "object" || typeof e == "function") ? e : t;
|
|
2407
2401
|
}
|
|
2408
|
-
function
|
|
2402
|
+
function Xe(t, e) {
|
|
2409
2403
|
if (typeof e != "function" && e !== null)
|
|
2410
2404
|
throw new TypeError("Super expression must either be null or a function, not " + typeof e);
|
|
2411
2405
|
t.prototype = Object.create(e && e.prototype, { constructor: { value: t, enumerable: !1, writable: !0, configurable: !0 } }), e && (Object.setPrototypeOf ? Object.setPrototypeOf(t, e) : t.__proto__ = e);
|
|
2412
2406
|
}
|
|
2413
|
-
var
|
|
2414
|
-
|
|
2407
|
+
var _u = function(t) {
|
|
2408
|
+
Xe(e, t);
|
|
2415
2409
|
function e(r, n) {
|
|
2416
|
-
|
|
2417
|
-
var a =
|
|
2410
|
+
Fe(this, e);
|
|
2411
|
+
var a = He(this, (e.__proto__ || Object.getPrototypeOf(e)).call(this));
|
|
2418
2412
|
return a.name = "InvalidInputException", a.symbology = r, a.input = n, a.message = '"' + a.input + '" is not a valid input for ' + a.symbology, a;
|
|
2419
2413
|
}
|
|
2420
2414
|
return e;
|
|
2421
|
-
}(Error),
|
|
2422
|
-
|
|
2415
|
+
}(Error), vu = function(t) {
|
|
2416
|
+
Xe(e, t);
|
|
2423
2417
|
function e() {
|
|
2424
|
-
|
|
2425
|
-
var r =
|
|
2418
|
+
Fe(this, e);
|
|
2419
|
+
var r = He(this, (e.__proto__ || Object.getPrototypeOf(e)).call(this));
|
|
2426
2420
|
return r.name = "InvalidElementException", r.message = "Not supported type to render on", r;
|
|
2427
2421
|
}
|
|
2428
2422
|
return e;
|
|
2429
|
-
}(Error),
|
|
2430
|
-
|
|
2423
|
+
}(Error), yu = function(t) {
|
|
2424
|
+
Xe(e, t);
|
|
2431
2425
|
function e() {
|
|
2432
|
-
|
|
2433
|
-
var r =
|
|
2426
|
+
Fe(this, e);
|
|
2427
|
+
var r = He(this, (e.__proto__ || Object.getPrototypeOf(e)).call(this));
|
|
2434
2428
|
return r.name = "NoElementException", r.message = "No element to render on.", r;
|
|
2435
2429
|
}
|
|
2436
2430
|
return e;
|
|
2437
2431
|
}(Error);
|
|
2438
|
-
|
|
2439
|
-
|
|
2440
|
-
|
|
2441
|
-
Object.defineProperty(
|
|
2432
|
+
k.InvalidInputException = _u;
|
|
2433
|
+
k.InvalidElementException = vu;
|
|
2434
|
+
k.NoElementException = yu;
|
|
2435
|
+
Object.defineProperty(De, "__esModule", {
|
|
2442
2436
|
value: !0
|
|
2443
2437
|
});
|
|
2444
|
-
var
|
|
2438
|
+
var su = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(t) {
|
|
2445
2439
|
return typeof t;
|
|
2446
2440
|
} : function(t) {
|
|
2447
2441
|
return t && typeof Symbol == "function" && t.constructor === Symbol && t !== Symbol.prototype ? "symbol" : typeof t;
|
|
2448
|
-
},
|
|
2449
|
-
function
|
|
2442
|
+
}, pu = je, de = Rt(pu), gu = Be, L = Rt(gu), Ou = k;
|
|
2443
|
+
function Rt(t) {
|
|
2450
2444
|
return t && t.__esModule ? t : { default: t };
|
|
2451
2445
|
}
|
|
2452
|
-
function
|
|
2446
|
+
function ze(t) {
|
|
2453
2447
|
if (typeof t == "string")
|
|
2454
|
-
return
|
|
2448
|
+
return Eu(t);
|
|
2455
2449
|
if (Array.isArray(t)) {
|
|
2456
2450
|
for (var e = [], r = 0; r < t.length; r++)
|
|
2457
|
-
e.push(
|
|
2451
|
+
e.push(ze(t[r]));
|
|
2458
2452
|
return e;
|
|
2459
2453
|
} else {
|
|
2460
2454
|
if (typeof HTMLCanvasElement < "u" && t instanceof HTMLImageElement)
|
|
2461
|
-
return
|
|
2455
|
+
return bu(t);
|
|
2462
2456
|
if (t && t.nodeName && t.nodeName.toLowerCase() === "svg" || typeof SVGElement < "u" && t instanceof SVGElement)
|
|
2463
2457
|
return {
|
|
2464
2458
|
element: t,
|
|
2465
|
-
options: (0,
|
|
2466
|
-
renderer:
|
|
2459
|
+
options: (0, de.default)(t),
|
|
2460
|
+
renderer: L.default.SVGRenderer
|
|
2467
2461
|
};
|
|
2468
2462
|
if (typeof HTMLCanvasElement < "u" && t instanceof HTMLCanvasElement)
|
|
2469
2463
|
return {
|
|
2470
2464
|
element: t,
|
|
2471
|
-
options: (0,
|
|
2472
|
-
renderer:
|
|
2465
|
+
options: (0, de.default)(t),
|
|
2466
|
+
renderer: L.default.CanvasRenderer
|
|
2473
2467
|
};
|
|
2474
2468
|
if (t && t.getContext)
|
|
2475
2469
|
return {
|
|
2476
2470
|
element: t,
|
|
2477
|
-
renderer:
|
|
2471
|
+
renderer: L.default.CanvasRenderer
|
|
2478
2472
|
};
|
|
2479
|
-
if (t && (typeof t > "u" ? "undefined" :
|
|
2473
|
+
if (t && (typeof t > "u" ? "undefined" : su(t)) === "object" && !t.nodeName)
|
|
2480
2474
|
return {
|
|
2481
2475
|
element: t,
|
|
2482
|
-
renderer:
|
|
2476
|
+
renderer: L.default.ObjectRenderer
|
|
2483
2477
|
};
|
|
2484
|
-
throw new
|
|
2478
|
+
throw new Ou.InvalidElementException();
|
|
2485
2479
|
}
|
|
2486
2480
|
}
|
|
2487
|
-
function
|
|
2481
|
+
function Eu(t) {
|
|
2488
2482
|
var e = document.querySelectorAll(t);
|
|
2489
2483
|
if (e.length !== 0) {
|
|
2490
2484
|
for (var r = [], n = 0; n < e.length; n++)
|
|
2491
|
-
r.push(
|
|
2485
|
+
r.push(ze(e[n]));
|
|
2492
2486
|
return r;
|
|
2493
2487
|
}
|
|
2494
2488
|
}
|
|
2495
|
-
function
|
|
2489
|
+
function bu(t) {
|
|
2496
2490
|
var e = document.createElement("canvas");
|
|
2497
2491
|
return {
|
|
2498
2492
|
element: e,
|
|
2499
|
-
options: (0,
|
|
2500
|
-
renderer:
|
|
2493
|
+
options: (0, de.default)(t),
|
|
2494
|
+
renderer: L.default.CanvasRenderer,
|
|
2501
2495
|
afterRender: function() {
|
|
2502
2496
|
t.setAttribute("src", e.toDataURL());
|
|
2503
2497
|
}
|
|
2504
2498
|
};
|
|
2505
2499
|
}
|
|
2506
|
-
|
|
2507
|
-
var
|
|
2508
|
-
Object.defineProperty(
|
|
2500
|
+
De.default = ze;
|
|
2501
|
+
var Ue = {};
|
|
2502
|
+
Object.defineProperty(Ue, "__esModule", {
|
|
2509
2503
|
value: !0
|
|
2510
2504
|
});
|
|
2511
|
-
var
|
|
2505
|
+
var wu = function() {
|
|
2512
2506
|
function t(e, r) {
|
|
2513
2507
|
for (var n = 0; n < r.length; n++) {
|
|
2514
2508
|
var a = r[n];
|
|
@@ -2519,15 +2513,15 @@ var Cu = function() {
|
|
|
2519
2513
|
return r && t(e.prototype, r), n && t(e, n), e;
|
|
2520
2514
|
};
|
|
2521
2515
|
}();
|
|
2522
|
-
function
|
|
2516
|
+
function mu(t, e) {
|
|
2523
2517
|
if (!(t instanceof e))
|
|
2524
2518
|
throw new TypeError("Cannot call a class as a function");
|
|
2525
2519
|
}
|
|
2526
|
-
var
|
|
2520
|
+
var $u = function() {
|
|
2527
2521
|
function t(e) {
|
|
2528
|
-
|
|
2522
|
+
mu(this, t), this.api = e;
|
|
2529
2523
|
}
|
|
2530
|
-
return
|
|
2524
|
+
return wu(t, [{
|
|
2531
2525
|
key: "handleCatch",
|
|
2532
2526
|
value: function(r) {
|
|
2533
2527
|
if (r.name === "InvalidInputException")
|
|
@@ -2552,145 +2546,101 @@ var Gu = function() {
|
|
|
2552
2546
|
}
|
|
2553
2547
|
}]), t;
|
|
2554
2548
|
}();
|
|
2555
|
-
|
|
2556
|
-
var
|
|
2549
|
+
Ue.default = $u;
|
|
2550
|
+
var xu = ve, b = E(xu), Su = I, H = E(Su), Au = Ie, Pt = E(Au), Ru = ke, it = E(Ru), Pu = De, Tu = E(Pu), Mu = ne, Iu = E(Mu), ku = Ue, Du = E(ku), Tt = k, ju = re, Mt = E(ju);
|
|
2557
2551
|
function E(t) {
|
|
2558
2552
|
return t && t.__esModule ? t : { default: t };
|
|
2559
2553
|
}
|
|
2560
|
-
var
|
|
2561
|
-
},
|
|
2562
|
-
var a = new
|
|
2554
|
+
var p = function() {
|
|
2555
|
+
}, ae = function(e, r, n) {
|
|
2556
|
+
var a = new p();
|
|
2563
2557
|
if (typeof e > "u")
|
|
2564
2558
|
throw Error("No element to render on was provided.");
|
|
2565
|
-
return a._renderProperties = (0,
|
|
2559
|
+
return a._renderProperties = (0, Tu.default)(e), a._encodings = [], a._options = Mt.default, a._errorHandler = new Du.default(a), typeof r < "u" && (n = n || {}, n.format || (n.format = kt()), a.options(n)[n.format](r, n).render()), a;
|
|
2566
2560
|
};
|
|
2567
|
-
|
|
2568
|
-
return
|
|
2561
|
+
ae.getModule = function(t) {
|
|
2562
|
+
return b.default[t];
|
|
2569
2563
|
};
|
|
2570
|
-
for (var
|
|
2571
|
-
|
|
2572
|
-
function
|
|
2573
|
-
|
|
2564
|
+
for (var ot in b.default)
|
|
2565
|
+
b.default.hasOwnProperty(ot) && Bu(b.default, ot);
|
|
2566
|
+
function Bu(t, e) {
|
|
2567
|
+
p.prototype[e] = p.prototype[e.toUpperCase()] = p.prototype[e.toLowerCase()] = function(r, n) {
|
|
2574
2568
|
var a = this;
|
|
2575
2569
|
return a._errorHandler.wrapBarcodeCall(function() {
|
|
2576
2570
|
n.text = typeof n.text > "u" ? void 0 : "" + n.text;
|
|
2577
|
-
var i = (0,
|
|
2578
|
-
i = (0,
|
|
2579
|
-
var o = t[e], u =
|
|
2571
|
+
var i = (0, H.default)(a._options, n);
|
|
2572
|
+
i = (0, Iu.default)(i);
|
|
2573
|
+
var o = t[e], u = It(r, o, i);
|
|
2580
2574
|
return a._encodings.push(u), a;
|
|
2581
2575
|
});
|
|
2582
2576
|
};
|
|
2583
2577
|
}
|
|
2584
|
-
function
|
|
2578
|
+
function It(t, e, r) {
|
|
2585
2579
|
t = "" + t;
|
|
2586
2580
|
var n = new e(t, r);
|
|
2587
2581
|
if (!n.valid())
|
|
2588
|
-
throw new
|
|
2582
|
+
throw new Tt.InvalidInputException(n.constructor.name, t);
|
|
2589
2583
|
var a = n.encode();
|
|
2590
|
-
a = (0,
|
|
2584
|
+
a = (0, Pt.default)(a);
|
|
2591
2585
|
for (var i = 0; i < a.length; i++)
|
|
2592
|
-
a[i].options = (0,
|
|
2586
|
+
a[i].options = (0, H.default)(r, a[i].options);
|
|
2593
2587
|
return a;
|
|
2594
2588
|
}
|
|
2595
|
-
function
|
|
2596
|
-
return
|
|
2589
|
+
function kt() {
|
|
2590
|
+
return b.default.CODE128 ? "CODE128" : Object.keys(b.default)[0];
|
|
2597
2591
|
}
|
|
2598
|
-
|
|
2599
|
-
return this._options = (0,
|
|
2592
|
+
p.prototype.options = function(t) {
|
|
2593
|
+
return this._options = (0, H.default)(this._options, t), this;
|
|
2600
2594
|
};
|
|
2601
|
-
|
|
2595
|
+
p.prototype.blank = function(t) {
|
|
2602
2596
|
var e = new Array(t + 1).join("0");
|
|
2603
2597
|
return this._encodings.push({ data: e }), this;
|
|
2604
2598
|
};
|
|
2605
|
-
|
|
2599
|
+
p.prototype.init = function() {
|
|
2606
2600
|
if (this._renderProperties) {
|
|
2607
2601
|
Array.isArray(this._renderProperties) || (this._renderProperties = [this._renderProperties]);
|
|
2608
2602
|
var t;
|
|
2609
2603
|
for (var e in this._renderProperties) {
|
|
2610
2604
|
t = this._renderProperties[e];
|
|
2611
|
-
var r = (0,
|
|
2612
|
-
r.format == "auto" && (r.format =
|
|
2613
|
-
var n = r.value, a =
|
|
2614
|
-
|
|
2605
|
+
var r = (0, H.default)(this._options, t.options);
|
|
2606
|
+
r.format == "auto" && (r.format = kt()), this._errorHandler.wrapBarcodeCall(function() {
|
|
2607
|
+
var n = r.value, a = b.default[r.format.toUpperCase()], i = It(n, a, r);
|
|
2608
|
+
_e(t, i, r);
|
|
2615
2609
|
});
|
|
2616
2610
|
}
|
|
2617
2611
|
}
|
|
2618
2612
|
};
|
|
2619
|
-
|
|
2613
|
+
p.prototype.render = function() {
|
|
2620
2614
|
if (!this._renderProperties)
|
|
2621
|
-
throw new
|
|
2615
|
+
throw new Tt.NoElementException();
|
|
2622
2616
|
if (Array.isArray(this._renderProperties))
|
|
2623
2617
|
for (var t = 0; t < this._renderProperties.length; t++)
|
|
2624
|
-
|
|
2618
|
+
_e(this._renderProperties[t], this._encodings, this._options);
|
|
2625
2619
|
else
|
|
2626
|
-
|
|
2620
|
+
_e(this._renderProperties, this._encodings, this._options);
|
|
2627
2621
|
return this;
|
|
2628
2622
|
};
|
|
2629
|
-
|
|
2630
|
-
function
|
|
2631
|
-
e = (0,
|
|
2623
|
+
p.prototype._defaults = Mt.default;
|
|
2624
|
+
function _e(t, e, r) {
|
|
2625
|
+
e = (0, Pt.default)(e);
|
|
2632
2626
|
for (var n = 0; n < e.length; n++)
|
|
2633
|
-
e[n].options = (0,
|
|
2634
|
-
(0,
|
|
2627
|
+
e[n].options = (0, H.default)(r, e[n].options), (0, it.default)(e[n].options);
|
|
2628
|
+
(0, it.default)(r);
|
|
2635
2629
|
var a = t.renderer, i = new a(t.element, e, r);
|
|
2636
2630
|
i.render(), t.afterRender && t.afterRender();
|
|
2637
2631
|
}
|
|
2638
|
-
typeof window < "u" && (window.JsBarcode =
|
|
2632
|
+
typeof window < "u" && (window.JsBarcode = ae);
|
|
2639
2633
|
typeof jQuery < "u" && (jQuery.fn.JsBarcode = function(t, e) {
|
|
2640
2634
|
var r = [];
|
|
2641
2635
|
return jQuery(this).each(function() {
|
|
2642
2636
|
r.push(this);
|
|
2643
|
-
}),
|
|
2644
|
-
});
|
|
2645
|
-
var Ku = fe;
|
|
2646
|
-
async function ef(t, e = 300, r = 150, n) {
|
|
2647
|
-
const a = document.createElement("canvas");
|
|
2648
|
-
if (!a.getContext("2d"))
|
|
2649
|
-
throw new Error("Canvas context is not available.");
|
|
2650
|
-
return a.width = e, a.height = r, await Ku(a, t, n), a.toDataURL("image/png");
|
|
2651
|
-
}
|
|
2652
|
-
const tf = ["src"], nf = ht({ componentName: qt.FieldWidget }), Sf = /* @__PURE__ */ ht({
|
|
2653
|
-
...nf,
|
|
2654
|
-
__name: "barcode-widget",
|
|
2655
|
-
props: { ...Jt },
|
|
2656
|
-
setup(t, { expose: e }) {
|
|
2657
|
-
const r = t, { exposed: n, extendAttrs: a, fieldObj: i } = Yt(r), o = Ct(""), u = () => {
|
|
2658
|
-
var c, v, b;
|
|
2659
|
-
ef((c = a.value) == null ? void 0 : c.content, 300, 150, {
|
|
2660
|
-
...a.value,
|
|
2661
|
-
width: (v = a.value) == null ? void 0 : v.lineWidth,
|
|
2662
|
-
height: (b = a.value) == null ? void 0 : b.lineHeight
|
|
2663
|
-
}).then((j) => {
|
|
2664
|
-
o.value = j;
|
|
2665
|
-
}).catch((j) => {
|
|
2666
|
-
import("./noimg-89eb860b.js").then((V) => {
|
|
2667
|
-
o.value = V.default;
|
|
2668
|
-
});
|
|
2669
|
-
});
|
|
2670
|
-
};
|
|
2671
|
-
return Nt(() => a.value, (c) => {
|
|
2672
|
-
u();
|
|
2673
|
-
}, { immediate: !0 }), e({ ...n }), (c, v) => (Gt(), Ft(Wt, Ht(c.$props, {
|
|
2674
|
-
"prop-options": { fieldObj: B(i) }
|
|
2675
|
-
}), {
|
|
2676
|
-
default: zt(() => {
|
|
2677
|
-
var b, j, V;
|
|
2678
|
-
return [
|
|
2679
|
-
Xt("img", {
|
|
2680
|
-
ref: "fieldEditor",
|
|
2681
|
-
class: Ut(B(Qt)((b = B(a)) == null ? void 0 : b.customClass)),
|
|
2682
|
-
src: o.value,
|
|
2683
|
-
style: Vt({
|
|
2684
|
-
width: (j = B(a)) == null ? void 0 : j.ctrlWidth,
|
|
2685
|
-
height: (V = B(a)) == null ? void 0 : V.ctrlHeight
|
|
2686
|
-
})
|
|
2687
|
-
}, null, 14, tf)
|
|
2688
|
-
];
|
|
2689
|
-
}),
|
|
2690
|
-
_: 1
|
|
2691
|
-
}, 16, ["prop-options"]));
|
|
2692
|
-
}
|
|
2637
|
+
}), ae(r, t, e);
|
|
2693
2638
|
});
|
|
2639
|
+
var ut = ae;
|
|
2640
|
+
const Lu = /* @__PURE__ */ jt({
|
|
2641
|
+
__proto__: null,
|
|
2642
|
+
default: ut
|
|
2643
|
+
}, [ut]);
|
|
2694
2644
|
export {
|
|
2695
|
-
|
|
2645
|
+
Lu as J
|
|
2696
2646
|
};
|