@arthurzakharov/ui-kit 1.3.2 → 1.3.4
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.
|
@@ -1,27 +1,28 @@
|
|
|
1
1
|
import { jsxs as Q, jsx as z } from "react/jsx-runtime";
|
|
2
|
-
import
|
|
3
|
-
import { g as
|
|
4
|
-
import { useResizeObserver as
|
|
5
|
-
import { RefreshCw as
|
|
6
|
-
import
|
|
2
|
+
import ze, { useRef as Fe, useState as Se, useCallback as re, useEffect as de } from "react";
|
|
3
|
+
import { g as qe, a as Be } from "../../input.component-C5xcmnfu.js";
|
|
4
|
+
import { useResizeObserver as Ue } from "usehooks-ts";
|
|
5
|
+
import { RefreshCw as Ne, Check as Ye } from "lucide-react";
|
|
6
|
+
import Pe from "clsx";
|
|
7
7
|
import { Animation as ee } from "../../animations/animation.component.js";
|
|
8
8
|
import { C as oe } from "../../control.component-B9Ao9mfl.js";
|
|
9
9
|
import { Flex as ie } from "../flex/flex.component.js";
|
|
10
|
-
import { Text as
|
|
10
|
+
import { Text as we } from "../text/text.component.js";
|
|
11
|
+
import { Loader as He } from "../loader/loader.component.js";
|
|
11
12
|
import '../../assets/signature-CLmBTe_C.css';var le = { exports: {} }, ue = { exports: {} }, ce = { exports: {} }, I = {};
|
|
12
|
-
var
|
|
13
|
+
var Ee;
|
|
13
14
|
function Ve() {
|
|
14
|
-
if (
|
|
15
|
-
|
|
16
|
-
var e = typeof Symbol == "function" && Symbol.for, a = e ? /* @__PURE__ */ Symbol.for("react.element") : 60103, r = e ? /* @__PURE__ */ Symbol.for("react.portal") : 60106, t = e ? /* @__PURE__ */ Symbol.for("react.fragment") : 60107, n = e ? /* @__PURE__ */ Symbol.for("react.strict_mode") : 60108, o = e ? /* @__PURE__ */ Symbol.for("react.profiler") : 60114,
|
|
15
|
+
if (Ee) return I;
|
|
16
|
+
Ee = 1;
|
|
17
|
+
var e = typeof Symbol == "function" && Symbol.for, a = e ? /* @__PURE__ */ Symbol.for("react.element") : 60103, r = e ? /* @__PURE__ */ Symbol.for("react.portal") : 60106, t = e ? /* @__PURE__ */ Symbol.for("react.fragment") : 60107, n = e ? /* @__PURE__ */ Symbol.for("react.strict_mode") : 60108, o = e ? /* @__PURE__ */ Symbol.for("react.profiler") : 60114, u = e ? /* @__PURE__ */ Symbol.for("react.provider") : 60109, i = e ? /* @__PURE__ */ Symbol.for("react.context") : 60110, p = e ? /* @__PURE__ */ Symbol.for("react.async_mode") : 60111, c = e ? /* @__PURE__ */ Symbol.for("react.concurrent_mode") : 60111, l = e ? /* @__PURE__ */ Symbol.for("react.forward_ref") : 60112, v = e ? /* @__PURE__ */ Symbol.for("react.suspense") : 60113, m = e ? /* @__PURE__ */ Symbol.for("react.suspense_list") : 60120, x = e ? /* @__PURE__ */ Symbol.for("react.memo") : 60115, b = e ? /* @__PURE__ */ Symbol.for("react.lazy") : 60116, y = e ? /* @__PURE__ */ Symbol.for("react.block") : 60121, C = e ? /* @__PURE__ */ Symbol.for("react.fundamental") : 60117, g = e ? /* @__PURE__ */ Symbol.for("react.responder") : 60118, q = e ? /* @__PURE__ */ Symbol.for("react.scope") : 60119;
|
|
17
18
|
function $(f) {
|
|
18
19
|
if (typeof f == "object" && f !== null) {
|
|
19
|
-
var
|
|
20
|
-
switch (
|
|
20
|
+
var Z = f.$$typeof;
|
|
21
|
+
switch (Z) {
|
|
21
22
|
case a:
|
|
22
23
|
switch (f = f.type, f) {
|
|
23
|
-
case
|
|
24
|
-
case
|
|
24
|
+
case p:
|
|
25
|
+
case c:
|
|
25
26
|
case t:
|
|
26
27
|
case o:
|
|
27
28
|
case n:
|
|
@@ -32,27 +33,27 @@ function Ve() {
|
|
|
32
33
|
case i:
|
|
33
34
|
case l:
|
|
34
35
|
case b:
|
|
35
|
-
case
|
|
36
|
-
case
|
|
36
|
+
case x:
|
|
37
|
+
case u:
|
|
37
38
|
return f;
|
|
38
39
|
default:
|
|
39
|
-
return
|
|
40
|
+
return Z;
|
|
40
41
|
}
|
|
41
42
|
}
|
|
42
43
|
case r:
|
|
43
|
-
return
|
|
44
|
+
return Z;
|
|
44
45
|
}
|
|
45
46
|
}
|
|
46
47
|
}
|
|
47
|
-
function
|
|
48
|
-
return $(f) ===
|
|
48
|
+
function k(f) {
|
|
49
|
+
return $(f) === c;
|
|
49
50
|
}
|
|
50
|
-
return I.AsyncMode =
|
|
51
|
-
return
|
|
52
|
-
}, I.isConcurrentMode =
|
|
51
|
+
return I.AsyncMode = p, I.ConcurrentMode = c, I.ContextConsumer = i, I.ContextProvider = u, I.Element = a, I.ForwardRef = l, I.Fragment = t, I.Lazy = b, I.Memo = x, I.Portal = r, I.Profiler = o, I.StrictMode = n, I.Suspense = v, I.isAsyncMode = function(f) {
|
|
52
|
+
return k(f) || $(f) === p;
|
|
53
|
+
}, I.isConcurrentMode = k, I.isContextConsumer = function(f) {
|
|
53
54
|
return $(f) === i;
|
|
54
55
|
}, I.isContextProvider = function(f) {
|
|
55
|
-
return $(f) ===
|
|
56
|
+
return $(f) === u;
|
|
56
57
|
}, I.isElement = function(f) {
|
|
57
58
|
return typeof f == "object" && f !== null && f.$$typeof === a;
|
|
58
59
|
}, I.isForwardRef = function(f) {
|
|
@@ -62,7 +63,7 @@ function Ve() {
|
|
|
62
63
|
}, I.isLazy = function(f) {
|
|
63
64
|
return $(f) === b;
|
|
64
65
|
}, I.isMemo = function(f) {
|
|
65
|
-
return $(f) ===
|
|
66
|
+
return $(f) === x;
|
|
66
67
|
}, I.isPortal = function(f) {
|
|
67
68
|
return $(f) === r;
|
|
68
69
|
}, I.isProfiler = function(f) {
|
|
@@ -72,27 +73,27 @@ function Ve() {
|
|
|
72
73
|
}, I.isSuspense = function(f) {
|
|
73
74
|
return $(f) === v;
|
|
74
75
|
}, I.isValidElementType = function(f) {
|
|
75
|
-
return typeof f == "string" || typeof f == "function" || f === t || f ===
|
|
76
|
+
return typeof f == "string" || typeof f == "function" || f === t || f === c || f === o || f === n || f === v || f === m || typeof f == "object" && f !== null && (f.$$typeof === b || f.$$typeof === x || f.$$typeof === u || f.$$typeof === i || f.$$typeof === l || f.$$typeof === C || f.$$typeof === g || f.$$typeof === q || f.$$typeof === y);
|
|
76
77
|
}, I.typeOf = $, I;
|
|
77
78
|
}
|
|
78
79
|
var j = {};
|
|
79
|
-
var
|
|
80
|
+
var Te;
|
|
80
81
|
function Xe() {
|
|
81
|
-
return
|
|
82
|
-
var e = typeof Symbol == "function" && Symbol.for, a = e ? /* @__PURE__ */ Symbol.for("react.element") : 60103, r = e ? /* @__PURE__ */ Symbol.for("react.portal") : 60106, t = e ? /* @__PURE__ */ Symbol.for("react.fragment") : 60107, n = e ? /* @__PURE__ */ Symbol.for("react.strict_mode") : 60108, o = e ? /* @__PURE__ */ Symbol.for("react.profiler") : 60114,
|
|
83
|
-
function $(
|
|
84
|
-
return typeof
|
|
85
|
-
|
|
82
|
+
return Te || (Te = 1, process.env.NODE_ENV !== "production" && (function() {
|
|
83
|
+
var e = typeof Symbol == "function" && Symbol.for, a = e ? /* @__PURE__ */ Symbol.for("react.element") : 60103, r = e ? /* @__PURE__ */ Symbol.for("react.portal") : 60106, t = e ? /* @__PURE__ */ Symbol.for("react.fragment") : 60107, n = e ? /* @__PURE__ */ Symbol.for("react.strict_mode") : 60108, o = e ? /* @__PURE__ */ Symbol.for("react.profiler") : 60114, u = e ? /* @__PURE__ */ Symbol.for("react.provider") : 60109, i = e ? /* @__PURE__ */ Symbol.for("react.context") : 60110, p = e ? /* @__PURE__ */ Symbol.for("react.async_mode") : 60111, c = e ? /* @__PURE__ */ Symbol.for("react.concurrent_mode") : 60111, l = e ? /* @__PURE__ */ Symbol.for("react.forward_ref") : 60112, v = e ? /* @__PURE__ */ Symbol.for("react.suspense") : 60113, m = e ? /* @__PURE__ */ Symbol.for("react.suspense_list") : 60120, x = e ? /* @__PURE__ */ Symbol.for("react.memo") : 60115, b = e ? /* @__PURE__ */ Symbol.for("react.lazy") : 60116, y = e ? /* @__PURE__ */ Symbol.for("react.block") : 60121, C = e ? /* @__PURE__ */ Symbol.for("react.fundamental") : 60117, g = e ? /* @__PURE__ */ Symbol.for("react.responder") : 60118, q = e ? /* @__PURE__ */ Symbol.for("react.scope") : 60119;
|
|
84
|
+
function $(h) {
|
|
85
|
+
return typeof h == "string" || typeof h == "function" || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.
|
|
86
|
+
h === t || h === c || h === o || h === n || h === v || h === m || typeof h == "object" && h !== null && (h.$$typeof === b || h.$$typeof === x || h.$$typeof === u || h.$$typeof === i || h.$$typeof === l || h.$$typeof === C || h.$$typeof === g || h.$$typeof === q || h.$$typeof === y);
|
|
86
87
|
}
|
|
87
|
-
function
|
|
88
|
-
if (typeof
|
|
89
|
-
var G =
|
|
88
|
+
function k(h) {
|
|
89
|
+
if (typeof h == "object" && h !== null) {
|
|
90
|
+
var G = h.$$typeof;
|
|
90
91
|
switch (G) {
|
|
91
92
|
case a:
|
|
92
|
-
var se =
|
|
93
|
+
var se = h.type;
|
|
93
94
|
switch (se) {
|
|
94
|
-
case
|
|
95
|
-
case
|
|
95
|
+
case p:
|
|
96
|
+
case c:
|
|
96
97
|
case t:
|
|
97
98
|
case o:
|
|
98
99
|
case n:
|
|
@@ -104,8 +105,8 @@ function Xe() {
|
|
|
104
105
|
case i:
|
|
105
106
|
case l:
|
|
106
107
|
case b:
|
|
107
|
-
case
|
|
108
|
-
case
|
|
108
|
+
case x:
|
|
109
|
+
case u:
|
|
109
110
|
return be;
|
|
110
111
|
default:
|
|
111
112
|
return G;
|
|
@@ -116,57 +117,57 @@ function Xe() {
|
|
|
116
117
|
}
|
|
117
118
|
}
|
|
118
119
|
}
|
|
119
|
-
var f =
|
|
120
|
-
function
|
|
121
|
-
return U || (U = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),
|
|
120
|
+
var f = p, Z = c, te = i, N = u, E = a, w = l, B = t, F = b, _ = x, K = r, ae = o, H = n, X = v, U = !1;
|
|
121
|
+
function J(h) {
|
|
122
|
+
return U || (U = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")), s(h) || k(h) === p;
|
|
122
123
|
}
|
|
123
|
-
function
|
|
124
|
-
return
|
|
124
|
+
function s(h) {
|
|
125
|
+
return k(h) === c;
|
|
125
126
|
}
|
|
126
|
-
function h
|
|
127
|
-
return
|
|
127
|
+
function d(h) {
|
|
128
|
+
return k(h) === i;
|
|
128
129
|
}
|
|
129
|
-
function S(
|
|
130
|
-
return
|
|
130
|
+
function S(h) {
|
|
131
|
+
return k(h) === u;
|
|
131
132
|
}
|
|
132
|
-
function
|
|
133
|
-
return typeof
|
|
133
|
+
function R(h) {
|
|
134
|
+
return typeof h == "object" && h !== null && h.$$typeof === a;
|
|
134
135
|
}
|
|
135
|
-
function P(
|
|
136
|
-
return
|
|
136
|
+
function P(h) {
|
|
137
|
+
return k(h) === l;
|
|
137
138
|
}
|
|
138
|
-
function
|
|
139
|
-
return
|
|
139
|
+
function M(h) {
|
|
140
|
+
return k(h) === t;
|
|
140
141
|
}
|
|
141
|
-
function
|
|
142
|
-
return
|
|
142
|
+
function T(h) {
|
|
143
|
+
return k(h) === b;
|
|
143
144
|
}
|
|
144
|
-
function
|
|
145
|
-
return
|
|
145
|
+
function O(h) {
|
|
146
|
+
return k(h) === x;
|
|
146
147
|
}
|
|
147
|
-
function
|
|
148
|
-
return
|
|
148
|
+
function A(h) {
|
|
149
|
+
return k(h) === r;
|
|
149
150
|
}
|
|
150
|
-
function W(
|
|
151
|
-
return
|
|
151
|
+
function W(h) {
|
|
152
|
+
return k(h) === o;
|
|
152
153
|
}
|
|
153
|
-
function
|
|
154
|
-
return
|
|
154
|
+
function D(h) {
|
|
155
|
+
return k(h) === n;
|
|
155
156
|
}
|
|
156
|
-
function Y(
|
|
157
|
-
return
|
|
157
|
+
function Y(h) {
|
|
158
|
+
return k(h) === v;
|
|
158
159
|
}
|
|
159
|
-
j.AsyncMode = f, j.ConcurrentMode =
|
|
160
|
+
j.AsyncMode = f, j.ConcurrentMode = Z, j.ContextConsumer = te, j.ContextProvider = N, j.Element = E, j.ForwardRef = w, j.Fragment = B, j.Lazy = F, j.Memo = _, j.Portal = K, j.Profiler = ae, j.StrictMode = H, j.Suspense = X, j.isAsyncMode = J, j.isConcurrentMode = s, j.isContextConsumer = d, j.isContextProvider = S, j.isElement = R, j.isForwardRef = P, j.isFragment = M, j.isLazy = T, j.isMemo = O, j.isPortal = A, j.isProfiler = W, j.isStrictMode = D, j.isSuspense = Y, j.isValidElementType = $, j.typeOf = k;
|
|
160
161
|
})()), j;
|
|
161
162
|
}
|
|
162
|
-
var
|
|
163
|
-
function
|
|
164
|
-
return
|
|
163
|
+
var Ce;
|
|
164
|
+
function We() {
|
|
165
|
+
return Ce || (Ce = 1, process.env.NODE_ENV === "production" ? ce.exports = Ve() : ce.exports = Xe()), ce.exports;
|
|
165
166
|
}
|
|
166
|
-
var he,
|
|
167
|
+
var he, Re;
|
|
167
168
|
function Je() {
|
|
168
|
-
if (
|
|
169
|
-
|
|
169
|
+
if (Re) return he;
|
|
170
|
+
Re = 1;
|
|
170
171
|
var e = Object.getOwnPropertySymbols, a = Object.prototype.hasOwnProperty, r = Object.prototype.propertyIsEnumerable;
|
|
171
172
|
function t(o) {
|
|
172
173
|
if (o == null)
|
|
@@ -180,86 +181,86 @@ function Je() {
|
|
|
180
181
|
var o = new String("abc");
|
|
181
182
|
if (o[5] = "de", Object.getOwnPropertyNames(o)[0] === "5")
|
|
182
183
|
return !1;
|
|
183
|
-
for (var
|
|
184
|
-
|
|
185
|
-
var
|
|
186
|
-
return
|
|
184
|
+
for (var u = {}, i = 0; i < 10; i++)
|
|
185
|
+
u["_" + String.fromCharCode(i)] = i;
|
|
186
|
+
var p = Object.getOwnPropertyNames(u).map(function(l) {
|
|
187
|
+
return u[l];
|
|
187
188
|
});
|
|
188
|
-
if (
|
|
189
|
+
if (p.join("") !== "0123456789")
|
|
189
190
|
return !1;
|
|
190
|
-
var
|
|
191
|
+
var c = {};
|
|
191
192
|
return "abcdefghijklmnopqrst".split("").forEach(function(l) {
|
|
192
|
-
|
|
193
|
-
}), Object.keys(Object.assign({},
|
|
193
|
+
c[l] = l;
|
|
194
|
+
}), Object.keys(Object.assign({}, c)).join("") === "abcdefghijklmnopqrst";
|
|
194
195
|
} catch {
|
|
195
196
|
return !1;
|
|
196
197
|
}
|
|
197
198
|
}
|
|
198
|
-
return he = n() ? Object.assign : function(o,
|
|
199
|
-
for (var i,
|
|
199
|
+
return he = n() ? Object.assign : function(o, u) {
|
|
200
|
+
for (var i, p = t(o), c, l = 1; l < arguments.length; l++) {
|
|
200
201
|
i = Object(arguments[l]);
|
|
201
202
|
for (var v in i)
|
|
202
|
-
a.call(i, v) && (
|
|
203
|
+
a.call(i, v) && (p[v] = i[v]);
|
|
203
204
|
if (e) {
|
|
204
|
-
|
|
205
|
-
for (var
|
|
206
|
-
r.call(i,
|
|
205
|
+
c = e(i);
|
|
206
|
+
for (var m = 0; m < c.length; m++)
|
|
207
|
+
r.call(i, c[m]) && (p[c[m]] = i[c[m]]);
|
|
207
208
|
}
|
|
208
209
|
}
|
|
209
|
-
return
|
|
210
|
+
return p;
|
|
210
211
|
}, he;
|
|
211
212
|
}
|
|
212
|
-
var pe,
|
|
213
|
+
var pe, Oe;
|
|
213
214
|
function _e() {
|
|
214
|
-
if (
|
|
215
|
-
|
|
215
|
+
if (Oe) return pe;
|
|
216
|
+
Oe = 1;
|
|
216
217
|
var e = "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";
|
|
217
218
|
return pe = e, pe;
|
|
218
219
|
}
|
|
219
|
-
var ve,
|
|
220
|
-
function
|
|
221
|
-
return
|
|
220
|
+
var ve, Me;
|
|
221
|
+
function Le() {
|
|
222
|
+
return Me || (Me = 1, ve = Function.call.bind(Object.prototype.hasOwnProperty)), ve;
|
|
222
223
|
}
|
|
223
|
-
var ye,
|
|
224
|
+
var ye, Ae;
|
|
224
225
|
function Ze() {
|
|
225
|
-
if (
|
|
226
|
-
|
|
226
|
+
if (Ae) return ye;
|
|
227
|
+
Ae = 1;
|
|
227
228
|
var e = function() {
|
|
228
229
|
};
|
|
229
230
|
if (process.env.NODE_ENV !== "production") {
|
|
230
|
-
var a = /* @__PURE__ */ _e(), r = {}, t = /* @__PURE__ */
|
|
231
|
+
var a = /* @__PURE__ */ _e(), r = {}, t = /* @__PURE__ */ Le();
|
|
231
232
|
e = function(o) {
|
|
232
|
-
var
|
|
233
|
-
typeof console < "u" && console.error(
|
|
233
|
+
var u = "Warning: " + o;
|
|
234
|
+
typeof console < "u" && console.error(u);
|
|
234
235
|
try {
|
|
235
|
-
throw new Error(
|
|
236
|
+
throw new Error(u);
|
|
236
237
|
} catch {
|
|
237
238
|
}
|
|
238
239
|
};
|
|
239
240
|
}
|
|
240
|
-
function n(o,
|
|
241
|
+
function n(o, u, i, p, c) {
|
|
241
242
|
if (process.env.NODE_ENV !== "production") {
|
|
242
243
|
for (var l in o)
|
|
243
244
|
if (t(o, l)) {
|
|
244
245
|
var v;
|
|
245
246
|
try {
|
|
246
247
|
if (typeof o[l] != "function") {
|
|
247
|
-
var
|
|
248
|
-
(
|
|
248
|
+
var m = Error(
|
|
249
|
+
(p || "React class") + ": " + i + " type `" + l + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof o[l] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`."
|
|
249
250
|
);
|
|
250
|
-
throw
|
|
251
|
+
throw m.name = "Invariant Violation", m;
|
|
251
252
|
}
|
|
252
|
-
v = o[l](
|
|
253
|
+
v = o[l](u, l, p, i, null, a);
|
|
253
254
|
} catch (b) {
|
|
254
255
|
v = b;
|
|
255
256
|
}
|
|
256
257
|
if (v && !(v instanceof Error) && e(
|
|
257
|
-
(
|
|
258
|
+
(p || "React class") + ": type specification of " + i + " `" + l + "` is invalid; the type checker function must return `null` or an `Error` but returned a " + typeof v + ". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."
|
|
258
259
|
), v instanceof Error && !(v.message in r)) {
|
|
259
260
|
r[v.message] = !0;
|
|
260
|
-
var
|
|
261
|
+
var x = c ? c() : "";
|
|
261
262
|
e(
|
|
262
|
-
"Failed " + i + " type: " + v.message + (
|
|
263
|
+
"Failed " + i + " type: " + v.message + (x ?? "")
|
|
263
264
|
);
|
|
264
265
|
}
|
|
265
266
|
}
|
|
@@ -269,278 +270,278 @@ function Ze() {
|
|
|
269
270
|
process.env.NODE_ENV !== "production" && (r = {});
|
|
270
271
|
}, ye = n, ye;
|
|
271
272
|
}
|
|
272
|
-
var me,
|
|
273
|
+
var me, De;
|
|
273
274
|
function Ge() {
|
|
274
|
-
if (
|
|
275
|
-
|
|
276
|
-
var e =
|
|
275
|
+
if (De) return me;
|
|
276
|
+
De = 1;
|
|
277
|
+
var e = We(), a = Je(), r = /* @__PURE__ */ _e(), t = /* @__PURE__ */ Le(), n = /* @__PURE__ */ Ze(), o = function() {
|
|
277
278
|
};
|
|
278
279
|
process.env.NODE_ENV !== "production" && (o = function(i) {
|
|
279
|
-
var
|
|
280
|
-
typeof console < "u" && console.error(
|
|
280
|
+
var p = "Warning: " + i;
|
|
281
|
+
typeof console < "u" && console.error(p);
|
|
281
282
|
try {
|
|
282
|
-
throw new Error(
|
|
283
|
+
throw new Error(p);
|
|
283
284
|
} catch {
|
|
284
285
|
}
|
|
285
286
|
});
|
|
286
|
-
function
|
|
287
|
+
function u() {
|
|
287
288
|
return null;
|
|
288
289
|
}
|
|
289
|
-
return me = function(i,
|
|
290
|
-
var
|
|
291
|
-
function v(
|
|
292
|
-
var
|
|
293
|
-
if (typeof
|
|
294
|
-
return
|
|
290
|
+
return me = function(i, p) {
|
|
291
|
+
var c = typeof Symbol == "function" && Symbol.iterator, l = "@@iterator";
|
|
292
|
+
function v(s) {
|
|
293
|
+
var d = s && (c && s[c] || s[l]);
|
|
294
|
+
if (typeof d == "function")
|
|
295
|
+
return d;
|
|
295
296
|
}
|
|
296
|
-
var
|
|
297
|
-
array:
|
|
298
|
-
bigint:
|
|
299
|
-
bool:
|
|
300
|
-
func:
|
|
301
|
-
number:
|
|
302
|
-
object:
|
|
303
|
-
string:
|
|
304
|
-
symbol:
|
|
297
|
+
var m = "<<anonymous>>", x = {
|
|
298
|
+
array: g("array"),
|
|
299
|
+
bigint: g("bigint"),
|
|
300
|
+
bool: g("boolean"),
|
|
301
|
+
func: g("function"),
|
|
302
|
+
number: g("number"),
|
|
303
|
+
object: g("object"),
|
|
304
|
+
string: g("string"),
|
|
305
|
+
symbol: g("symbol"),
|
|
305
306
|
any: q(),
|
|
306
307
|
arrayOf: $,
|
|
307
|
-
element:
|
|
308
|
+
element: k(),
|
|
308
309
|
elementType: f(),
|
|
309
|
-
instanceOf:
|
|
310
|
+
instanceOf: Z,
|
|
310
311
|
node: w(),
|
|
311
|
-
objectOf:
|
|
312
|
-
oneOf:
|
|
313
|
-
oneOfType:
|
|
312
|
+
objectOf: N,
|
|
313
|
+
oneOf: te,
|
|
314
|
+
oneOfType: E,
|
|
314
315
|
shape: F,
|
|
315
|
-
exact:
|
|
316
|
+
exact: _
|
|
316
317
|
};
|
|
317
|
-
function b(
|
|
318
|
-
return
|
|
318
|
+
function b(s, d) {
|
|
319
|
+
return s === d ? s !== 0 || 1 / s === 1 / d : s !== s && d !== d;
|
|
319
320
|
}
|
|
320
|
-
function
|
|
321
|
-
this.message =
|
|
321
|
+
function y(s, d) {
|
|
322
|
+
this.message = s, this.data = d && typeof d == "object" ? d : {}, this.stack = "";
|
|
322
323
|
}
|
|
323
|
-
|
|
324
|
-
function
|
|
324
|
+
y.prototype = Error.prototype;
|
|
325
|
+
function C(s) {
|
|
325
326
|
if (process.env.NODE_ENV !== "production")
|
|
326
|
-
var
|
|
327
|
-
function
|
|
328
|
-
if (
|
|
329
|
-
if (
|
|
330
|
-
var
|
|
327
|
+
var d = {}, S = 0;
|
|
328
|
+
function R(M, T, O, A, W, D, Y) {
|
|
329
|
+
if (A = A || m, D = D || O, Y !== r) {
|
|
330
|
+
if (p) {
|
|
331
|
+
var h = new Error(
|
|
331
332
|
"Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types"
|
|
332
333
|
);
|
|
333
|
-
throw
|
|
334
|
+
throw h.name = "Invariant Violation", h;
|
|
334
335
|
} else if (process.env.NODE_ENV !== "production" && typeof console < "u") {
|
|
335
|
-
var G =
|
|
336
|
-
!
|
|
336
|
+
var G = A + ":" + O;
|
|
337
|
+
!d[G] && // Avoid spamming the console because they are often not actionable except for lib authors
|
|
337
338
|
S < 3 && (o(
|
|
338
|
-
"You are manually calling a React.PropTypes validation function for the `" +
|
|
339
|
-
),
|
|
339
|
+
"You are manually calling a React.PropTypes validation function for the `" + D + "` prop on `" + A + "`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details."
|
|
340
|
+
), d[G] = !0, S++);
|
|
340
341
|
}
|
|
341
342
|
}
|
|
342
|
-
return
|
|
343
|
+
return T[O] == null ? M ? T[O] === null ? new y("The " + W + " `" + D + "` is marked as required " + ("in `" + A + "`, but its value is `null`.")) : new y("The " + W + " `" + D + "` is marked as required in " + ("`" + A + "`, but its value is `undefined`.")) : null : s(T, O, A, W, D);
|
|
343
344
|
}
|
|
344
|
-
var P =
|
|
345
|
-
return P.isRequired =
|
|
345
|
+
var P = R.bind(null, !1);
|
|
346
|
+
return P.isRequired = R.bind(null, !0), P;
|
|
346
347
|
}
|
|
347
|
-
function
|
|
348
|
-
function
|
|
349
|
-
var
|
|
350
|
-
if (W !==
|
|
351
|
-
var
|
|
352
|
-
return new
|
|
353
|
-
"Invalid " +
|
|
354
|
-
{ expectedType:
|
|
348
|
+
function g(s) {
|
|
349
|
+
function d(S, R, P, M, T, O) {
|
|
350
|
+
var A = S[R], W = H(A);
|
|
351
|
+
if (W !== s) {
|
|
352
|
+
var D = X(A);
|
|
353
|
+
return new y(
|
|
354
|
+
"Invalid " + M + " `" + T + "` of type " + ("`" + D + "` supplied to `" + P + "`, expected ") + ("`" + s + "`."),
|
|
355
|
+
{ expectedType: s }
|
|
355
356
|
);
|
|
356
357
|
}
|
|
357
358
|
return null;
|
|
358
359
|
}
|
|
359
|
-
return
|
|
360
|
+
return C(d);
|
|
360
361
|
}
|
|
361
362
|
function q() {
|
|
362
|
-
return
|
|
363
|
+
return C(u);
|
|
363
364
|
}
|
|
364
|
-
function $(
|
|
365
|
-
function
|
|
366
|
-
if (typeof
|
|
367
|
-
return new
|
|
368
|
-
var
|
|
369
|
-
if (!Array.isArray(
|
|
370
|
-
var
|
|
371
|
-
return new
|
|
365
|
+
function $(s) {
|
|
366
|
+
function d(S, R, P, M, T) {
|
|
367
|
+
if (typeof s != "function")
|
|
368
|
+
return new y("Property `" + T + "` of component `" + P + "` has invalid PropType notation inside arrayOf.");
|
|
369
|
+
var O = S[R];
|
|
370
|
+
if (!Array.isArray(O)) {
|
|
371
|
+
var A = H(O);
|
|
372
|
+
return new y("Invalid " + M + " `" + T + "` of type " + ("`" + A + "` supplied to `" + P + "`, expected an array."));
|
|
372
373
|
}
|
|
373
|
-
for (var W = 0; W <
|
|
374
|
-
var
|
|
375
|
-
if (
|
|
376
|
-
return
|
|
374
|
+
for (var W = 0; W < O.length; W++) {
|
|
375
|
+
var D = s(O, W, P, M, T + "[" + W + "]", r);
|
|
376
|
+
if (D instanceof Error)
|
|
377
|
+
return D;
|
|
377
378
|
}
|
|
378
379
|
return null;
|
|
379
380
|
}
|
|
380
|
-
return
|
|
381
|
+
return C(d);
|
|
381
382
|
}
|
|
382
|
-
function
|
|
383
|
-
function
|
|
384
|
-
var
|
|
385
|
-
if (!i(
|
|
386
|
-
var
|
|
387
|
-
return new
|
|
383
|
+
function k() {
|
|
384
|
+
function s(d, S, R, P, M) {
|
|
385
|
+
var T = d[S];
|
|
386
|
+
if (!i(T)) {
|
|
387
|
+
var O = H(T);
|
|
388
|
+
return new y("Invalid " + P + " `" + M + "` of type " + ("`" + O + "` supplied to `" + R + "`, expected a single ReactElement."));
|
|
388
389
|
}
|
|
389
390
|
return null;
|
|
390
391
|
}
|
|
391
|
-
return
|
|
392
|
+
return C(s);
|
|
392
393
|
}
|
|
393
394
|
function f() {
|
|
394
|
-
function
|
|
395
|
-
var
|
|
396
|
-
if (!e.isValidElementType(
|
|
397
|
-
var
|
|
398
|
-
return new
|
|
395
|
+
function s(d, S, R, P, M) {
|
|
396
|
+
var T = d[S];
|
|
397
|
+
if (!e.isValidElementType(T)) {
|
|
398
|
+
var O = H(T);
|
|
399
|
+
return new y("Invalid " + P + " `" + M + "` of type " + ("`" + O + "` supplied to `" + R + "`, expected a single ReactElement type."));
|
|
399
400
|
}
|
|
400
401
|
return null;
|
|
401
402
|
}
|
|
402
|
-
return
|
|
403
|
+
return C(s);
|
|
403
404
|
}
|
|
404
|
-
function
|
|
405
|
-
function
|
|
406
|
-
if (!(S[
|
|
407
|
-
var
|
|
408
|
-
return new
|
|
405
|
+
function Z(s) {
|
|
406
|
+
function d(S, R, P, M, T) {
|
|
407
|
+
if (!(S[R] instanceof s)) {
|
|
408
|
+
var O = s.name || m, A = J(S[R]);
|
|
409
|
+
return new y("Invalid " + M + " `" + T + "` of type " + ("`" + A + "` supplied to `" + P + "`, expected ") + ("instance of `" + O + "`."));
|
|
409
410
|
}
|
|
410
411
|
return null;
|
|
411
412
|
}
|
|
412
|
-
return
|
|
413
|
+
return C(d);
|
|
413
414
|
}
|
|
414
|
-
function
|
|
415
|
-
if (!Array.isArray(
|
|
415
|
+
function te(s) {
|
|
416
|
+
if (!Array.isArray(s))
|
|
416
417
|
return process.env.NODE_ENV !== "production" && (arguments.length > 1 ? o(
|
|
417
418
|
"Invalid arguments supplied to oneOf, expected an array, got " + arguments.length + " arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."
|
|
418
|
-
) : o("Invalid argument supplied to oneOf, expected an array.")),
|
|
419
|
-
function
|
|
420
|
-
for (var
|
|
421
|
-
if (b(
|
|
419
|
+
) : o("Invalid argument supplied to oneOf, expected an array.")), u;
|
|
420
|
+
function d(S, R, P, M, T) {
|
|
421
|
+
for (var O = S[R], A = 0; A < s.length; A++)
|
|
422
|
+
if (b(O, s[A]))
|
|
422
423
|
return null;
|
|
423
|
-
var W = JSON.stringify(
|
|
424
|
-
var G =
|
|
425
|
-
return G === "symbol" ? String(
|
|
424
|
+
var W = JSON.stringify(s, function(Y, h) {
|
|
425
|
+
var G = X(h);
|
|
426
|
+
return G === "symbol" ? String(h) : h;
|
|
426
427
|
});
|
|
427
|
-
return new
|
|
428
|
+
return new y("Invalid " + M + " `" + T + "` of value `" + String(O) + "` " + ("supplied to `" + P + "`, expected one of " + W + "."));
|
|
428
429
|
}
|
|
429
|
-
return
|
|
430
|
+
return C(d);
|
|
430
431
|
}
|
|
431
|
-
function
|
|
432
|
-
function
|
|
433
|
-
if (typeof
|
|
434
|
-
return new
|
|
435
|
-
var
|
|
436
|
-
if (
|
|
437
|
-
return new
|
|
438
|
-
for (var W in
|
|
439
|
-
if (t(
|
|
440
|
-
var
|
|
441
|
-
if (
|
|
442
|
-
return
|
|
432
|
+
function N(s) {
|
|
433
|
+
function d(S, R, P, M, T) {
|
|
434
|
+
if (typeof s != "function")
|
|
435
|
+
return new y("Property `" + T + "` of component `" + P + "` has invalid PropType notation inside objectOf.");
|
|
436
|
+
var O = S[R], A = H(O);
|
|
437
|
+
if (A !== "object")
|
|
438
|
+
return new y("Invalid " + M + " `" + T + "` of type " + ("`" + A + "` supplied to `" + P + "`, expected an object."));
|
|
439
|
+
for (var W in O)
|
|
440
|
+
if (t(O, W)) {
|
|
441
|
+
var D = s(O, W, P, M, T + "." + W, r);
|
|
442
|
+
if (D instanceof Error)
|
|
443
|
+
return D;
|
|
443
444
|
}
|
|
444
445
|
return null;
|
|
445
446
|
}
|
|
446
|
-
return
|
|
447
|
+
return C(d);
|
|
447
448
|
}
|
|
448
|
-
function
|
|
449
|
-
if (!Array.isArray(
|
|
450
|
-
return process.env.NODE_ENV !== "production" && o("Invalid argument supplied to oneOfType, expected an instance of array."),
|
|
451
|
-
for (var
|
|
452
|
-
var S =
|
|
449
|
+
function E(s) {
|
|
450
|
+
if (!Array.isArray(s))
|
|
451
|
+
return process.env.NODE_ENV !== "production" && o("Invalid argument supplied to oneOfType, expected an instance of array."), u;
|
|
452
|
+
for (var d = 0; d < s.length; d++) {
|
|
453
|
+
var S = s[d];
|
|
453
454
|
if (typeof S != "function")
|
|
454
455
|
return o(
|
|
455
|
-
"Invalid argument supplied to oneOfType. Expected an array of check functions, but received " + U(S) + " at index " +
|
|
456
|
-
),
|
|
456
|
+
"Invalid argument supplied to oneOfType. Expected an array of check functions, but received " + U(S) + " at index " + d + "."
|
|
457
|
+
), u;
|
|
457
458
|
}
|
|
458
|
-
function
|
|
459
|
-
for (var W = [],
|
|
460
|
-
var Y =
|
|
461
|
-
if (
|
|
459
|
+
function R(P, M, T, O, A) {
|
|
460
|
+
for (var W = [], D = 0; D < s.length; D++) {
|
|
461
|
+
var Y = s[D], h = Y(P, M, T, O, A, r);
|
|
462
|
+
if (h == null)
|
|
462
463
|
return null;
|
|
463
|
-
|
|
464
|
+
h.data && t(h.data, "expectedType") && W.push(h.data.expectedType);
|
|
464
465
|
}
|
|
465
466
|
var G = W.length > 0 ? ", expected one of type [" + W.join(", ") + "]" : "";
|
|
466
|
-
return new
|
|
467
|
+
return new y("Invalid " + O + " `" + A + "` supplied to " + ("`" + T + "`" + G + "."));
|
|
467
468
|
}
|
|
468
|
-
return
|
|
469
|
+
return C(R);
|
|
469
470
|
}
|
|
470
471
|
function w() {
|
|
471
|
-
function
|
|
472
|
-
return K(
|
|
472
|
+
function s(d, S, R, P, M) {
|
|
473
|
+
return K(d[S]) ? null : new y("Invalid " + P + " `" + M + "` supplied to " + ("`" + R + "`, expected a ReactNode."));
|
|
473
474
|
}
|
|
474
|
-
return
|
|
475
|
+
return C(s);
|
|
475
476
|
}
|
|
476
|
-
function B(
|
|
477
|
-
return new
|
|
478
|
-
(
|
|
477
|
+
function B(s, d, S, R, P) {
|
|
478
|
+
return new y(
|
|
479
|
+
(s || "React class") + ": " + d + " type `" + S + "." + R + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + P + "`."
|
|
479
480
|
);
|
|
480
481
|
}
|
|
481
|
-
function F(
|
|
482
|
-
function
|
|
483
|
-
var
|
|
484
|
-
if (
|
|
485
|
-
return new
|
|
486
|
-
for (var W in
|
|
487
|
-
var
|
|
488
|
-
if (typeof
|
|
489
|
-
return B(P,
|
|
490
|
-
var Y =
|
|
482
|
+
function F(s) {
|
|
483
|
+
function d(S, R, P, M, T) {
|
|
484
|
+
var O = S[R], A = H(O);
|
|
485
|
+
if (A !== "object")
|
|
486
|
+
return new y("Invalid " + M + " `" + T + "` of type `" + A + "` " + ("supplied to `" + P + "`, expected `object`."));
|
|
487
|
+
for (var W in s) {
|
|
488
|
+
var D = s[W];
|
|
489
|
+
if (typeof D != "function")
|
|
490
|
+
return B(P, M, T, W, X(D));
|
|
491
|
+
var Y = D(O, W, P, M, T + "." + W, r);
|
|
491
492
|
if (Y)
|
|
492
493
|
return Y;
|
|
493
494
|
}
|
|
494
495
|
return null;
|
|
495
496
|
}
|
|
496
|
-
return
|
|
497
|
+
return C(d);
|
|
497
498
|
}
|
|
498
|
-
function
|
|
499
|
-
function
|
|
500
|
-
var
|
|
501
|
-
if (
|
|
502
|
-
return new
|
|
503
|
-
var W = a({}, S[
|
|
504
|
-
for (var
|
|
505
|
-
var Y =
|
|
506
|
-
if (t(
|
|
507
|
-
return B(P,
|
|
499
|
+
function _(s) {
|
|
500
|
+
function d(S, R, P, M, T) {
|
|
501
|
+
var O = S[R], A = H(O);
|
|
502
|
+
if (A !== "object")
|
|
503
|
+
return new y("Invalid " + M + " `" + T + "` of type `" + A + "` " + ("supplied to `" + P + "`, expected `object`."));
|
|
504
|
+
var W = a({}, S[R], s);
|
|
505
|
+
for (var D in W) {
|
|
506
|
+
var Y = s[D];
|
|
507
|
+
if (t(s, D) && typeof Y != "function")
|
|
508
|
+
return B(P, M, T, D, X(Y));
|
|
508
509
|
if (!Y)
|
|
509
|
-
return new
|
|
510
|
-
"Invalid " +
|
|
511
|
-
Valid keys: ` + JSON.stringify(Object.keys(
|
|
510
|
+
return new y(
|
|
511
|
+
"Invalid " + M + " `" + T + "` key `" + D + "` supplied to `" + P + "`.\nBad object: " + JSON.stringify(S[R], null, " ") + `
|
|
512
|
+
Valid keys: ` + JSON.stringify(Object.keys(s), null, " ")
|
|
512
513
|
);
|
|
513
|
-
var
|
|
514
|
-
if (
|
|
515
|
-
return
|
|
514
|
+
var h = Y(O, D, P, M, T + "." + D, r);
|
|
515
|
+
if (h)
|
|
516
|
+
return h;
|
|
516
517
|
}
|
|
517
518
|
return null;
|
|
518
519
|
}
|
|
519
|
-
return
|
|
520
|
+
return C(d);
|
|
520
521
|
}
|
|
521
|
-
function K(
|
|
522
|
-
switch (typeof
|
|
522
|
+
function K(s) {
|
|
523
|
+
switch (typeof s) {
|
|
523
524
|
case "number":
|
|
524
525
|
case "string":
|
|
525
526
|
case "undefined":
|
|
526
527
|
return !0;
|
|
527
528
|
case "boolean":
|
|
528
|
-
return !
|
|
529
|
+
return !s;
|
|
529
530
|
case "object":
|
|
530
|
-
if (Array.isArray(
|
|
531
|
-
return
|
|
532
|
-
if (
|
|
531
|
+
if (Array.isArray(s))
|
|
532
|
+
return s.every(K);
|
|
533
|
+
if (s === null || i(s))
|
|
533
534
|
return !0;
|
|
534
|
-
var
|
|
535
|
-
if (
|
|
536
|
-
var S =
|
|
537
|
-
if (
|
|
538
|
-
for (; !(
|
|
539
|
-
if (!K(
|
|
535
|
+
var d = v(s);
|
|
536
|
+
if (d) {
|
|
537
|
+
var S = d.call(s), R;
|
|
538
|
+
if (d !== s.entries) {
|
|
539
|
+
for (; !(R = S.next()).done; )
|
|
540
|
+
if (!K(R.value))
|
|
540
541
|
return !1;
|
|
541
542
|
} else
|
|
542
|
-
for (; !(
|
|
543
|
-
var P =
|
|
543
|
+
for (; !(R = S.next()).done; ) {
|
|
544
|
+
var P = R.value;
|
|
544
545
|
if (P && !K(P[1]))
|
|
545
546
|
return !1;
|
|
546
547
|
}
|
|
@@ -551,61 +552,61 @@ Valid keys: ` + JSON.stringify(Object.keys(u), null, " ")
|
|
|
551
552
|
return !1;
|
|
552
553
|
}
|
|
553
554
|
}
|
|
554
|
-
function ae(
|
|
555
|
-
return
|
|
555
|
+
function ae(s, d) {
|
|
556
|
+
return s === "symbol" ? !0 : d ? d["@@toStringTag"] === "Symbol" || typeof Symbol == "function" && d instanceof Symbol : !1;
|
|
556
557
|
}
|
|
557
|
-
function H(
|
|
558
|
-
var
|
|
559
|
-
return Array.isArray(
|
|
558
|
+
function H(s) {
|
|
559
|
+
var d = typeof s;
|
|
560
|
+
return Array.isArray(s) ? "array" : s instanceof RegExp ? "object" : ae(d, s) ? "symbol" : d;
|
|
560
561
|
}
|
|
561
|
-
function
|
|
562
|
-
if (typeof
|
|
563
|
-
return "" +
|
|
564
|
-
var
|
|
565
|
-
if (
|
|
566
|
-
if (
|
|
562
|
+
function X(s) {
|
|
563
|
+
if (typeof s > "u" || s === null)
|
|
564
|
+
return "" + s;
|
|
565
|
+
var d = H(s);
|
|
566
|
+
if (d === "object") {
|
|
567
|
+
if (s instanceof Date)
|
|
567
568
|
return "date";
|
|
568
|
-
if (
|
|
569
|
+
if (s instanceof RegExp)
|
|
569
570
|
return "regexp";
|
|
570
571
|
}
|
|
571
|
-
return
|
|
572
|
+
return d;
|
|
572
573
|
}
|
|
573
|
-
function U(
|
|
574
|
-
var
|
|
575
|
-
switch (
|
|
574
|
+
function U(s) {
|
|
575
|
+
var d = X(s);
|
|
576
|
+
switch (d) {
|
|
576
577
|
case "array":
|
|
577
578
|
case "object":
|
|
578
|
-
return "an " +
|
|
579
|
+
return "an " + d;
|
|
579
580
|
case "boolean":
|
|
580
581
|
case "date":
|
|
581
582
|
case "regexp":
|
|
582
|
-
return "a " +
|
|
583
|
+
return "a " + d;
|
|
583
584
|
default:
|
|
584
|
-
return
|
|
585
|
+
return d;
|
|
585
586
|
}
|
|
586
587
|
}
|
|
587
|
-
function
|
|
588
|
-
return !
|
|
588
|
+
function J(s) {
|
|
589
|
+
return !s.constructor || !s.constructor.name ? m : s.constructor.name;
|
|
589
590
|
}
|
|
590
|
-
return
|
|
591
|
+
return x.checkPropTypes = n, x.resetWarningCache = n.resetWarningCache, x.PropTypes = x, x;
|
|
591
592
|
}, me;
|
|
592
593
|
}
|
|
593
|
-
var ge,
|
|
594
|
+
var ge, ke;
|
|
594
595
|
function Ke() {
|
|
595
|
-
if (
|
|
596
|
-
|
|
596
|
+
if (ke) return ge;
|
|
597
|
+
ke = 1;
|
|
597
598
|
var e = /* @__PURE__ */ _e();
|
|
598
599
|
function a() {
|
|
599
600
|
}
|
|
600
601
|
function r() {
|
|
601
602
|
}
|
|
602
603
|
return r.resetWarningCache = a, ge = function() {
|
|
603
|
-
function t(
|
|
604
|
+
function t(u, i, p, c, l, v) {
|
|
604
605
|
if (v !== e) {
|
|
605
|
-
var
|
|
606
|
+
var m = new Error(
|
|
606
607
|
"Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types"
|
|
607
608
|
);
|
|
608
|
-
throw
|
|
609
|
+
throw m.name = "Invariant Violation", m;
|
|
609
610
|
}
|
|
610
611
|
}
|
|
611
612
|
t.isRequired = t;
|
|
@@ -638,11 +639,11 @@ function Ke() {
|
|
|
638
639
|
return o.PropTypes = o, o;
|
|
639
640
|
}, ge;
|
|
640
641
|
}
|
|
641
|
-
var
|
|
642
|
+
var Ie;
|
|
642
643
|
function Qe() {
|
|
643
|
-
if (
|
|
644
|
-
if (
|
|
645
|
-
var e =
|
|
644
|
+
if (Ie) return ue.exports;
|
|
645
|
+
if (Ie = 1, process.env.NODE_ENV !== "production") {
|
|
646
|
+
var e = We(), a = !0;
|
|
646
647
|
ue.exports = /* @__PURE__ */ Ge()(e.isElement, a);
|
|
647
648
|
} else
|
|
648
649
|
ue.exports = /* @__PURE__ */ Ke()();
|
|
@@ -665,12 +666,12 @@ function xe(e, a, r, t) {
|
|
|
665
666
|
}
|
|
666
667
|
xe.prototype.length = function() {
|
|
667
668
|
for (var e = 10, a = 0, r = void 0, t = void 0, n = 0; n <= e; n += 1) {
|
|
668
|
-
var o = n / e,
|
|
669
|
+
var o = n / e, u = this._point(o, this.startPoint.x, this.control1.x, this.control2.x, this.endPoint.x), i = this._point(o, this.startPoint.y, this.control1.y, this.control2.y, this.endPoint.y);
|
|
669
670
|
if (n > 0) {
|
|
670
|
-
var
|
|
671
|
-
a += Math.sqrt(
|
|
671
|
+
var p = u - r, c = i - t;
|
|
672
|
+
a += Math.sqrt(p * p + c * c);
|
|
672
673
|
}
|
|
673
|
-
r =
|
|
674
|
+
r = u, t = i;
|
|
674
675
|
}
|
|
675
676
|
return a;
|
|
676
677
|
};
|
|
@@ -678,16 +679,16 @@ xe.prototype._point = function(e, a, r, t, n) {
|
|
|
678
679
|
return a * (1 - e) * (1 - e) * (1 - e) + 3 * r * (1 - e) * (1 - e) * e + 3 * t * (1 - e) * e * e + n * e * e * e;
|
|
679
680
|
};
|
|
680
681
|
function et(e, a, r) {
|
|
681
|
-
var t, n, o,
|
|
682
|
+
var t, n, o, u = null, i = 0;
|
|
682
683
|
r || (r = {});
|
|
683
|
-
var
|
|
684
|
-
i = r.leading === !1 ? 0 : Date.now(),
|
|
684
|
+
var p = function() {
|
|
685
|
+
i = r.leading === !1 ? 0 : Date.now(), u = null, o = e.apply(t, n), u || (t = n = null);
|
|
685
686
|
};
|
|
686
687
|
return function() {
|
|
687
|
-
var
|
|
688
|
-
!i && r.leading === !1 && (i =
|
|
689
|
-
var l = a - (
|
|
690
|
-
return t = this, n = arguments, l <= 0 || l > a ? (
|
|
688
|
+
var c = Date.now();
|
|
689
|
+
!i && r.leading === !1 && (i = c);
|
|
690
|
+
var l = a - (c - i);
|
|
691
|
+
return t = this, n = arguments, l <= 0 || l > a ? (u && (clearTimeout(u), u = null), i = c, o = e.apply(t, n), u || (t = n = null)) : !u && r.trailing !== !1 && (u = setTimeout(p, l)), o;
|
|
691
692
|
};
|
|
692
693
|
}
|
|
693
694
|
function L(e, a) {
|
|
@@ -719,9 +720,9 @@ L.prototype.clear = function() {
|
|
|
719
720
|
e.fillStyle = this.backgroundColor, e.clearRect(0, 0, a.width, a.height), e.fillRect(0, 0, a.width, a.height), this._data = [], this._reset(), this._isEmpty = !0;
|
|
720
721
|
};
|
|
721
722
|
L.prototype.fromDataURL = function(e) {
|
|
722
|
-
var a = this, r = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, t = new Image(), n = r.ratio || window.devicePixelRatio || 1, o = r.width || this._canvas.width / n,
|
|
723
|
+
var a = this, r = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, t = new Image(), n = r.ratio || window.devicePixelRatio || 1, o = r.width || this._canvas.width / n, u = r.height || this._canvas.height / n;
|
|
723
724
|
this._reset(), t.src = e, t.onload = function() {
|
|
724
|
-
a._ctx.drawImage(t, 0, 0, o,
|
|
725
|
+
a._ctx.drawImage(t, 0, 0, o, u);
|
|
725
726
|
}, this._isEmpty = !1;
|
|
726
727
|
};
|
|
727
728
|
L.prototype.toDataURL = function(e) {
|
|
@@ -748,10 +749,10 @@ L.prototype._strokeBegin = function(e) {
|
|
|
748
749
|
this._data.push([]), this._reset(), this._strokeUpdate(e), typeof this.onBegin == "function" && this.onBegin(e);
|
|
749
750
|
};
|
|
750
751
|
L.prototype._strokeUpdate = function(e) {
|
|
751
|
-
var a = e.clientX, r = e.clientY, t = this._createPoint(a, r), n = this._data[this._data.length - 1], o = n && n[n.length - 1],
|
|
752
|
-
if (!(o &&
|
|
753
|
-
var i = this._addPoint(t),
|
|
754
|
-
|
|
752
|
+
var a = e.clientX, r = e.clientY, t = this._createPoint(a, r), n = this._data[this._data.length - 1], o = n && n[n.length - 1], u = o && t.distanceTo(o) < this.minDistance;
|
|
753
|
+
if (!(o && u)) {
|
|
754
|
+
var i = this._addPoint(t), p = i.curve, c = i.widths;
|
|
755
|
+
p && c && this._drawCurve(p, c.start, c.end), this._data[this._data.length - 1].push({
|
|
755
756
|
x: t.x,
|
|
756
757
|
y: t.y,
|
|
757
758
|
time: t.time,
|
|
@@ -791,16 +792,16 @@ L.prototype._addPoint = function(e) {
|
|
|
791
792
|
a.length === 3 && a.unshift(a[0]), r = this._calculateCurveControlPoints(a[0], a[1], a[2]);
|
|
792
793
|
var t = r.c2;
|
|
793
794
|
r = this._calculateCurveControlPoints(a[1], a[2], a[3]);
|
|
794
|
-
var n = r.c1, o = new xe(a[1], t, n, a[2]),
|
|
795
|
-
return a.shift(), { curve: o, widths:
|
|
795
|
+
var n = r.c1, o = new xe(a[1], t, n, a[2]), u = this._calculateCurveWidths(o);
|
|
796
|
+
return a.shift(), { curve: o, widths: u };
|
|
796
797
|
}
|
|
797
798
|
return {};
|
|
798
799
|
};
|
|
799
800
|
L.prototype._calculateCurveControlPoints = function(e, a, r) {
|
|
800
|
-
var t = e.x - a.x, n = e.y - a.y, o = a.x - r.x,
|
|
801
|
+
var t = e.x - a.x, n = e.y - a.y, o = a.x - r.x, u = a.y - r.y, i = { x: (e.x + a.x) / 2, y: (e.y + a.y) / 2 }, p = { x: (a.x + r.x) / 2, y: (a.y + r.y) / 2 }, c = Math.sqrt(t * t + n * n), l = Math.sqrt(o * o + u * u), v = i.x - p.x, m = i.y - p.y, x = l / (c + l), b = { x: p.x + v * x, y: p.y + m * x }, y = a.x - b.x, C = a.y - b.y;
|
|
801
802
|
return {
|
|
802
|
-
c1: new ne(i.x +
|
|
803
|
-
c2: new ne(
|
|
803
|
+
c1: new ne(i.x + y, i.y + C),
|
|
804
|
+
c2: new ne(p.x + y, p.y + C)
|
|
804
805
|
};
|
|
805
806
|
};
|
|
806
807
|
L.prototype._calculateCurveWidths = function(e) {
|
|
@@ -817,13 +818,13 @@ L.prototype._drawPoint = function(e, a, r) {
|
|
|
817
818
|
L.prototype._drawCurve = function(e, a, r) {
|
|
818
819
|
var t = this._ctx, n = r - a, o = Math.floor(e.length());
|
|
819
820
|
t.beginPath();
|
|
820
|
-
for (var
|
|
821
|
-
var i =
|
|
822
|
-
|
|
823
|
-
var b =
|
|
824
|
-
b += 3 * v * i * e.control1.y, b += 3 * l *
|
|
825
|
-
var
|
|
826
|
-
this._drawPoint(
|
|
821
|
+
for (var u = 0; u < o; u += 1) {
|
|
822
|
+
var i = u / o, p = i * i, c = p * i, l = 1 - i, v = l * l, m = v * l, x = m * e.startPoint.x;
|
|
823
|
+
x += 3 * v * i * e.control1.x, x += 3 * l * p * e.control2.x, x += c * e.endPoint.x;
|
|
824
|
+
var b = m * e.startPoint.y;
|
|
825
|
+
b += 3 * v * i * e.control1.y, b += 3 * l * p * e.control2.y, b += c * e.endPoint.y;
|
|
826
|
+
var y = a + c * n;
|
|
827
|
+
this._drawPoint(x, b, y);
|
|
827
828
|
}
|
|
828
829
|
t.closePath(), t.fill();
|
|
829
830
|
};
|
|
@@ -836,43 +837,43 @@ L.prototype._fromData = function(e, a, r) {
|
|
|
836
837
|
var n = e[t];
|
|
837
838
|
if (n.length > 1)
|
|
838
839
|
for (var o = 0; o < n.length; o += 1) {
|
|
839
|
-
var
|
|
840
|
+
var u = n[o], i = new ne(u.x, u.y, u.time), p = u.color;
|
|
840
841
|
if (o === 0)
|
|
841
|
-
this.penColor =
|
|
842
|
+
this.penColor = p, this._reset(), this._addPoint(i);
|
|
842
843
|
else if (o !== n.length - 1) {
|
|
843
|
-
var
|
|
844
|
-
l && v && a(l, v,
|
|
844
|
+
var c = this._addPoint(i), l = c.curve, v = c.widths;
|
|
845
|
+
l && v && a(l, v, p);
|
|
845
846
|
}
|
|
846
847
|
}
|
|
847
848
|
else {
|
|
848
849
|
this._reset();
|
|
849
|
-
var
|
|
850
|
-
r(
|
|
850
|
+
var m = n[0];
|
|
851
|
+
r(m);
|
|
851
852
|
}
|
|
852
853
|
}
|
|
853
854
|
};
|
|
854
855
|
L.prototype._toSVG = function() {
|
|
855
|
-
var e = this, a = this._data, r = this._canvas, t = Math.max(window.devicePixelRatio || 1, 1), n = 0, o = 0,
|
|
856
|
-
|
|
857
|
-
var
|
|
858
|
-
if (!isNaN(
|
|
859
|
-
var f = "M " +
|
|
860
|
-
|
|
856
|
+
var e = this, a = this._data, r = this._canvas, t = Math.max(window.devicePixelRatio || 1, 1), n = 0, o = 0, u = r.width / t, i = r.height / t, p = document.createElementNS("http://www.w3.org/2000/svg", "svg");
|
|
857
|
+
p.setAttributeNS(null, "width", r.width), p.setAttributeNS(null, "height", r.height), this._fromData(a, function(g, q, $) {
|
|
858
|
+
var k = document.createElement("path");
|
|
859
|
+
if (!isNaN(g.control1.x) && !isNaN(g.control1.y) && !isNaN(g.control2.x) && !isNaN(g.control2.y)) {
|
|
860
|
+
var f = "M " + g.startPoint.x.toFixed(3) + "," + g.startPoint.y.toFixed(3) + " " + ("C " + g.control1.x.toFixed(3) + "," + g.control1.y.toFixed(3) + " ") + (g.control2.x.toFixed(3) + "," + g.control2.y.toFixed(3) + " ") + (g.endPoint.x.toFixed(3) + "," + g.endPoint.y.toFixed(3));
|
|
861
|
+
k.setAttribute("d", f), k.setAttribute("stroke-width", (q.end * 2.25).toFixed(3)), k.setAttribute("stroke", $), k.setAttribute("fill", "none"), k.setAttribute("stroke-linecap", "round"), p.appendChild(k);
|
|
861
862
|
}
|
|
862
|
-
}, function(
|
|
863
|
+
}, function(g) {
|
|
863
864
|
var q = document.createElement("circle"), $ = typeof e.dotSize == "function" ? e.dotSize() : e.dotSize;
|
|
864
|
-
q.setAttribute("r", $), q.setAttribute("cx",
|
|
865
|
+
q.setAttribute("r", $), q.setAttribute("cx", g.x), q.setAttribute("cy", g.y), q.setAttribute("fill", g.color), p.appendChild(q);
|
|
865
866
|
});
|
|
866
|
-
var
|
|
867
|
+
var c = "data:image/svg+xml;base64,", l = '<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"' + (' viewBox="' + n + " " + o + " " + u + " " + i + '"') + (' width="' + u + '"') + (' height="' + i + '"') + ">", v = p.innerHTML;
|
|
867
868
|
if (v === void 0) {
|
|
868
|
-
var
|
|
869
|
-
|
|
870
|
-
for (var b = 0; b <
|
|
871
|
-
|
|
872
|
-
v =
|
|
869
|
+
var m = document.createElement("dummy"), x = p.childNodes;
|
|
870
|
+
m.innerHTML = "";
|
|
871
|
+
for (var b = 0; b < x.length; b += 1)
|
|
872
|
+
m.appendChild(x[b].cloneNode(!0));
|
|
873
|
+
v = m.innerHTML;
|
|
873
874
|
}
|
|
874
|
-
var
|
|
875
|
-
return
|
|
875
|
+
var y = "</svg>", C = l + v + y;
|
|
876
|
+
return c + btoa(C);
|
|
876
877
|
};
|
|
877
878
|
L.prototype.fromData = function(e) {
|
|
878
879
|
var a = this;
|
|
@@ -888,38 +889,38 @@ L.prototype.toData = function() {
|
|
|
888
889
|
const tt = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
889
890
|
__proto__: null,
|
|
890
891
|
default: L
|
|
891
|
-
}, Symbol.toStringTag, { value: "Module" })), rt = /* @__PURE__ */
|
|
892
|
-
var fe = { exports: {} }, nt = fe.exports,
|
|
892
|
+
}, Symbol.toStringTag, { value: "Module" })), rt = /* @__PURE__ */ qe(tt);
|
|
893
|
+
var fe = { exports: {} }, nt = fe.exports, je;
|
|
893
894
|
function at() {
|
|
894
|
-
return
|
|
895
|
+
return je || (je = 1, (function(e, a) {
|
|
895
896
|
(function(r, t) {
|
|
896
897
|
e.exports = t();
|
|
897
898
|
})(nt, function() {
|
|
898
899
|
return (function(r) {
|
|
899
900
|
function t(o) {
|
|
900
901
|
if (n[o]) return n[o].exports;
|
|
901
|
-
var
|
|
902
|
-
return r[o].call(
|
|
902
|
+
var u = n[o] = { exports: {}, id: o, loaded: !1 };
|
|
903
|
+
return r[o].call(u.exports, u, u.exports, t), u.loaded = !0, u.exports;
|
|
903
904
|
}
|
|
904
905
|
var n = {};
|
|
905
906
|
return t.m = r, t.c = n, t.p = "", t(0);
|
|
906
907
|
})([function(r, t) {
|
|
907
|
-
function n(
|
|
908
|
-
var l =
|
|
909
|
-
return
|
|
908
|
+
function n(c) {
|
|
909
|
+
var l = c.getContext("2d"), v = c.width, m = c.height, x = l.getImageData(0, 0, v, m).data, b = i(!0, v, m, x), y = i(!1, v, m, x), C = p(!0, v, m, x), g = p(!1, v, m, x), q = g - C + 1, $ = y - b + 1, k = l.getImageData(C, b, q, $);
|
|
910
|
+
return c.width = q, c.height = $, l.clearRect(0, 0, q, $), l.putImageData(k, 0, 0), c;
|
|
910
911
|
}
|
|
911
|
-
function o(
|
|
912
|
-
return { red:
|
|
912
|
+
function o(c, l, v, m) {
|
|
913
|
+
return { red: m[4 * (v * l + c)], green: m[4 * (v * l + c) + 1], blue: m[4 * (v * l + c) + 2], alpha: m[4 * (v * l + c) + 3] };
|
|
913
914
|
}
|
|
914
|
-
function c
|
|
915
|
-
return o(
|
|
915
|
+
function u(c, l, v, m) {
|
|
916
|
+
return o(c, l, v, m).alpha;
|
|
916
917
|
}
|
|
917
|
-
function i(
|
|
918
|
-
for (var
|
|
918
|
+
function i(c, l, v, m) {
|
|
919
|
+
for (var x = c ? 1 : -1, b = c ? 0 : v - 1, y = b; c ? y < v : y > -1; y += x) for (var C = 0; C < l; C++) if (u(C, y, l, m)) return y;
|
|
919
920
|
return null;
|
|
920
921
|
}
|
|
921
|
-
function
|
|
922
|
-
for (var
|
|
922
|
+
function p(c, l, v, m) {
|
|
923
|
+
for (var x = c ? 1 : -1, b = c ? 0 : l - 1, y = b; c ? y < l : y > -1; y += x) for (var C = 0; C < v; C++) if (u(y, C, l, m)) return y;
|
|
923
924
|
return null;
|
|
924
925
|
}
|
|
925
926
|
Object.defineProperty(t, "__esModule", { value: !0 }), t.default = n;
|
|
@@ -927,99 +928,99 @@ function at() {
|
|
|
927
928
|
});
|
|
928
929
|
})(fe)), fe.exports;
|
|
929
930
|
}
|
|
930
|
-
var ot = le.exports,
|
|
931
|
+
var ot = le.exports, $e;
|
|
931
932
|
function it() {
|
|
932
|
-
return
|
|
933
|
+
return $e || ($e = 1, (function(e, a) {
|
|
933
934
|
(function(r, t) {
|
|
934
|
-
e.exports = t(/* @__PURE__ */ Qe(),
|
|
935
|
+
e.exports = t(/* @__PURE__ */ Qe(), ze, rt, at());
|
|
935
936
|
})(ot, function(r, t, n, o) {
|
|
936
|
-
return (function(
|
|
937
|
-
function i(
|
|
938
|
-
if (
|
|
939
|
-
var l =
|
|
940
|
-
return c
|
|
937
|
+
return (function(u) {
|
|
938
|
+
function i(c) {
|
|
939
|
+
if (p[c]) return p[c].exports;
|
|
940
|
+
var l = p[c] = { exports: {}, id: c, loaded: !1 };
|
|
941
|
+
return u[c].call(l.exports, l, l.exports, i), l.loaded = !0, l.exports;
|
|
941
942
|
}
|
|
942
|
-
var
|
|
943
|
-
return i.m =
|
|
944
|
-
})([function(
|
|
945
|
-
function
|
|
946
|
-
return
|
|
943
|
+
var p = {};
|
|
944
|
+
return i.m = u, i.c = p, i.p = "", i(0);
|
|
945
|
+
})([function(u, i, p) {
|
|
946
|
+
function c(E) {
|
|
947
|
+
return E && E.__esModule ? E : { default: E };
|
|
947
948
|
}
|
|
948
|
-
function l(
|
|
949
|
+
function l(E, w) {
|
|
949
950
|
var B = {};
|
|
950
|
-
for (var F in
|
|
951
|
+
for (var F in E) w.indexOf(F) >= 0 || Object.prototype.hasOwnProperty.call(E, F) && (B[F] = E[F]);
|
|
951
952
|
return B;
|
|
952
953
|
}
|
|
953
|
-
function v(
|
|
954
|
-
if (!(
|
|
954
|
+
function v(E, w) {
|
|
955
|
+
if (!(E instanceof w)) throw new TypeError("Cannot call a class as a function");
|
|
955
956
|
}
|
|
956
|
-
function
|
|
957
|
-
if (!
|
|
958
|
-
return !w || typeof w != "object" && typeof w != "function" ?
|
|
957
|
+
function m(E, w) {
|
|
958
|
+
if (!E) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
959
|
+
return !w || typeof w != "object" && typeof w != "function" ? E : w;
|
|
959
960
|
}
|
|
960
|
-
function
|
|
961
|
+
function x(E, w) {
|
|
961
962
|
if (typeof w != "function" && w !== null) throw new TypeError("Super expression must either be null or a function, not " + typeof w);
|
|
962
|
-
|
|
963
|
+
E.prototype = Object.create(w && w.prototype, { constructor: { value: E, enumerable: !1, writable: !0, configurable: !0 } }), w && (Object.setPrototypeOf ? Object.setPrototypeOf(E, w) : E.__proto__ = w);
|
|
963
964
|
}
|
|
964
965
|
Object.defineProperty(i, "__esModule", { value: !0 });
|
|
965
|
-
var b = Object.assign || function(
|
|
966
|
+
var b = Object.assign || function(E) {
|
|
966
967
|
for (var w = 1; w < arguments.length; w++) {
|
|
967
968
|
var B = arguments[w];
|
|
968
|
-
for (var F in B) Object.prototype.hasOwnProperty.call(B, F) && (
|
|
969
|
+
for (var F in B) Object.prototype.hasOwnProperty.call(B, F) && (E[F] = B[F]);
|
|
969
970
|
}
|
|
970
|
-
return
|
|
971
|
-
},
|
|
972
|
-
function
|
|
971
|
+
return E;
|
|
972
|
+
}, y = /* @__PURE__ */ (function() {
|
|
973
|
+
function E(w, B) {
|
|
973
974
|
for (var F = 0; F < B.length; F++) {
|
|
974
|
-
var
|
|
975
|
-
|
|
975
|
+
var _ = B[F];
|
|
976
|
+
_.enumerable = _.enumerable || !1, _.configurable = !0, "value" in _ && (_.writable = !0), Object.defineProperty(w, _.key, _);
|
|
976
977
|
}
|
|
977
978
|
}
|
|
978
979
|
return function(w, B, F) {
|
|
979
|
-
return B &&
|
|
980
|
+
return B && E(w.prototype, B), F && E(w, F), w;
|
|
980
981
|
};
|
|
981
|
-
})(),
|
|
982
|
+
})(), C = p(1), g = c(C), q = p(2), $ = c(q), k = p(3), f = c(k), Z = p(4), te = c(Z), N = (function(E) {
|
|
982
983
|
function w() {
|
|
983
|
-
var B, F,
|
|
984
|
+
var B, F, _, K;
|
|
984
985
|
v(this, w);
|
|
985
|
-
for (var ae = arguments.length, H = Array(ae),
|
|
986
|
-
return F =
|
|
987
|
-
var U =
|
|
988
|
-
return
|
|
989
|
-
},
|
|
990
|
-
return
|
|
991
|
-
},
|
|
986
|
+
for (var ae = arguments.length, H = Array(ae), X = 0; X < ae; X++) H[X] = arguments[X];
|
|
987
|
+
return F = _ = m(this, (B = w.__proto__ || Object.getPrototypeOf(w)).call.apply(B, [this].concat(H))), _._sigPad = null, _._excludeOurProps = function() {
|
|
988
|
+
var U = _.props, J = (U.canvasProps, U.clearOnResize, l(U, ["canvasProps", "clearOnResize"]));
|
|
989
|
+
return J;
|
|
990
|
+
}, _.getCanvas = function() {
|
|
991
|
+
return _._canvas;
|
|
992
|
+
}, _.getTrimmedCanvas = function() {
|
|
992
993
|
var U = document.createElement("canvas");
|
|
993
|
-
return U.width =
|
|
994
|
-
},
|
|
995
|
-
return
|
|
996
|
-
},
|
|
997
|
-
|
|
998
|
-
},
|
|
999
|
-
var U =
|
|
1000
|
-
if (!
|
|
1001
|
-
var
|
|
1002
|
-
|
|
994
|
+
return U.width = _._canvas.width, U.height = _._canvas.height, U.getContext("2d").drawImage(_._canvas, 0, 0), (0, te.default)(U);
|
|
995
|
+
}, _.getSignaturePad = function() {
|
|
996
|
+
return _._sigPad;
|
|
997
|
+
}, _._checkClearOnResize = function() {
|
|
998
|
+
_.props.clearOnResize && _._resizeCanvas();
|
|
999
|
+
}, _._resizeCanvas = function() {
|
|
1000
|
+
var U = _.props.canvasProps || {}, J = U.width, s = U.height;
|
|
1001
|
+
if (!J || !s) {
|
|
1002
|
+
var d = _._canvas, S = Math.max(window.devicePixelRatio || 1, 1);
|
|
1003
|
+
J || (d.width = d.offsetWidth * S), s || (d.height = d.offsetHeight * S), d.getContext("2d").scale(S, S), _.clear();
|
|
1003
1004
|
}
|
|
1004
|
-
},
|
|
1005
|
-
return window.addEventListener("resize",
|
|
1006
|
-
},
|
|
1007
|
-
return window.removeEventListener("resize",
|
|
1008
|
-
},
|
|
1009
|
-
return
|
|
1010
|
-
},
|
|
1011
|
-
return
|
|
1012
|
-
},
|
|
1013
|
-
return
|
|
1014
|
-
},
|
|
1015
|
-
return
|
|
1016
|
-
},
|
|
1017
|
-
return
|
|
1018
|
-
},
|
|
1019
|
-
return
|
|
1020
|
-
}, K = F,
|
|
1005
|
+
}, _.on = function() {
|
|
1006
|
+
return window.addEventListener("resize", _._checkClearOnResize), _._sigPad.on();
|
|
1007
|
+
}, _.off = function() {
|
|
1008
|
+
return window.removeEventListener("resize", _._checkClearOnResize), _._sigPad.off();
|
|
1009
|
+
}, _.clear = function() {
|
|
1010
|
+
return _._sigPad.clear();
|
|
1011
|
+
}, _.isEmpty = function() {
|
|
1012
|
+
return _._sigPad.isEmpty();
|
|
1013
|
+
}, _.fromDataURL = function(U, J) {
|
|
1014
|
+
return _._sigPad.fromDataURL(U, J);
|
|
1015
|
+
}, _.toDataURL = function(U, J) {
|
|
1016
|
+
return _._sigPad.toDataURL(U, J);
|
|
1017
|
+
}, _.fromData = function(U) {
|
|
1018
|
+
return _._sigPad.fromData(U);
|
|
1019
|
+
}, _.toData = function() {
|
|
1020
|
+
return _._sigPad.toData();
|
|
1021
|
+
}, K = F, m(_, K);
|
|
1021
1022
|
}
|
|
1022
|
-
return
|
|
1023
|
+
return x(w, E), y(w, [{ key: "componentDidMount", value: function() {
|
|
1023
1024
|
this._sigPad = new f.default(this._canvas, this._excludeOurProps()), this._resizeCanvas(), this.on();
|
|
1024
1025
|
} }, { key: "componentWillUnmount", value: function() {
|
|
1025
1026
|
this.off();
|
|
@@ -1027,26 +1028,26 @@ function it() {
|
|
|
1027
1028
|
Object.assign(this._sigPad, this._excludeOurProps());
|
|
1028
1029
|
} }, { key: "render", value: function() {
|
|
1029
1030
|
var B = this, F = this.props.canvasProps;
|
|
1030
|
-
return $.default.createElement("canvas", b({ ref: function(
|
|
1031
|
-
B._canvas =
|
|
1031
|
+
return $.default.createElement("canvas", b({ ref: function(_) {
|
|
1032
|
+
B._canvas = _;
|
|
1032
1033
|
} }, F));
|
|
1033
1034
|
} }]), w;
|
|
1034
1035
|
})(q.Component);
|
|
1035
|
-
|
|
1036
|
-
}, function(
|
|
1037
|
-
|
|
1038
|
-
}, function(
|
|
1039
|
-
|
|
1040
|
-
}, function(
|
|
1041
|
-
|
|
1042
|
-
}, function(
|
|
1043
|
-
|
|
1036
|
+
N.propTypes = { velocityFilterWeight: g.default.number, minWidth: g.default.number, maxWidth: g.default.number, minDistance: g.default.number, dotSize: g.default.oneOfType([g.default.number, g.default.func]), penColor: g.default.string, throttle: g.default.number, onEnd: g.default.func, onBegin: g.default.func, canvasProps: g.default.object, clearOnResize: g.default.bool }, N.defaultProps = { clearOnResize: !0 }, i.default = N;
|
|
1037
|
+
}, function(u, i) {
|
|
1038
|
+
u.exports = r;
|
|
1039
|
+
}, function(u, i) {
|
|
1040
|
+
u.exports = t;
|
|
1041
|
+
}, function(u, i) {
|
|
1042
|
+
u.exports = n;
|
|
1043
|
+
}, function(u, i) {
|
|
1044
|
+
u.exports = o;
|
|
1044
1045
|
}]);
|
|
1045
1046
|
});
|
|
1046
1047
|
})(le)), le.exports;
|
|
1047
1048
|
}
|
|
1048
1049
|
var st = it();
|
|
1049
|
-
const ut = /* @__PURE__ */
|
|
1050
|
+
const ut = /* @__PURE__ */ Be(st), ct = "_Signature_mhdg5_1", lt = "_SignatureMain_mhdg5_5", ft = "_SignatureMainAuto_mhdg5_15", dt = "_SignatureMainManual_mhdg5_19", ht = "_SignatureHeader_mhdg5_26", pt = "_SignatureHeaderReset_mhdg5_34", vt = "_SignatureManualPanel_mhdg5_41", yt = "_SignatureManualPanelPlaceholder_mhdg5_48", mt = "_SignatureManualPanelButton_mhdg5_52", gt = "_SignatureAutoPanelImage_mhdg5_67", _t = "_SignatureAutoPanelLoader_mhdg5_72", xt = "_SignatureAutoPanelNoteIcon_mhdg5_77", bt = "_SignatureAutoPanelButton_mhdg5_81", V = {
|
|
1050
1051
|
Signature: ct,
|
|
1051
1052
|
SignatureMain: lt,
|
|
1052
1053
|
SignatureMainAuto: ft,
|
|
@@ -1060,62 +1061,62 @@ const ut = /* @__PURE__ */ qe(st), ct = "_Signature_mhdg5_1", lt = "_SignatureMa
|
|
|
1060
1061
|
SignatureAutoPanelLoader: _t,
|
|
1061
1062
|
SignatureAutoPanelNoteIcon: xt,
|
|
1062
1063
|
SignatureAutoPanelButton: bt
|
|
1063
|
-
},
|
|
1064
|
-
const { modes: a, isInAutoMode: r, valueAuto: t, valueManual: n, onUpdateAuto: o, onUpdateManual:
|
|
1065
|
-
|
|
1066
|
-
width: +
|
|
1067
|
-
height: +
|
|
1064
|
+
}, kt = (e) => {
|
|
1065
|
+
const { modes: a, isInAutoMode: r, valueAuto: t, valueManual: n, onUpdateAuto: o, onUpdateManual: u, onChange: i, className: p = "" } = e, c = Fe(null), [l, v] = Se(null), [m, x] = Se("auto-generated"), { width: b = 0, height: y = 0 } = Ue({ ref: c, box: "border-box" }), C = r ? "auto-generated" : m === "manual-drawn" ? "manual-drawn" : n ? "manual-stored" : "manual-blank", g = re(() => {
|
|
1066
|
+
l && b && y && n && l.fromDataURL(n, {
|
|
1067
|
+
width: +b.toFixed(),
|
|
1068
|
+
height: +y.toFixed()
|
|
1068
1069
|
});
|
|
1069
|
-
}, [
|
|
1070
|
-
if (
|
|
1071
|
-
const
|
|
1072
|
-
|
|
1070
|
+
}, [l, b, y, n]), q = re(() => {
|
|
1071
|
+
if (l) {
|
|
1072
|
+
const E = l.getCanvas().toDataURL("image/png");
|
|
1073
|
+
x("manual-drawn"), u(E), i(E);
|
|
1073
1074
|
}
|
|
1074
|
-
}, [
|
|
1075
|
-
|
|
1076
|
-
}, [
|
|
1077
|
-
o(!0),
|
|
1078
|
-
}, [o, t, i]),
|
|
1079
|
-
o(!1),
|
|
1080
|
-
}, [o, n, i,
|
|
1081
|
-
o(!1),
|
|
1082
|
-
}, [o,
|
|
1083
|
-
|
|
1084
|
-
}, [
|
|
1075
|
+
}, [l, i, u]), $ = re(() => {
|
|
1076
|
+
l && (l.clear(), u(""), i(""));
|
|
1077
|
+
}, [l, i, u]), k = re(() => {
|
|
1078
|
+
o(!0), x("auto-generated"), t && i(t);
|
|
1079
|
+
}, [o, t, i]), f = re(() => {
|
|
1080
|
+
o(!1), x(n ? "manual-stored" : "manual-blank"), n ? (i(n), setTimeout(g, 0)) : i("");
|
|
1081
|
+
}, [o, n, i, g]), Z = re(() => {
|
|
1082
|
+
o(!1), x("manual-blank"), u(""), i("");
|
|
1083
|
+
}, [o, u, i]), te = re(() => {
|
|
1084
|
+
x("manual-stored"), g();
|
|
1085
|
+
}, [g]), N = (E) => E.includes(C);
|
|
1085
1086
|
return de(() => {
|
|
1086
1087
|
!a.includes("auto") && r && o(!1);
|
|
1087
1088
|
}, [a, r, o]), de(() => {
|
|
1088
|
-
!r && n &&
|
|
1089
|
-
}, [r, n,
|
|
1089
|
+
!r && n && b && y && g();
|
|
1090
|
+
}, [r, n, b, y, g]), de(() => {
|
|
1090
1091
|
r && t ? i(t) : !r && !n && i("");
|
|
1091
|
-
}, [r, t, n, i]), /* @__PURE__ */ Q("div", { className: V.Signature, children: [
|
|
1092
|
+
}, [r, t, n, i]), /* @__PURE__ */ Q("div", { className: Pe(V.Signature, p), children: [
|
|
1092
1093
|
/* @__PURE__ */ Q(
|
|
1093
1094
|
"div",
|
|
1094
1095
|
{
|
|
1095
|
-
className:
|
|
1096
|
+
className: Pe(
|
|
1096
1097
|
V.SignatureMain,
|
|
1097
1098
|
N(["auto-generated"]) ? V.SignatureMainAuto : V.SignatureMainManual
|
|
1098
1099
|
),
|
|
1099
|
-
ref:
|
|
1100
|
+
ref: c,
|
|
1100
1101
|
children: [
|
|
1101
1102
|
/* @__PURE__ */ Q(ie, { direction: "row", justify: N(["manual-drawn"]) ? "end" : "center", className: V.SignatureHeader, children: [
|
|
1102
|
-
/* @__PURE__ */ Q(
|
|
1103
|
+
/* @__PURE__ */ Q(we.Tag, { tag: "h6", weight: "medium", size: "regular", color: "primary", align: "center", children: [
|
|
1103
1104
|
/* @__PURE__ */ z(ee.FadeScale, { name: "generated-signature", condition: N(["auto-generated"]), children: "Wir haben eine digitale Signature Sie generiert." }),
|
|
1104
1105
|
/* @__PURE__ */ z(ee.FadeScale, { flex: !0, name: "create-signature", condition: N(["manual-blank", "manual-stored"]), children: "Ihre Signatur:" })
|
|
1105
1106
|
] }),
|
|
1106
|
-
/* @__PURE__ */ z(ee.FadeSlide, { flex: !0, name: "reset", direction: "rtl", condition: N(["manual-drawn"]), children: /* @__PURE__ */ z("div", { className: V.SignatureHeaderReset, children: /* @__PURE__ */ z(oe.ButtonText, { blurAfterClick: !0, underlined: !0, icon: /* @__PURE__ */ z(
|
|
1107
|
+
/* @__PURE__ */ z(ee.FadeSlide, { flex: !0, name: "reset", direction: "rtl", condition: N(["manual-drawn"]), children: /* @__PURE__ */ z("div", { className: V.SignatureHeaderReset, children: /* @__PURE__ */ z(oe.ButtonText, { blurAfterClick: !0, underlined: !0, icon: /* @__PURE__ */ z(Ne, {}), onClick: $, children: "Neu starten" }) }) })
|
|
1107
1108
|
] }),
|
|
1108
1109
|
/* @__PURE__ */ z(ie, { direction: "row", align: "end", justify: "center", children: N(["auto-generated"]) ? /* @__PURE__ */ Q(ie, { direction: "column", align: "center", justify: "start", children: [
|
|
1109
1110
|
/* @__PURE__ */ z(ee.FadeScale, { flex: !0, name: "signature", condition: t !== "", children: /* @__PURE__ */ z("img", { className: V.SignatureAutoPanelImage, src: t, alt: "signature" }) }),
|
|
1110
|
-
/* @__PURE__ */ z(ee.FadeScale, { flex: !0, name: "signature", condition: t === "", children: /* @__PURE__ */ z("div", { className: V.SignatureAutoPanelLoader, children: /* @__PURE__ */ z(
|
|
1111
|
+
/* @__PURE__ */ z(ee.FadeScale, { flex: !0, name: "signature", condition: t === "", children: /* @__PURE__ */ z("div", { className: V.SignatureAutoPanelLoader, children: /* @__PURE__ */ z(He, { size: "sm", color: "primary" }) }) }),
|
|
1111
1112
|
/* @__PURE__ */ Q(ie, { direction: "row", align: "center", justify: "center", gap: "xxs", mt: "xs", children: [
|
|
1112
1113
|
/* @__PURE__ */ z(Ye, { size: 24, className: V.SignatureAutoPanelNoteIcon }),
|
|
1113
|
-
/* @__PURE__ */ z(
|
|
1114
|
+
/* @__PURE__ */ z(we.Tag, { weight: "regular", size: "small", color: "secondary", children: "Diese Unterschrift ist ausreichend" })
|
|
1114
1115
|
] }),
|
|
1115
|
-
/* @__PURE__ */ z(ee.FadeScale, { flex: !0, name: "signature", condition: a.includes("manual"), children: /* @__PURE__ */ z("div", { className: V.SignatureAutoPanelButton, children: /* @__PURE__ */ z(oe.ButtonText, { blurAfterClick: !0, underlined: !0, onClick:
|
|
1116
|
+
/* @__PURE__ */ z(ee.FadeScale, { flex: !0, name: "signature", condition: a.includes("manual"), children: /* @__PURE__ */ z("div", { className: V.SignatureAutoPanelButton, children: /* @__PURE__ */ z(oe.ButtonText, { blurAfterClick: !0, underlined: !0, onClick: f, children: "per Hand/Maus unterschreiben" }) }) })
|
|
1116
1117
|
] }) : /* @__PURE__ */ Q("div", { className: V.SignatureManualPanel, children: [
|
|
1117
1118
|
/* @__PURE__ */ z("div", { className: V.SignatureManualPanelPlaceholder }),
|
|
1118
|
-
N(["manual-stored"]) ? /* @__PURE__ */ z("img", { width:
|
|
1119
|
+
N(["manual-stored"]) ? /* @__PURE__ */ z("img", { width: b, height: y, alt: "signature", src: n }) : /* @__PURE__ */ z(
|
|
1119
1120
|
ut,
|
|
1120
1121
|
{
|
|
1121
1122
|
penColor: "#262626",
|
|
@@ -1123,10 +1124,10 @@ const ut = /* @__PURE__ */ qe(st), ct = "_Signature_mhdg5_1", lt = "_SignatureMa
|
|
|
1123
1124
|
minWidth: 0.25,
|
|
1124
1125
|
maxWidth: 2.75,
|
|
1125
1126
|
throttle: 12,
|
|
1126
|
-
canvasProps: { width: +(
|
|
1127
|
-
ref: (
|
|
1127
|
+
canvasProps: { width: +(b || 0).toFixed(), height: +(y || 0).toFixed() },
|
|
1128
|
+
ref: (E) => v(E),
|
|
1128
1129
|
clearOnResize: !0,
|
|
1129
|
-
onEnd:
|
|
1130
|
+
onEnd: q
|
|
1130
1131
|
}
|
|
1131
1132
|
),
|
|
1132
1133
|
/* @__PURE__ */ z(
|
|
@@ -1135,7 +1136,7 @@ const ut = /* @__PURE__ */ qe(st), ct = "_Signature_mhdg5_1", lt = "_SignatureMa
|
|
|
1135
1136
|
name: "to-generated",
|
|
1136
1137
|
condition: N(["manual-stored"]),
|
|
1137
1138
|
className: V.SignatureManualPanelButton,
|
|
1138
|
-
children: /* @__PURE__ */ z(oe.ButtonText, { blurAfterClick: !0, underlined: !0, onClick:
|
|
1139
|
+
children: /* @__PURE__ */ z(oe.ButtonText, { blurAfterClick: !0, underlined: !0, onClick: Z, children: "Zurücksetzen" })
|
|
1139
1140
|
}
|
|
1140
1141
|
)
|
|
1141
1142
|
] }) })
|
|
@@ -1143,11 +1144,11 @@ const ut = /* @__PURE__ */ qe(st), ct = "_Signature_mhdg5_1", lt = "_SignatureMa
|
|
|
1143
1144
|
}
|
|
1144
1145
|
),
|
|
1145
1146
|
/* @__PURE__ */ z(ee.FadeScale, { name: "footer", condition: N(["manual-blank", "manual-drawn"]), children: /* @__PURE__ */ Q(ie, { direction: "row", align: "center", justify: "space-between", gap: "md", mt: "md", children: [
|
|
1146
|
-
a.includes("auto") ? /* @__PURE__ */ z(oe.Button, { fullWidth: !0, blurAfterClick: !0, color: "tertiary", onClick:
|
|
1147
|
-
/* @__PURE__ */ z(oe.Button, { fullWidth: !0, blurAfterClick: !0, color: "primary", disabled: !n, onClick:
|
|
1147
|
+
a.includes("auto") ? /* @__PURE__ */ z(oe.Button, { fullWidth: !0, blurAfterClick: !0, color: "tertiary", onClick: k, children: "Abbrechen" }) : null,
|
|
1148
|
+
/* @__PURE__ */ z(oe.Button, { fullWidth: !0, blurAfterClick: !0, color: "primary", disabled: !n, onClick: te, children: "Speichern" })
|
|
1148
1149
|
] }) })
|
|
1149
1150
|
] });
|
|
1150
1151
|
};
|
|
1151
1152
|
export {
|
|
1152
|
-
|
|
1153
|
+
kt as Signature
|
|
1153
1154
|
};
|