@arthurzakharov/ui-kit 1.8.2 → 1.8.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,11 +1,11 @@
1
- import { jsxs as te, jsx as V } from "react/jsx-runtime";
2
- import Ne, { useRef as fe, useState as oe, useCallback as re, useEffect as de } from "react";
3
- import { useResizeObserver as ze } from "usehooks-ts";
1
+ import { jsxs as Q, jsx as U } from "react/jsx-runtime";
2
+ import We, { useRef as ze, useState as oe, useCallback as ee, useEffect as xe } from "react";
3
+ import { useResizeObserver as Ne } from "usehooks-ts";
4
4
  import { RefreshCw as Fe, RotateCcw as qe, Check as Be } from "lucide-react";
5
- import he from "clsx";
6
- import { Button as we } from "../../controls/buttons/button/button.component.js";
5
+ import fe from "clsx";
6
+ import { Button as Pe } from "../../controls/buttons/button/button.component.js";
7
7
  import "../../controls/primitives/box/box.component.js";
8
- import { baseProps as Ee } from "../../utils/functions/functions.util.js";
8
+ import { baseProps as we } from "../../utils/functions/functions.util.js";
9
9
  import { ButtonText as ie } from "../../controls/buttons/button-text/button-text.component.js";
10
10
  import { Loader as Ue } from "../loader/loader.component.js";
11
11
  import '../../assets/signature-CYVRZH6h.css';function He(e) {
@@ -13,21 +13,21 @@ import '../../assets/signature-CYVRZH6h.css';function He(e) {
13
13
  }
14
14
  function Ye(e) {
15
15
  if (Object.prototype.hasOwnProperty.call(e, "__esModule")) return e;
16
- var n = e.default;
17
- if (typeof n == "function") {
16
+ var a = e.default;
17
+ if (typeof a == "function") {
18
18
  var r = function t() {
19
- var a = !1;
19
+ var n = !1;
20
20
  try {
21
- a = this instanceof t;
21
+ n = this instanceof t;
22
22
  } catch {
23
23
  }
24
- return a ? Reflect.construct(n, arguments, this.constructor) : n.apply(this, arguments);
24
+ return n ? Reflect.construct(a, arguments, this.constructor) : a.apply(this, arguments);
25
25
  };
26
- r.prototype = n.prototype;
26
+ r.prototype = a.prototype;
27
27
  } else r = {};
28
28
  return Object.defineProperty(r, "__esModule", { value: !0 }), Object.keys(e).forEach(function(t) {
29
- var a = Object.getOwnPropertyDescriptor(e, t);
30
- Object.defineProperty(r, t, a.get ? a : {
29
+ var n = Object.getOwnPropertyDescriptor(e, t);
30
+ Object.defineProperty(r, t, n.get ? n : {
31
31
  enumerable: !0,
32
32
  get: function() {
33
33
  return e[t];
@@ -36,539 +36,539 @@ function Ye(e) {
36
36
  }), r;
37
37
  }
38
38
  var ce = { exports: {} }, se = { exports: {} }, ue = { exports: {} }, I = {};
39
- var Te;
39
+ var Ee;
40
40
  function Ve() {
41
- if (Te) return I;
42
- Te = 1;
43
- var e = typeof Symbol == "function" && Symbol.for, n = e ? /* @__PURE__ */ Symbol.for("react.element") : 60103, r = e ? /* @__PURE__ */ Symbol.for("react.portal") : 60106, t = e ? /* @__PURE__ */ Symbol.for("react.fragment") : 60107, a = e ? /* @__PURE__ */ Symbol.for("react.strict_mode") : 60108, o = e ? /* @__PURE__ */ Symbol.for("react.profiler") : 60114, l = e ? /* @__PURE__ */ Symbol.for("react.provider") : 60109, c = e ? /* @__PURE__ */ Symbol.for("react.context") : 60110, d = e ? /* @__PURE__ */ Symbol.for("react.async_mode") : 60111, s = e ? /* @__PURE__ */ Symbol.for("react.concurrent_mode") : 60111, u = e ? /* @__PURE__ */ Symbol.for("react.forward_ref") : 60112, v = e ? /* @__PURE__ */ Symbol.for("react.suspense") : 60113, y = e ? /* @__PURE__ */ Symbol.for("react.suspense_list") : 60120, b = e ? /* @__PURE__ */ Symbol.for("react.memo") : 60115, x = e ? /* @__PURE__ */ Symbol.for("react.lazy") : 60116, g = e ? /* @__PURE__ */ Symbol.for("react.block") : 60121, T = e ? /* @__PURE__ */ Symbol.for("react.fundamental") : 60117, _ = e ? /* @__PURE__ */ Symbol.for("react.responder") : 60118, N = e ? /* @__PURE__ */ Symbol.for("react.scope") : 60119;
44
- function R(f) {
41
+ if (Ee) return I;
42
+ Ee = 1;
43
+ 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, i = e ? /* @__PURE__ */ Symbol.for("react.profiler") : 60114, c = e ? /* @__PURE__ */ Symbol.for("react.provider") : 60109, o = e ? /* @__PURE__ */ Symbol.for("react.context") : 60110, v = e ? /* @__PURE__ */ Symbol.for("react.async_mode") : 60111, u = e ? /* @__PURE__ */ Symbol.for("react.concurrent_mode") : 60111, l = e ? /* @__PURE__ */ Symbol.for("react.forward_ref") : 60112, d = e ? /* @__PURE__ */ Symbol.for("react.suspense") : 60113, m = e ? /* @__PURE__ */ Symbol.for("react.suspense_list") : 60120, b = e ? /* @__PURE__ */ Symbol.for("react.memo") : 60115, P = e ? /* @__PURE__ */ Symbol.for("react.lazy") : 60116, _ = e ? /* @__PURE__ */ Symbol.for("react.block") : 60121, x = e ? /* @__PURE__ */ Symbol.for("react.fundamental") : 60117, g = e ? /* @__PURE__ */ Symbol.for("react.responder") : 60118, F = e ? /* @__PURE__ */ Symbol.for("react.scope") : 60119;
44
+ function $(f) {
45
45
  if (typeof f == "object" && f !== null) {
46
- var G = f.$$typeof;
47
- switch (G) {
48
- case n:
46
+ var Z = f.$$typeof;
47
+ switch (Z) {
48
+ case a:
49
49
  switch (f = f.type, f) {
50
- case d:
51
- case s:
52
- case t:
53
- case o:
54
- case a:
55
50
  case v:
51
+ case u:
52
+ case t:
53
+ case i:
54
+ case n:
55
+ case d:
56
56
  return f;
57
57
  default:
58
58
  switch (f = f && f.$$typeof, f) {
59
- case c:
60
- case u:
61
- case x:
62
- case b:
59
+ case o:
63
60
  case l:
61
+ case P:
62
+ case b:
63
+ case c:
64
64
  return f;
65
65
  default:
66
- return G;
66
+ return Z;
67
67
  }
68
68
  }
69
69
  case r:
70
- return G;
70
+ return Z;
71
71
  }
72
72
  }
73
73
  }
74
- function j(f) {
75
- return R(f) === s;
74
+ function A(f) {
75
+ return $(f) === u;
76
76
  }
77
- return I.AsyncMode = d, I.ConcurrentMode = s, I.ContextConsumer = c, I.ContextProvider = l, I.Element = n, I.ForwardRef = u, I.Fragment = t, I.Lazy = x, I.Memo = b, I.Portal = r, I.Profiler = o, I.StrictMode = a, I.Suspense = v, I.isAsyncMode = function(f) {
78
- return j(f) || R(f) === d;
79
- }, I.isConcurrentMode = j, I.isContextConsumer = function(f) {
80
- return R(f) === c;
77
+ return I.AsyncMode = v, I.ConcurrentMode = u, I.ContextConsumer = o, I.ContextProvider = c, I.Element = a, I.ForwardRef = l, I.Fragment = t, I.Lazy = P, I.Memo = b, I.Portal = r, I.Profiler = i, I.StrictMode = n, I.Suspense = d, I.isAsyncMode = function(f) {
78
+ return A(f) || $(f) === v;
79
+ }, I.isConcurrentMode = A, I.isContextConsumer = function(f) {
80
+ return $(f) === o;
81
81
  }, I.isContextProvider = function(f) {
82
- return R(f) === l;
82
+ return $(f) === c;
83
83
  }, I.isElement = function(f) {
84
- return typeof f == "object" && f !== null && f.$$typeof === n;
84
+ return typeof f == "object" && f !== null && f.$$typeof === a;
85
85
  }, I.isForwardRef = function(f) {
86
- return R(f) === u;
86
+ return $(f) === l;
87
87
  }, I.isFragment = function(f) {
88
- return R(f) === t;
88
+ return $(f) === t;
89
89
  }, I.isLazy = function(f) {
90
- return R(f) === x;
90
+ return $(f) === P;
91
91
  }, I.isMemo = function(f) {
92
- return R(f) === b;
92
+ return $(f) === b;
93
93
  }, I.isPortal = function(f) {
94
- return R(f) === r;
94
+ return $(f) === r;
95
95
  }, I.isProfiler = function(f) {
96
- return R(f) === o;
96
+ return $(f) === i;
97
97
  }, I.isStrictMode = function(f) {
98
- return R(f) === a;
98
+ return $(f) === n;
99
99
  }, I.isSuspense = function(f) {
100
- return R(f) === v;
100
+ return $(f) === d;
101
101
  }, I.isValidElementType = function(f) {
102
- return typeof f == "string" || typeof f == "function" || f === t || f === s || f === o || f === a || f === v || f === y || typeof f == "object" && f !== null && (f.$$typeof === x || f.$$typeof === b || f.$$typeof === l || f.$$typeof === c || f.$$typeof === u || f.$$typeof === T || f.$$typeof === _ || f.$$typeof === N || f.$$typeof === g);
103
- }, I.typeOf = R, I;
102
+ return typeof f == "string" || typeof f == "function" || f === t || f === u || f === i || f === n || f === d || f === m || typeof f == "object" && f !== null && (f.$$typeof === P || f.$$typeof === b || f.$$typeof === c || f.$$typeof === o || f.$$typeof === l || f.$$typeof === x || f.$$typeof === g || f.$$typeof === F || f.$$typeof === _);
103
+ }, I.typeOf = $, I;
104
104
  }
105
105
  var L = {};
106
- var Se;
106
+ var Te;
107
107
  function Xe() {
108
- return Se || (Se = 1, process.env.NODE_ENV !== "production" && (function() {
109
- var e = typeof Symbol == "function" && Symbol.for, n = e ? /* @__PURE__ */ Symbol.for("react.element") : 60103, r = e ? /* @__PURE__ */ Symbol.for("react.portal") : 60106, t = e ? /* @__PURE__ */ Symbol.for("react.fragment") : 60107, a = e ? /* @__PURE__ */ Symbol.for("react.strict_mode") : 60108, o = e ? /* @__PURE__ */ Symbol.for("react.profiler") : 60114, l = e ? /* @__PURE__ */ Symbol.for("react.provider") : 60109, c = e ? /* @__PURE__ */ Symbol.for("react.context") : 60110, d = e ? /* @__PURE__ */ Symbol.for("react.async_mode") : 60111, s = e ? /* @__PURE__ */ Symbol.for("react.concurrent_mode") : 60111, u = e ? /* @__PURE__ */ Symbol.for("react.forward_ref") : 60112, v = e ? /* @__PURE__ */ Symbol.for("react.suspense") : 60113, y = e ? /* @__PURE__ */ Symbol.for("react.suspense_list") : 60120, b = e ? /* @__PURE__ */ Symbol.for("react.memo") : 60115, x = e ? /* @__PURE__ */ Symbol.for("react.lazy") : 60116, g = e ? /* @__PURE__ */ Symbol.for("react.block") : 60121, T = e ? /* @__PURE__ */ Symbol.for("react.fundamental") : 60117, _ = e ? /* @__PURE__ */ Symbol.for("react.responder") : 60118, N = e ? /* @__PURE__ */ Symbol.for("react.scope") : 60119;
110
- function R(p) {
108
+ return Te || (Te = 1, process.env.NODE_ENV !== "production" && (function() {
109
+ 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, i = e ? /* @__PURE__ */ Symbol.for("react.profiler") : 60114, c = e ? /* @__PURE__ */ Symbol.for("react.provider") : 60109, o = e ? /* @__PURE__ */ Symbol.for("react.context") : 60110, v = e ? /* @__PURE__ */ Symbol.for("react.async_mode") : 60111, u = e ? /* @__PURE__ */ Symbol.for("react.concurrent_mode") : 60111, l = e ? /* @__PURE__ */ Symbol.for("react.forward_ref") : 60112, d = e ? /* @__PURE__ */ Symbol.for("react.suspense") : 60113, m = e ? /* @__PURE__ */ Symbol.for("react.suspense_list") : 60120, b = e ? /* @__PURE__ */ Symbol.for("react.memo") : 60115, P = e ? /* @__PURE__ */ Symbol.for("react.lazy") : 60116, _ = e ? /* @__PURE__ */ Symbol.for("react.block") : 60121, x = e ? /* @__PURE__ */ Symbol.for("react.fundamental") : 60117, g = e ? /* @__PURE__ */ Symbol.for("react.responder") : 60118, F = e ? /* @__PURE__ */ Symbol.for("react.scope") : 60119;
110
+ function $(p) {
111
111
  return typeof p == "string" || typeof p == "function" || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.
112
- p === t || p === s || p === o || p === a || p === v || p === y || typeof p == "object" && p !== null && (p.$$typeof === x || p.$$typeof === b || p.$$typeof === l || p.$$typeof === c || p.$$typeof === u || p.$$typeof === T || p.$$typeof === _ || p.$$typeof === N || p.$$typeof === g);
112
+ p === t || p === u || p === i || p === n || p === d || p === m || typeof p == "object" && p !== null && (p.$$typeof === P || p.$$typeof === b || p.$$typeof === c || p.$$typeof === o || p.$$typeof === l || p.$$typeof === x || p.$$typeof === g || p.$$typeof === F || p.$$typeof === _);
113
113
  }
114
- function j(p) {
114
+ function A(p) {
115
115
  if (typeof p == "object" && p !== null) {
116
- var Z = p.$$typeof;
117
- switch (Z) {
118
- case n:
116
+ var G = p.$$typeof;
117
+ switch (G) {
118
+ case a:
119
119
  var ae = p.type;
120
120
  switch (ae) {
121
- case d:
122
- case s:
123
- case t:
124
- case o:
125
- case a:
126
121
  case v:
122
+ case u:
123
+ case t:
124
+ case i:
125
+ case n:
126
+ case d:
127
127
  return ae;
128
128
  default:
129
- var Pe = ae && ae.$$typeof;
130
- switch (Pe) {
131
- case c:
132
- case u:
133
- case x:
134
- case b:
129
+ var be = ae && ae.$$typeof;
130
+ switch (be) {
131
+ case o:
135
132
  case l:
136
- return Pe;
133
+ case P:
134
+ case b:
135
+ case c:
136
+ return be;
137
137
  default:
138
- return Z;
138
+ return G;
139
139
  }
140
140
  }
141
141
  case r:
142
- return Z;
142
+ return G;
143
143
  }
144
144
  }
145
145
  }
146
- var f = d, G = s, Q = c, K = l, A = n, P = u, q = t, F = x, m = b, H = r, ee = o, $ = a, Y = v, B = !1;
146
+ var f = v, Z = u, te = o, K = c, R = a, w = l, M = t, N = P, y = b, Y = r, ne = i, V = n, X = d, q = !1;
147
147
  function J(p) {
148
- return B || (B = !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.")), i(p) || j(p) === d;
148
+ return q || (q = !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(p) || A(p) === v;
149
149
  }
150
- function i(p) {
151
- return j(p) === s;
150
+ function s(p) {
151
+ return A(p) === u;
152
152
  }
153
153
  function h(p) {
154
- return j(p) === c;
154
+ return A(p) === o;
155
155
  }
156
- function w(p) {
157
- return j(p) === l;
156
+ function E(p) {
157
+ return A(p) === c;
158
158
  }
159
- function O(p) {
160
- return typeof p == "object" && p !== null && p.$$typeof === n;
159
+ function C(p) {
160
+ return typeof p == "object" && p !== null && p.$$typeof === a;
161
161
  }
162
- function E(p) {
163
- return j(p) === u;
162
+ function T(p) {
163
+ return A(p) === l;
164
164
  }
165
- function M(p) {
166
- return j(p) === t;
165
+ function D(p) {
166
+ return A(p) === t;
167
167
  }
168
168
  function S(p) {
169
- return j(p) === x;
169
+ return A(p) === P;
170
170
  }
171
- function C(p) {
172
- return j(p) === b;
171
+ function O(p) {
172
+ return A(p) === b;
173
173
  }
174
- function D(p) {
175
- return j(p) === r;
174
+ function k(p) {
175
+ return A(p) === r;
176
176
  }
177
177
  function W(p) {
178
- return j(p) === o;
178
+ return A(p) === i;
179
179
  }
180
- function k(p) {
181
- return j(p) === a;
180
+ function j(p) {
181
+ return A(p) === n;
182
182
  }
183
- function X(p) {
184
- return j(p) === v;
183
+ function H(p) {
184
+ return A(p) === d;
185
185
  }
186
- L.AsyncMode = f, L.ConcurrentMode = G, L.ContextConsumer = Q, L.ContextProvider = K, L.Element = A, L.ForwardRef = P, L.Fragment = q, L.Lazy = F, L.Memo = m, L.Portal = H, L.Profiler = ee, L.StrictMode = $, L.Suspense = Y, L.isAsyncMode = J, L.isConcurrentMode = i, L.isContextConsumer = h, L.isContextProvider = w, L.isElement = O, L.isForwardRef = E, L.isFragment = M, L.isLazy = S, L.isMemo = C, L.isPortal = D, L.isProfiler = W, L.isStrictMode = k, L.isSuspense = X, L.isValidElementType = R, L.typeOf = j;
186
+ L.AsyncMode = f, L.ConcurrentMode = Z, L.ContextConsumer = te, L.ContextProvider = K, L.Element = R, L.ForwardRef = w, L.Fragment = M, L.Lazy = N, L.Memo = y, L.Portal = Y, L.Profiler = ne, L.StrictMode = V, L.Suspense = X, L.isAsyncMode = J, L.isConcurrentMode = s, L.isContextConsumer = h, L.isContextProvider = E, L.isElement = C, L.isForwardRef = T, L.isFragment = D, L.isLazy = S, L.isMemo = O, L.isPortal = k, L.isProfiler = W, L.isStrictMode = j, L.isSuspense = H, L.isValidElementType = $, L.typeOf = A;
187
187
  })()), L;
188
188
  }
189
- var Oe;
190
- function $e() {
191
- return Oe || (Oe = 1, process.env.NODE_ENV === "production" ? ue.exports = Ve() : ue.exports = Xe()), ue.exports;
189
+ var Se;
190
+ function Le() {
191
+ return Se || (Se = 1, process.env.NODE_ENV === "production" ? ue.exports = Ve() : ue.exports = Xe()), ue.exports;
192
192
  }
193
- var pe, Ce;
193
+ var de, Ce;
194
194
  function Je() {
195
- if (Ce) return pe;
195
+ if (Ce) return de;
196
196
  Ce = 1;
197
- var e = Object.getOwnPropertySymbols, n = Object.prototype.hasOwnProperty, r = Object.prototype.propertyIsEnumerable;
198
- function t(o) {
199
- if (o == null)
197
+ var e = Object.getOwnPropertySymbols, a = Object.prototype.hasOwnProperty, r = Object.prototype.propertyIsEnumerable;
198
+ function t(i) {
199
+ if (i == null)
200
200
  throw new TypeError("Object.assign cannot be called with null or undefined");
201
- return Object(o);
201
+ return Object(i);
202
202
  }
203
- function a() {
203
+ function n() {
204
204
  try {
205
205
  if (!Object.assign)
206
206
  return !1;
207
- var o = new String("abc");
208
- if (o[5] = "de", Object.getOwnPropertyNames(o)[0] === "5")
207
+ var i = new String("abc");
208
+ if (i[5] = "de", Object.getOwnPropertyNames(i)[0] === "5")
209
209
  return !1;
210
- for (var l = {}, c = 0; c < 10; c++)
211
- l["_" + String.fromCharCode(c)] = c;
212
- var d = Object.getOwnPropertyNames(l).map(function(u) {
213
- return l[u];
210
+ for (var c = {}, o = 0; o < 10; o++)
211
+ c["_" + String.fromCharCode(o)] = o;
212
+ var v = Object.getOwnPropertyNames(c).map(function(l) {
213
+ return c[l];
214
214
  });
215
- if (d.join("") !== "0123456789")
215
+ if (v.join("") !== "0123456789")
216
216
  return !1;
217
- var s = {};
218
- return "abcdefghijklmnopqrst".split("").forEach(function(u) {
219
- s[u] = u;
220
- }), Object.keys(Object.assign({}, s)).join("") === "abcdefghijklmnopqrst";
217
+ var u = {};
218
+ return "abcdefghijklmnopqrst".split("").forEach(function(l) {
219
+ u[l] = l;
220
+ }), Object.keys(Object.assign({}, u)).join("") === "abcdefghijklmnopqrst";
221
221
  } catch {
222
222
  return !1;
223
223
  }
224
224
  }
225
- return pe = a() ? Object.assign : function(o, l) {
226
- for (var c, d = t(o), s, u = 1; u < arguments.length; u++) {
227
- c = Object(arguments[u]);
228
- for (var v in c)
229
- n.call(c, v) && (d[v] = c[v]);
225
+ return de = n() ? Object.assign : function(i, c) {
226
+ for (var o, v = t(i), u, l = 1; l < arguments.length; l++) {
227
+ o = Object(arguments[l]);
228
+ for (var d in o)
229
+ a.call(o, d) && (v[d] = o[d]);
230
230
  if (e) {
231
- s = e(c);
232
- for (var y = 0; y < s.length; y++)
233
- r.call(c, s[y]) && (d[s[y]] = c[s[y]]);
231
+ u = e(o);
232
+ for (var m = 0; m < u.length; m++)
233
+ r.call(o, u[m]) && (v[u[m]] = o[u[m]]);
234
234
  }
235
235
  }
236
- return d;
237
- }, pe;
236
+ return v;
237
+ }, de;
238
238
  }
239
- var ve, Re;
240
- function be() {
241
- if (Re) return ve;
242
- Re = 1;
239
+ var he, Oe;
240
+ function _e() {
241
+ if (Oe) return he;
242
+ Oe = 1;
243
243
  var e = "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";
244
- return ve = e, ve;
244
+ return he = e, he;
245
245
  }
246
- var ye, Ae;
247
- function We() {
248
- return Ae || (Ae = 1, ye = Function.call.bind(Object.prototype.hasOwnProperty)), ye;
246
+ var pe, Ae;
247
+ function $e() {
248
+ return Ae || (Ae = 1, pe = Function.call.bind(Object.prototype.hasOwnProperty)), pe;
249
249
  }
250
- var me, Me;
251
- function Ge() {
252
- if (Me) return me;
253
- Me = 1;
250
+ var ve, Re;
251
+ function Ze() {
252
+ if (Re) return ve;
253
+ Re = 1;
254
254
  var e = function() {
255
255
  };
256
256
  if (process.env.NODE_ENV !== "production") {
257
- var n = /* @__PURE__ */ be(), r = {}, t = /* @__PURE__ */ We();
258
- e = function(o) {
259
- var l = "Warning: " + o;
260
- typeof console < "u" && console.error(l);
257
+ var a = /* @__PURE__ */ _e(), r = {}, t = /* @__PURE__ */ $e();
258
+ e = function(i) {
259
+ var c = "Warning: " + i;
260
+ typeof console < "u" && console.error(c);
261
261
  try {
262
- throw new Error(l);
262
+ throw new Error(c);
263
263
  } catch {
264
264
  }
265
265
  };
266
266
  }
267
- function a(o, l, c, d, s) {
267
+ function n(i, c, o, v, u) {
268
268
  if (process.env.NODE_ENV !== "production") {
269
- for (var u in o)
270
- if (t(o, u)) {
271
- var v;
269
+ for (var l in i)
270
+ if (t(i, l)) {
271
+ var d;
272
272
  try {
273
- if (typeof o[u] != "function") {
274
- var y = Error(
275
- (d || "React class") + ": " + c + " type `" + u + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof o[u] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`."
273
+ if (typeof i[l] != "function") {
274
+ var m = Error(
275
+ (v || "React class") + ": " + o + " type `" + l + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof i[l] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`."
276
276
  );
277
- throw y.name = "Invariant Violation", y;
277
+ throw m.name = "Invariant Violation", m;
278
278
  }
279
- v = o[u](l, u, d, c, null, n);
280
- } catch (x) {
281
- v = x;
279
+ d = i[l](c, l, v, o, null, a);
280
+ } catch (P) {
281
+ d = P;
282
282
  }
283
- if (v && !(v instanceof Error) && e(
284
- (d || "React class") + ": type specification of " + c + " `" + u + "` 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)."
285
- ), v instanceof Error && !(v.message in r)) {
286
- r[v.message] = !0;
287
- var b = s ? s() : "";
283
+ if (d && !(d instanceof Error) && e(
284
+ (v || "React class") + ": type specification of " + o + " `" + l + "` is invalid; the type checker function must return `null` or an `Error` but returned a " + typeof d + ". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."
285
+ ), d instanceof Error && !(d.message in r)) {
286
+ r[d.message] = !0;
287
+ var b = u ? u() : "";
288
288
  e(
289
- "Failed " + c + " type: " + v.message + (b ?? "")
289
+ "Failed " + o + " type: " + d.message + (b ?? "")
290
290
  );
291
291
  }
292
292
  }
293
293
  }
294
294
  }
295
- return a.resetWarningCache = function() {
295
+ return n.resetWarningCache = function() {
296
296
  process.env.NODE_ENV !== "production" && (r = {});
297
- }, me = a, me;
297
+ }, ve = n, ve;
298
298
  }
299
- var _e, De;
300
- function Ze() {
301
- if (De) return _e;
302
- De = 1;
303
- var e = $e(), n = Je(), r = /* @__PURE__ */ be(), t = /* @__PURE__ */ We(), a = /* @__PURE__ */ Ge(), o = function() {
299
+ var ye, Me;
300
+ function Ge() {
301
+ if (Me) return ye;
302
+ Me = 1;
303
+ var e = Le(), a = Je(), r = /* @__PURE__ */ _e(), t = /* @__PURE__ */ $e(), n = /* @__PURE__ */ Ze(), i = function() {
304
304
  };
305
- process.env.NODE_ENV !== "production" && (o = function(c) {
306
- var d = "Warning: " + c;
307
- typeof console < "u" && console.error(d);
305
+ process.env.NODE_ENV !== "production" && (i = function(o) {
306
+ var v = "Warning: " + o;
307
+ typeof console < "u" && console.error(v);
308
308
  try {
309
- throw new Error(d);
309
+ throw new Error(v);
310
310
  } catch {
311
311
  }
312
312
  });
313
- function l() {
313
+ function c() {
314
314
  return null;
315
315
  }
316
- return _e = function(c, d) {
317
- var s = typeof Symbol == "function" && Symbol.iterator, u = "@@iterator";
318
- function v(i) {
319
- var h = i && (s && i[s] || i[u]);
316
+ return ye = function(o, v) {
317
+ var u = typeof Symbol == "function" && Symbol.iterator, l = "@@iterator";
318
+ function d(s) {
319
+ var h = s && (u && s[u] || s[l]);
320
320
  if (typeof h == "function")
321
321
  return h;
322
322
  }
323
- var y = "<<anonymous>>", b = {
324
- array: _("array"),
325
- bigint: _("bigint"),
326
- bool: _("boolean"),
327
- func: _("function"),
328
- number: _("number"),
329
- object: _("object"),
330
- string: _("string"),
331
- symbol: _("symbol"),
332
- any: N(),
333
- arrayOf: R,
334
- element: j(),
323
+ var m = "<<anonymous>>", b = {
324
+ array: g("array"),
325
+ bigint: g("bigint"),
326
+ bool: g("boolean"),
327
+ func: g("function"),
328
+ number: g("number"),
329
+ object: g("object"),
330
+ string: g("string"),
331
+ symbol: g("symbol"),
332
+ any: F(),
333
+ arrayOf: $,
334
+ element: A(),
335
335
  elementType: f(),
336
- instanceOf: G,
337
- node: P(),
336
+ instanceOf: Z,
337
+ node: w(),
338
338
  objectOf: K,
339
- oneOf: Q,
340
- oneOfType: A,
341
- shape: F,
342
- exact: m
339
+ oneOf: te,
340
+ oneOfType: R,
341
+ shape: N,
342
+ exact: y
343
343
  };
344
- function x(i, h) {
345
- return i === h ? i !== 0 || 1 / i === 1 / h : i !== i && h !== h;
344
+ function P(s, h) {
345
+ return s === h ? s !== 0 || 1 / s === 1 / h : s !== s && h !== h;
346
346
  }
347
- function g(i, h) {
348
- this.message = i, this.data = h && typeof h == "object" ? h : {}, this.stack = "";
347
+ function _(s, h) {
348
+ this.message = s, this.data = h && typeof h == "object" ? h : {}, this.stack = "";
349
349
  }
350
- g.prototype = Error.prototype;
351
- function T(i) {
350
+ _.prototype = Error.prototype;
351
+ function x(s) {
352
352
  if (process.env.NODE_ENV !== "production")
353
- var h = {}, w = 0;
354
- function O(M, S, C, D, W, k, X) {
355
- if (D = D || y, k = k || C, X !== r) {
356
- if (d) {
353
+ var h = {}, E = 0;
354
+ function C(D, S, O, k, W, j, H) {
355
+ if (k = k || m, j = j || O, H !== r) {
356
+ if (v) {
357
357
  var p = new Error(
358
358
  "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"
359
359
  );
360
360
  throw p.name = "Invariant Violation", p;
361
361
  } else if (process.env.NODE_ENV !== "production" && typeof console < "u") {
362
- var Z = D + ":" + C;
363
- !h[Z] && // Avoid spamming the console because they are often not actionable except for lib authors
364
- w < 3 && (o(
365
- "You are manually calling a React.PropTypes validation function for the `" + k + "` prop on `" + D + "`. 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."
366
- ), h[Z] = !0, w++);
362
+ var G = k + ":" + O;
363
+ !h[G] && // Avoid spamming the console because they are often not actionable except for lib authors
364
+ E < 3 && (i(
365
+ "You are manually calling a React.PropTypes validation function for the `" + j + "` prop on `" + k + "`. 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."
366
+ ), h[G] = !0, E++);
367
367
  }
368
368
  }
369
- return S[C] == null ? M ? S[C] === null ? new g("The " + W + " `" + k + "` is marked as required " + ("in `" + D + "`, but its value is `null`.")) : new g("The " + W + " `" + k + "` is marked as required in " + ("`" + D + "`, but its value is `undefined`.")) : null : i(S, C, D, W, k);
369
+ return S[O] == null ? D ? S[O] === null ? new _("The " + W + " `" + j + "` is marked as required " + ("in `" + k + "`, but its value is `null`.")) : new _("The " + W + " `" + j + "` is marked as required in " + ("`" + k + "`, but its value is `undefined`.")) : null : s(S, O, k, W, j);
370
370
  }
371
- var E = O.bind(null, !1);
372
- return E.isRequired = O.bind(null, !0), E;
371
+ var T = C.bind(null, !1);
372
+ return T.isRequired = C.bind(null, !0), T;
373
373
  }
374
- function _(i) {
375
- function h(w, O, E, M, S, C) {
376
- var D = w[O], W = $(D);
377
- if (W !== i) {
378
- var k = Y(D);
379
- return new g(
380
- "Invalid " + M + " `" + S + "` of type " + ("`" + k + "` supplied to `" + E + "`, expected ") + ("`" + i + "`."),
381
- { expectedType: i }
374
+ function g(s) {
375
+ function h(E, C, T, D, S, O) {
376
+ var k = E[C], W = V(k);
377
+ if (W !== s) {
378
+ var j = X(k);
379
+ return new _(
380
+ "Invalid " + D + " `" + S + "` of type " + ("`" + j + "` supplied to `" + T + "`, expected ") + ("`" + s + "`."),
381
+ { expectedType: s }
382
382
  );
383
383
  }
384
384
  return null;
385
385
  }
386
- return T(h);
386
+ return x(h);
387
387
  }
388
- function N() {
389
- return T(l);
388
+ function F() {
389
+ return x(c);
390
390
  }
391
- function R(i) {
392
- function h(w, O, E, M, S) {
393
- if (typeof i != "function")
394
- return new g("Property `" + S + "` of component `" + E + "` has invalid PropType notation inside arrayOf.");
395
- var C = w[O];
396
- if (!Array.isArray(C)) {
397
- var D = $(C);
398
- return new g("Invalid " + M + " `" + S + "` of type " + ("`" + D + "` supplied to `" + E + "`, expected an array."));
391
+ function $(s) {
392
+ function h(E, C, T, D, S) {
393
+ if (typeof s != "function")
394
+ return new _("Property `" + S + "` of component `" + T + "` has invalid PropType notation inside arrayOf.");
395
+ var O = E[C];
396
+ if (!Array.isArray(O)) {
397
+ var k = V(O);
398
+ return new _("Invalid " + D + " `" + S + "` of type " + ("`" + k + "` supplied to `" + T + "`, expected an array."));
399
399
  }
400
- for (var W = 0; W < C.length; W++) {
401
- var k = i(C, W, E, M, S + "[" + W + "]", r);
402
- if (k instanceof Error)
403
- return k;
400
+ for (var W = 0; W < O.length; W++) {
401
+ var j = s(O, W, T, D, S + "[" + W + "]", r);
402
+ if (j instanceof Error)
403
+ return j;
404
404
  }
405
405
  return null;
406
406
  }
407
- return T(h);
407
+ return x(h);
408
408
  }
409
- function j() {
410
- function i(h, w, O, E, M) {
411
- var S = h[w];
412
- if (!c(S)) {
413
- var C = $(S);
414
- return new g("Invalid " + E + " `" + M + "` of type " + ("`" + C + "` supplied to `" + O + "`, expected a single ReactElement."));
409
+ function A() {
410
+ function s(h, E, C, T, D) {
411
+ var S = h[E];
412
+ if (!o(S)) {
413
+ var O = V(S);
414
+ return new _("Invalid " + T + " `" + D + "` of type " + ("`" + O + "` supplied to `" + C + "`, expected a single ReactElement."));
415
415
  }
416
416
  return null;
417
417
  }
418
- return T(i);
418
+ return x(s);
419
419
  }
420
420
  function f() {
421
- function i(h, w, O, E, M) {
422
- var S = h[w];
421
+ function s(h, E, C, T, D) {
422
+ var S = h[E];
423
423
  if (!e.isValidElementType(S)) {
424
- var C = $(S);
425
- return new g("Invalid " + E + " `" + M + "` of type " + ("`" + C + "` supplied to `" + O + "`, expected a single ReactElement type."));
424
+ var O = V(S);
425
+ return new _("Invalid " + T + " `" + D + "` of type " + ("`" + O + "` supplied to `" + C + "`, expected a single ReactElement type."));
426
426
  }
427
427
  return null;
428
428
  }
429
- return T(i);
429
+ return x(s);
430
430
  }
431
- function G(i) {
432
- function h(w, O, E, M, S) {
433
- if (!(w[O] instanceof i)) {
434
- var C = i.name || y, D = J(w[O]);
435
- return new g("Invalid " + M + " `" + S + "` of type " + ("`" + D + "` supplied to `" + E + "`, expected ") + ("instance of `" + C + "`."));
431
+ function Z(s) {
432
+ function h(E, C, T, D, S) {
433
+ if (!(E[C] instanceof s)) {
434
+ var O = s.name || m, k = J(E[C]);
435
+ return new _("Invalid " + D + " `" + S + "` of type " + ("`" + k + "` supplied to `" + T + "`, expected ") + ("instance of `" + O + "`."));
436
436
  }
437
437
  return null;
438
438
  }
439
- return T(h);
439
+ return x(h);
440
440
  }
441
- function Q(i) {
442
- if (!Array.isArray(i))
443
- return process.env.NODE_ENV !== "production" && (arguments.length > 1 ? o(
441
+ function te(s) {
442
+ if (!Array.isArray(s))
443
+ return process.env.NODE_ENV !== "production" && (arguments.length > 1 ? i(
444
444
  "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])."
445
- ) : o("Invalid argument supplied to oneOf, expected an array.")), l;
446
- function h(w, O, E, M, S) {
447
- for (var C = w[O], D = 0; D < i.length; D++)
448
- if (x(C, i[D]))
445
+ ) : i("Invalid argument supplied to oneOf, expected an array.")), c;
446
+ function h(E, C, T, D, S) {
447
+ for (var O = E[C], k = 0; k < s.length; k++)
448
+ if (P(O, s[k]))
449
449
  return null;
450
- var W = JSON.stringify(i, function(X, p) {
451
- var Z = Y(p);
452
- return Z === "symbol" ? String(p) : p;
450
+ var W = JSON.stringify(s, function(H, p) {
451
+ var G = X(p);
452
+ return G === "symbol" ? String(p) : p;
453
453
  });
454
- return new g("Invalid " + M + " `" + S + "` of value `" + String(C) + "` " + ("supplied to `" + E + "`, expected one of " + W + "."));
454
+ return new _("Invalid " + D + " `" + S + "` of value `" + String(O) + "` " + ("supplied to `" + T + "`, expected one of " + W + "."));
455
455
  }
456
- return T(h);
456
+ return x(h);
457
457
  }
458
- function K(i) {
459
- function h(w, O, E, M, S) {
460
- if (typeof i != "function")
461
- return new g("Property `" + S + "` of component `" + E + "` has invalid PropType notation inside objectOf.");
462
- var C = w[O], D = $(C);
463
- if (D !== "object")
464
- return new g("Invalid " + M + " `" + S + "` of type " + ("`" + D + "` supplied to `" + E + "`, expected an object."));
465
- for (var W in C)
466
- if (t(C, W)) {
467
- var k = i(C, W, E, M, S + "." + W, r);
468
- if (k instanceof Error)
469
- return k;
458
+ function K(s) {
459
+ function h(E, C, T, D, S) {
460
+ if (typeof s != "function")
461
+ return new _("Property `" + S + "` of component `" + T + "` has invalid PropType notation inside objectOf.");
462
+ var O = E[C], k = V(O);
463
+ if (k !== "object")
464
+ return new _("Invalid " + D + " `" + S + "` of type " + ("`" + k + "` supplied to `" + T + "`, expected an object."));
465
+ for (var W in O)
466
+ if (t(O, W)) {
467
+ var j = s(O, W, T, D, S + "." + W, r);
468
+ if (j instanceof Error)
469
+ return j;
470
470
  }
471
471
  return null;
472
472
  }
473
- return T(h);
473
+ return x(h);
474
474
  }
475
- function A(i) {
476
- if (!Array.isArray(i))
477
- return process.env.NODE_ENV !== "production" && o("Invalid argument supplied to oneOfType, expected an instance of array."), l;
478
- for (var h = 0; h < i.length; h++) {
479
- var w = i[h];
480
- if (typeof w != "function")
481
- return o(
482
- "Invalid argument supplied to oneOfType. Expected an array of check functions, but received " + B(w) + " at index " + h + "."
483
- ), l;
475
+ function R(s) {
476
+ if (!Array.isArray(s))
477
+ return process.env.NODE_ENV !== "production" && i("Invalid argument supplied to oneOfType, expected an instance of array."), c;
478
+ for (var h = 0; h < s.length; h++) {
479
+ var E = s[h];
480
+ if (typeof E != "function")
481
+ return i(
482
+ "Invalid argument supplied to oneOfType. Expected an array of check functions, but received " + q(E) + " at index " + h + "."
483
+ ), c;
484
484
  }
485
- function O(E, M, S, C, D) {
486
- for (var W = [], k = 0; k < i.length; k++) {
487
- var X = i[k], p = X(E, M, S, C, D, r);
485
+ function C(T, D, S, O, k) {
486
+ for (var W = [], j = 0; j < s.length; j++) {
487
+ var H = s[j], p = H(T, D, S, O, k, r);
488
488
  if (p == null)
489
489
  return null;
490
490
  p.data && t(p.data, "expectedType") && W.push(p.data.expectedType);
491
491
  }
492
- var Z = W.length > 0 ? ", expected one of type [" + W.join(", ") + "]" : "";
493
- return new g("Invalid " + C + " `" + D + "` supplied to " + ("`" + S + "`" + Z + "."));
492
+ var G = W.length > 0 ? ", expected one of type [" + W.join(", ") + "]" : "";
493
+ return new _("Invalid " + O + " `" + k + "` supplied to " + ("`" + S + "`" + G + "."));
494
494
  }
495
- return T(O);
495
+ return x(C);
496
496
  }
497
- function P() {
498
- function i(h, w, O, E, M) {
499
- return H(h[w]) ? null : new g("Invalid " + E + " `" + M + "` supplied to " + ("`" + O + "`, expected a ReactNode."));
497
+ function w() {
498
+ function s(h, E, C, T, D) {
499
+ return Y(h[E]) ? null : new _("Invalid " + T + " `" + D + "` supplied to " + ("`" + C + "`, expected a ReactNode."));
500
500
  }
501
- return T(i);
501
+ return x(s);
502
502
  }
503
- function q(i, h, w, O, E) {
504
- return new g(
505
- (i || "React class") + ": " + h + " type `" + w + "." + O + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + E + "`."
503
+ function M(s, h, E, C, T) {
504
+ return new _(
505
+ (s || "React class") + ": " + h + " type `" + E + "." + C + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + T + "`."
506
506
  );
507
507
  }
508
- function F(i) {
509
- function h(w, O, E, M, S) {
510
- var C = w[O], D = $(C);
511
- if (D !== "object")
512
- return new g("Invalid " + M + " `" + S + "` of type `" + D + "` " + ("supplied to `" + E + "`, expected `object`."));
513
- for (var W in i) {
514
- var k = i[W];
515
- if (typeof k != "function")
516
- return q(E, M, S, W, Y(k));
517
- var X = k(C, W, E, M, S + "." + W, r);
518
- if (X)
519
- return X;
508
+ function N(s) {
509
+ function h(E, C, T, D, S) {
510
+ var O = E[C], k = V(O);
511
+ if (k !== "object")
512
+ return new _("Invalid " + D + " `" + S + "` of type `" + k + "` " + ("supplied to `" + T + "`, expected `object`."));
513
+ for (var W in s) {
514
+ var j = s[W];
515
+ if (typeof j != "function")
516
+ return M(T, D, S, W, X(j));
517
+ var H = j(O, W, T, D, S + "." + W, r);
518
+ if (H)
519
+ return H;
520
520
  }
521
521
  return null;
522
522
  }
523
- return T(h);
523
+ return x(h);
524
524
  }
525
- function m(i) {
526
- function h(w, O, E, M, S) {
527
- var C = w[O], D = $(C);
528
- if (D !== "object")
529
- return new g("Invalid " + M + " `" + S + "` of type `" + D + "` " + ("supplied to `" + E + "`, expected `object`."));
530
- var W = n({}, w[O], i);
531
- for (var k in W) {
532
- var X = i[k];
533
- if (t(i, k) && typeof X != "function")
534
- return q(E, M, S, k, Y(X));
535
- if (!X)
536
- return new g(
537
- "Invalid " + M + " `" + S + "` key `" + k + "` supplied to `" + E + "`.\nBad object: " + JSON.stringify(w[O], null, " ") + `
538
- Valid keys: ` + JSON.stringify(Object.keys(i), null, " ")
525
+ function y(s) {
526
+ function h(E, C, T, D, S) {
527
+ var O = E[C], k = V(O);
528
+ if (k !== "object")
529
+ return new _("Invalid " + D + " `" + S + "` of type `" + k + "` " + ("supplied to `" + T + "`, expected `object`."));
530
+ var W = a({}, E[C], s);
531
+ for (var j in W) {
532
+ var H = s[j];
533
+ if (t(s, j) && typeof H != "function")
534
+ return M(T, D, S, j, X(H));
535
+ if (!H)
536
+ return new _(
537
+ "Invalid " + D + " `" + S + "` key `" + j + "` supplied to `" + T + "`.\nBad object: " + JSON.stringify(E[C], null, " ") + `
538
+ Valid keys: ` + JSON.stringify(Object.keys(s), null, " ")
539
539
  );
540
- var p = X(C, k, E, M, S + "." + k, r);
540
+ var p = H(O, j, T, D, S + "." + j, r);
541
541
  if (p)
542
542
  return p;
543
543
  }
544
544
  return null;
545
545
  }
546
- return T(h);
546
+ return x(h);
547
547
  }
548
- function H(i) {
549
- switch (typeof i) {
548
+ function Y(s) {
549
+ switch (typeof s) {
550
550
  case "number":
551
551
  case "string":
552
552
  case "undefined":
553
553
  return !0;
554
554
  case "boolean":
555
- return !i;
555
+ return !s;
556
556
  case "object":
557
- if (Array.isArray(i))
558
- return i.every(H);
559
- if (i === null || c(i))
557
+ if (Array.isArray(s))
558
+ return s.every(Y);
559
+ if (s === null || o(s))
560
560
  return !0;
561
- var h = v(i);
561
+ var h = d(s);
562
562
  if (h) {
563
- var w = h.call(i), O;
564
- if (h !== i.entries) {
565
- for (; !(O = w.next()).done; )
566
- if (!H(O.value))
563
+ var E = h.call(s), C;
564
+ if (h !== s.entries) {
565
+ for (; !(C = E.next()).done; )
566
+ if (!Y(C.value))
567
567
  return !1;
568
568
  } else
569
- for (; !(O = w.next()).done; ) {
570
- var E = O.value;
571
- if (E && !H(E[1]))
569
+ for (; !(C = E.next()).done; ) {
570
+ var T = C.value;
571
+ if (T && !Y(T[1]))
572
572
  return !1;
573
573
  }
574
574
  } else
@@ -578,27 +578,27 @@ Valid keys: ` + JSON.stringify(Object.keys(i), null, " ")
578
578
  return !1;
579
579
  }
580
580
  }
581
- function ee(i, h) {
582
- return i === "symbol" ? !0 : h ? h["@@toStringTag"] === "Symbol" || typeof Symbol == "function" && h instanceof Symbol : !1;
581
+ function ne(s, h) {
582
+ return s === "symbol" ? !0 : h ? h["@@toStringTag"] === "Symbol" || typeof Symbol == "function" && h instanceof Symbol : !1;
583
583
  }
584
- function $(i) {
585
- var h = typeof i;
586
- return Array.isArray(i) ? "array" : i instanceof RegExp ? "object" : ee(h, i) ? "symbol" : h;
584
+ function V(s) {
585
+ var h = typeof s;
586
+ return Array.isArray(s) ? "array" : s instanceof RegExp ? "object" : ne(h, s) ? "symbol" : h;
587
587
  }
588
- function Y(i) {
589
- if (typeof i > "u" || i === null)
590
- return "" + i;
591
- var h = $(i);
588
+ function X(s) {
589
+ if (typeof s > "u" || s === null)
590
+ return "" + s;
591
+ var h = V(s);
592
592
  if (h === "object") {
593
- if (i instanceof Date)
593
+ if (s instanceof Date)
594
594
  return "date";
595
- if (i instanceof RegExp)
595
+ if (s instanceof RegExp)
596
596
  return "regexp";
597
597
  }
598
598
  return h;
599
599
  }
600
- function B(i) {
601
- var h = Y(i);
600
+ function q(s) {
601
+ var h = X(s);
602
602
  switch (h) {
603
603
  case "array":
604
604
  case "object":
@@ -611,35 +611,35 @@ Valid keys: ` + JSON.stringify(Object.keys(i), null, " ")
611
611
  return h;
612
612
  }
613
613
  }
614
- function J(i) {
615
- return !i.constructor || !i.constructor.name ? y : i.constructor.name;
614
+ function J(s) {
615
+ return !s.constructor || !s.constructor.name ? m : s.constructor.name;
616
616
  }
617
- return b.checkPropTypes = a, b.resetWarningCache = a.resetWarningCache, b.PropTypes = b, b;
618
- }, _e;
617
+ return b.checkPropTypes = n, b.resetWarningCache = n.resetWarningCache, b.PropTypes = b, b;
618
+ }, ye;
619
619
  }
620
- var ge, ke;
620
+ var me, De;
621
621
  function Ke() {
622
- if (ke) return ge;
623
- ke = 1;
624
- var e = /* @__PURE__ */ be();
625
- function n() {
622
+ if (De) return me;
623
+ De = 1;
624
+ var e = /* @__PURE__ */ _e();
625
+ function a() {
626
626
  }
627
627
  function r() {
628
628
  }
629
- return r.resetWarningCache = n, ge = function() {
630
- function t(l, c, d, s, u, v) {
631
- if (v !== e) {
632
- var y = new Error(
629
+ return r.resetWarningCache = a, me = function() {
630
+ function t(c, o, v, u, l, d) {
631
+ if (d !== e) {
632
+ var m = new Error(
633
633
  "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"
634
634
  );
635
- throw y.name = "Invariant Violation", y;
635
+ throw m.name = "Invariant Violation", m;
636
636
  }
637
637
  }
638
638
  t.isRequired = t;
639
- function a() {
639
+ function n() {
640
640
  return t;
641
641
  }
642
- var o = {
642
+ var i = {
643
643
  array: t,
644
644
  bigint: t,
645
645
  bool: t,
@@ -649,117 +649,117 @@ function Ke() {
649
649
  string: t,
650
650
  symbol: t,
651
651
  any: t,
652
- arrayOf: a,
652
+ arrayOf: n,
653
653
  element: t,
654
654
  elementType: t,
655
- instanceOf: a,
655
+ instanceOf: n,
656
656
  node: t,
657
- objectOf: a,
658
- oneOf: a,
659
- oneOfType: a,
660
- shape: a,
661
- exact: a,
657
+ objectOf: n,
658
+ oneOf: n,
659
+ oneOfType: n,
660
+ shape: n,
661
+ exact: n,
662
662
  checkPropTypes: r,
663
- resetWarningCache: n
663
+ resetWarningCache: a
664
664
  };
665
- return o.PropTypes = o, o;
666
- }, ge;
665
+ return i.PropTypes = i, i;
666
+ }, me;
667
667
  }
668
- var je;
668
+ var ke;
669
669
  function Qe() {
670
- if (je) return se.exports;
671
- if (je = 1, process.env.NODE_ENV !== "production") {
672
- var e = $e(), n = !0;
673
- se.exports = /* @__PURE__ */ Ze()(e.isElement, n);
670
+ if (ke) return se.exports;
671
+ if (ke = 1, process.env.NODE_ENV !== "production") {
672
+ var e = Le(), a = !0;
673
+ se.exports = /* @__PURE__ */ Ge()(e.isElement, a);
674
674
  } else
675
675
  se.exports = /* @__PURE__ */ Ke()();
676
676
  return se.exports;
677
677
  }
678
- function ne(e, n, r) {
679
- this.x = e, this.y = n, this.time = r || (/* @__PURE__ */ new Date()).getTime();
678
+ function re(e, a, r) {
679
+ this.x = e, this.y = a, this.time = r || (/* @__PURE__ */ new Date()).getTime();
680
680
  }
681
- ne.prototype.velocityFrom = function(e) {
681
+ re.prototype.velocityFrom = function(e) {
682
682
  return this.time !== e.time ? this.distanceTo(e) / (this.time - e.time) : 1;
683
683
  };
684
- ne.prototype.distanceTo = function(e) {
684
+ re.prototype.distanceTo = function(e) {
685
685
  return Math.sqrt(Math.pow(this.x - e.x, 2) + Math.pow(this.y - e.y, 2));
686
686
  };
687
- ne.prototype.equals = function(e) {
687
+ re.prototype.equals = function(e) {
688
688
  return this.x === e.x && this.y === e.y && this.time === e.time;
689
689
  };
690
- function xe(e, n, r, t) {
691
- this.startPoint = e, this.control1 = n, this.control2 = r, this.endPoint = t;
690
+ function ge(e, a, r, t) {
691
+ this.startPoint = e, this.control1 = a, this.control2 = r, this.endPoint = t;
692
692
  }
693
- xe.prototype.length = function() {
694
- for (var e = 10, n = 0, r = void 0, t = void 0, a = 0; a <= e; a += 1) {
695
- var o = a / e, l = this._point(o, this.startPoint.x, this.control1.x, this.control2.x, this.endPoint.x), c = this._point(o, this.startPoint.y, this.control1.y, this.control2.y, this.endPoint.y);
696
- if (a > 0) {
697
- var d = l - r, s = c - t;
698
- n += Math.sqrt(d * d + s * s);
693
+ ge.prototype.length = function() {
694
+ for (var e = 10, a = 0, r = void 0, t = void 0, n = 0; n <= e; n += 1) {
695
+ var i = n / e, c = this._point(i, this.startPoint.x, this.control1.x, this.control2.x, this.endPoint.x), o = this._point(i, this.startPoint.y, this.control1.y, this.control2.y, this.endPoint.y);
696
+ if (n > 0) {
697
+ var v = c - r, u = o - t;
698
+ a += Math.sqrt(v * v + u * u);
699
699
  }
700
- r = l, t = c;
700
+ r = c, t = o;
701
701
  }
702
- return n;
702
+ return a;
703
703
  };
704
- xe.prototype._point = function(e, n, r, t, a) {
705
- return n * (1 - e) * (1 - e) * (1 - e) + 3 * r * (1 - e) * (1 - e) * e + 3 * t * (1 - e) * e * e + a * e * e * e;
704
+ ge.prototype._point = function(e, a, r, t, n) {
705
+ 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;
706
706
  };
707
- function et(e, n, r) {
708
- var t, a, o, l = null, c = 0;
707
+ function et(e, a, r) {
708
+ var t, n, i, c = null, o = 0;
709
709
  r || (r = {});
710
- var d = function() {
711
- c = r.leading === !1 ? 0 : Date.now(), l = null, o = e.apply(t, a), l || (t = a = null);
710
+ var v = function() {
711
+ o = r.leading === !1 ? 0 : Date.now(), c = null, i = e.apply(t, n), c || (t = n = null);
712
712
  };
713
713
  return function() {
714
- var s = Date.now();
715
- !c && r.leading === !1 && (c = s);
716
- var u = n - (s - c);
717
- return t = this, a = arguments, u <= 0 || u > n ? (l && (clearTimeout(l), l = null), c = s, o = e.apply(t, a), l || (t = a = null)) : !l && r.trailing !== !1 && (l = setTimeout(d, u)), o;
714
+ var u = Date.now();
715
+ !o && r.leading === !1 && (o = u);
716
+ var l = a - (u - o);
717
+ return t = this, n = arguments, l <= 0 || l > a ? (c && (clearTimeout(c), c = null), o = u, i = e.apply(t, n), c || (t = n = null)) : !c && r.trailing !== !1 && (c = setTimeout(v, l)), i;
718
718
  };
719
719
  }
720
- function z(e, n) {
721
- var r = this, t = n || {};
720
+ function z(e, a) {
721
+ var r = this, t = a || {};
722
722
  this.velocityFilterWeight = t.velocityFilterWeight || 0.7, this.minWidth = t.minWidth || 0.5, this.maxWidth = t.maxWidth || 2.5, this.throttle = "throttle" in t ? t.throttle : 16, this.minDistance = "minDistance" in t ? t.minDistance : 5, this.throttle ? this._strokeMoveUpdate = et(z.prototype._strokeUpdate, this.throttle) : this._strokeMoveUpdate = z.prototype._strokeUpdate, this.dotSize = t.dotSize || function() {
723
723
  return (this.minWidth + this.maxWidth) / 2;
724
- }, this.penColor = t.penColor || "black", this.backgroundColor = t.backgroundColor || "rgba(0,0,0,0)", this.onBegin = t.onBegin, this.onEnd = t.onEnd, this._canvas = e, this._ctx = e.getContext("2d"), this.clear(), this._handleMouseDown = function(a) {
725
- a.which === 1 && (r._mouseButtonDown = !0, r._strokeBegin(a));
726
- }, this._handleMouseMove = function(a) {
727
- r._mouseButtonDown && r._strokeMoveUpdate(a);
728
- }, this._handleMouseUp = function(a) {
729
- a.which === 1 && r._mouseButtonDown && (r._mouseButtonDown = !1, r._strokeEnd(a));
730
- }, this._handleTouchStart = function(a) {
731
- if (a.targetTouches.length === 1) {
732
- var o = a.changedTouches[0];
733
- r._strokeBegin(o);
724
+ }, this.penColor = t.penColor || "black", this.backgroundColor = t.backgroundColor || "rgba(0,0,0,0)", this.onBegin = t.onBegin, this.onEnd = t.onEnd, this._canvas = e, this._ctx = e.getContext("2d"), this.clear(), this._handleMouseDown = function(n) {
725
+ n.which === 1 && (r._mouseButtonDown = !0, r._strokeBegin(n));
726
+ }, this._handleMouseMove = function(n) {
727
+ r._mouseButtonDown && r._strokeMoveUpdate(n);
728
+ }, this._handleMouseUp = function(n) {
729
+ n.which === 1 && r._mouseButtonDown && (r._mouseButtonDown = !1, r._strokeEnd(n));
730
+ }, this._handleTouchStart = function(n) {
731
+ if (n.targetTouches.length === 1) {
732
+ var i = n.changedTouches[0];
733
+ r._strokeBegin(i);
734
734
  }
735
- }, this._handleTouchMove = function(a) {
736
- a.preventDefault();
737
- var o = a.targetTouches[0];
738
- r._strokeMoveUpdate(o);
739
- }, this._handleTouchEnd = function(a) {
740
- var o = a.target === r._canvas;
741
- o && (a.preventDefault(), r._strokeEnd(a));
735
+ }, this._handleTouchMove = function(n) {
736
+ n.preventDefault();
737
+ var i = n.targetTouches[0];
738
+ r._strokeMoveUpdate(i);
739
+ }, this._handleTouchEnd = function(n) {
740
+ var i = n.target === r._canvas;
741
+ i && (n.preventDefault(), r._strokeEnd(n));
742
742
  }, this.on();
743
743
  }
744
744
  z.prototype.clear = function() {
745
- var e = this._ctx, n = this._canvas;
746
- e.fillStyle = this.backgroundColor, e.clearRect(0, 0, n.width, n.height), e.fillRect(0, 0, n.width, n.height), this._data = [], this._reset(), this._isEmpty = !0;
745
+ var e = this._ctx, a = this._canvas;
746
+ 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;
747
747
  };
748
748
  z.prototype.fromDataURL = function(e) {
749
- var n = this, r = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, t = new Image(), a = r.ratio || window.devicePixelRatio || 1, o = r.width || this._canvas.width / a, l = r.height || this._canvas.height / a;
749
+ var a = this, r = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, t = new Image(), n = r.ratio || window.devicePixelRatio || 1, i = r.width || this._canvas.width / n, c = r.height || this._canvas.height / n;
750
750
  this._reset(), t.src = e, t.onload = function() {
751
- n._ctx.drawImage(t, 0, 0, o, l);
751
+ a._ctx.drawImage(t, 0, 0, i, c);
752
752
  }, this._isEmpty = !1;
753
753
  };
754
754
  z.prototype.toDataURL = function(e) {
755
- var n;
755
+ var a;
756
756
  switch (e) {
757
757
  case "image/svg+xml":
758
758
  return this._toSVG();
759
759
  default:
760
- for (var r = arguments.length, t = Array(r > 1 ? r - 1 : 0), a = 1; a < r; a++)
761
- t[a - 1] = arguments[a];
762
- return (n = this._canvas).toDataURL.apply(n, [e].concat(t));
760
+ for (var r = arguments.length, t = Array(r > 1 ? r - 1 : 0), n = 1; n < r; n++)
761
+ t[n - 1] = arguments[n];
762
+ return (a = this._canvas).toDataURL.apply(a, [e].concat(t));
763
763
  }
764
764
  };
765
765
  z.prototype.on = function() {
@@ -775,10 +775,10 @@ z.prototype._strokeBegin = function(e) {
775
775
  this._data.push([]), this._reset(), this._strokeUpdate(e), typeof this.onBegin == "function" && this.onBegin(e);
776
776
  };
777
777
  z.prototype._strokeUpdate = function(e) {
778
- var n = e.clientX, r = e.clientY, t = this._createPoint(n, r), a = this._data[this._data.length - 1], o = a && a[a.length - 1], l = o && t.distanceTo(o) < this.minDistance;
779
- if (!(o && l)) {
780
- var c = this._addPoint(t), d = c.curve, s = c.widths;
781
- d && s && this._drawCurve(d, s.start, s.end), this._data[this._data.length - 1].push({
778
+ var a = e.clientX, r = e.clientY, t = this._createPoint(a, r), n = this._data[this._data.length - 1], i = n && n[n.length - 1], c = i && t.distanceTo(i) < this.minDistance;
779
+ if (!(i && c)) {
780
+ var o = this._addPoint(t), v = o.curve, u = o.widths;
781
+ v && u && this._drawCurve(v, u.start, u.end), this._data[this._data.length - 1].push({
782
782
  x: t.x,
783
783
  y: t.y,
784
784
  time: t.time,
@@ -787,10 +787,10 @@ z.prototype._strokeUpdate = function(e) {
787
787
  }
788
788
  };
789
789
  z.prototype._strokeEnd = function(e) {
790
- var n = this.points.length > 2, r = this.points[0];
791
- if (!n && r && this._drawDot(r), r) {
792
- var t = this._data[this._data.length - 1], a = t[t.length - 1];
793
- r.equals(a) || t.push({
790
+ var a = this.points.length > 2, r = this.points[0];
791
+ if (!a && r && this._drawDot(r), r) {
792
+ var t = this._data[this._data.length - 1], n = t[t.length - 1];
793
+ r.equals(n) || t.push({
794
794
  x: r.x,
795
795
  y: r.y,
796
796
  time: r.time,
@@ -808,105 +808,105 @@ z.prototype._handleTouchEvents = function() {
808
808
  z.prototype._reset = function() {
809
809
  this.points = [], this._lastVelocity = 0, this._lastWidth = (this.minWidth + this.maxWidth) / 2, this._ctx.fillStyle = this.penColor;
810
810
  };
811
- z.prototype._createPoint = function(e, n, r) {
811
+ z.prototype._createPoint = function(e, a, r) {
812
812
  var t = this._canvas.getBoundingClientRect();
813
- return new ne(e - t.left, n - t.top, r || (/* @__PURE__ */ new Date()).getTime());
813
+ return new re(e - t.left, a - t.top, r || (/* @__PURE__ */ new Date()).getTime());
814
814
  };
815
815
  z.prototype._addPoint = function(e) {
816
- var n = this.points, r = void 0;
817
- if (n.push(e), n.length > 2) {
818
- n.length === 3 && n.unshift(n[0]), r = this._calculateCurveControlPoints(n[0], n[1], n[2]);
816
+ var a = this.points, r = void 0;
817
+ if (a.push(e), a.length > 2) {
818
+ a.length === 3 && a.unshift(a[0]), r = this._calculateCurveControlPoints(a[0], a[1], a[2]);
819
819
  var t = r.c2;
820
- r = this._calculateCurveControlPoints(n[1], n[2], n[3]);
821
- var a = r.c1, o = new xe(n[1], t, a, n[2]), l = this._calculateCurveWidths(o);
822
- return n.shift(), { curve: o, widths: l };
820
+ r = this._calculateCurveControlPoints(a[1], a[2], a[3]);
821
+ var n = r.c1, i = new ge(a[1], t, n, a[2]), c = this._calculateCurveWidths(i);
822
+ return a.shift(), { curve: i, widths: c };
823
823
  }
824
824
  return {};
825
825
  };
826
- z.prototype._calculateCurveControlPoints = function(e, n, r) {
827
- var t = e.x - n.x, a = e.y - n.y, o = n.x - r.x, l = n.y - r.y, c = { x: (e.x + n.x) / 2, y: (e.y + n.y) / 2 }, d = { x: (n.x + r.x) / 2, y: (n.y + r.y) / 2 }, s = Math.sqrt(t * t + a * a), u = Math.sqrt(o * o + l * l), v = c.x - d.x, y = c.y - d.y, b = u / (s + u), x = { x: d.x + v * b, y: d.y + y * b }, g = n.x - x.x, T = n.y - x.y;
826
+ z.prototype._calculateCurveControlPoints = function(e, a, r) {
827
+ var t = e.x - a.x, n = e.y - a.y, i = a.x - r.x, c = a.y - r.y, o = { x: (e.x + a.x) / 2, y: (e.y + a.y) / 2 }, v = { x: (a.x + r.x) / 2, y: (a.y + r.y) / 2 }, u = Math.sqrt(t * t + n * n), l = Math.sqrt(i * i + c * c), d = o.x - v.x, m = o.y - v.y, b = l / (u + l), P = { x: v.x + d * b, y: v.y + m * b }, _ = a.x - P.x, x = a.y - P.y;
828
828
  return {
829
- c1: new ne(c.x + g, c.y + T),
830
- c2: new ne(d.x + g, d.y + T)
829
+ c1: new re(o.x + _, o.y + x),
830
+ c2: new re(v.x + _, v.y + x)
831
831
  };
832
832
  };
833
833
  z.prototype._calculateCurveWidths = function(e) {
834
- var n = e.startPoint, r = e.endPoint, t = { start: null, end: null }, a = this.velocityFilterWeight * r.velocityFrom(n) + (1 - this.velocityFilterWeight) * this._lastVelocity, o = this._strokeWidth(a);
835
- return t.start = this._lastWidth, t.end = o, this._lastVelocity = a, this._lastWidth = o, t;
834
+ var a = e.startPoint, r = e.endPoint, t = { start: null, end: null }, n = this.velocityFilterWeight * r.velocityFrom(a) + (1 - this.velocityFilterWeight) * this._lastVelocity, i = this._strokeWidth(n);
835
+ return t.start = this._lastWidth, t.end = i, this._lastVelocity = n, this._lastWidth = i, t;
836
836
  };
837
837
  z.prototype._strokeWidth = function(e) {
838
838
  return Math.max(this.maxWidth / (e + 1), this.minWidth);
839
839
  };
840
- z.prototype._drawPoint = function(e, n, r) {
840
+ z.prototype._drawPoint = function(e, a, r) {
841
841
  var t = this._ctx;
842
- t.moveTo(e, n), t.arc(e, n, r, 0, 2 * Math.PI, !1), this._isEmpty = !1;
842
+ t.moveTo(e, a), t.arc(e, a, r, 0, 2 * Math.PI, !1), this._isEmpty = !1;
843
843
  };
844
- z.prototype._drawCurve = function(e, n, r) {
845
- var t = this._ctx, a = r - n, o = Math.floor(e.length());
844
+ z.prototype._drawCurve = function(e, a, r) {
845
+ var t = this._ctx, n = r - a, i = Math.floor(e.length());
846
846
  t.beginPath();
847
- for (var l = 0; l < o; l += 1) {
848
- var c = l / o, d = c * c, s = d * c, u = 1 - c, v = u * u, y = v * u, b = y * e.startPoint.x;
849
- b += 3 * v * c * e.control1.x, b += 3 * u * d * e.control2.x, b += s * e.endPoint.x;
850
- var x = y * e.startPoint.y;
851
- x += 3 * v * c * e.control1.y, x += 3 * u * d * e.control2.y, x += s * e.endPoint.y;
852
- var g = n + s * a;
853
- this._drawPoint(b, x, g);
847
+ for (var c = 0; c < i; c += 1) {
848
+ var o = c / i, v = o * o, u = v * o, l = 1 - o, d = l * l, m = d * l, b = m * e.startPoint.x;
849
+ b += 3 * d * o * e.control1.x, b += 3 * l * v * e.control2.x, b += u * e.endPoint.x;
850
+ var P = m * e.startPoint.y;
851
+ P += 3 * d * o * e.control1.y, P += 3 * l * v * e.control2.y, P += u * e.endPoint.y;
852
+ var _ = a + u * n;
853
+ this._drawPoint(b, P, _);
854
854
  }
855
855
  t.closePath(), t.fill();
856
856
  };
857
857
  z.prototype._drawDot = function(e) {
858
- var n = this._ctx, r = typeof this.dotSize == "function" ? this.dotSize() : this.dotSize;
859
- n.beginPath(), this._drawPoint(e.x, e.y, r), n.closePath(), n.fill();
858
+ var a = this._ctx, r = typeof this.dotSize == "function" ? this.dotSize() : this.dotSize;
859
+ a.beginPath(), this._drawPoint(e.x, e.y, r), a.closePath(), a.fill();
860
860
  };
861
- z.prototype._fromData = function(e, n, r) {
861
+ z.prototype._fromData = function(e, a, r) {
862
862
  for (var t = 0; t < e.length; t += 1) {
863
- var a = e[t];
864
- if (a.length > 1)
865
- for (var o = 0; o < a.length; o += 1) {
866
- var l = a[o], c = new ne(l.x, l.y, l.time), d = l.color;
867
- if (o === 0)
868
- this.penColor = d, this._reset(), this._addPoint(c);
869
- else if (o !== a.length - 1) {
870
- var s = this._addPoint(c), u = s.curve, v = s.widths;
871
- u && v && n(u, v, d);
863
+ var n = e[t];
864
+ if (n.length > 1)
865
+ for (var i = 0; i < n.length; i += 1) {
866
+ var c = n[i], o = new re(c.x, c.y, c.time), v = c.color;
867
+ if (i === 0)
868
+ this.penColor = v, this._reset(), this._addPoint(o);
869
+ else if (i !== n.length - 1) {
870
+ var u = this._addPoint(o), l = u.curve, d = u.widths;
871
+ l && d && a(l, d, v);
872
872
  }
873
873
  }
874
874
  else {
875
875
  this._reset();
876
- var y = a[0];
877
- r(y);
876
+ var m = n[0];
877
+ r(m);
878
878
  }
879
879
  }
880
880
  };
881
881
  z.prototype._toSVG = function() {
882
- var e = this, n = this._data, r = this._canvas, t = Math.max(window.devicePixelRatio || 1, 1), a = 0, o = 0, l = r.width / t, c = r.height / t, d = document.createElementNS("http://www.w3.org/2000/svg", "svg");
883
- d.setAttributeNS(null, "width", r.width), d.setAttributeNS(null, "height", r.height), this._fromData(n, function(_, N, R) {
884
- var j = document.createElement("path");
885
- if (!isNaN(_.control1.x) && !isNaN(_.control1.y) && !isNaN(_.control2.x) && !isNaN(_.control2.y)) {
886
- var f = "M " + _.startPoint.x.toFixed(3) + "," + _.startPoint.y.toFixed(3) + " " + ("C " + _.control1.x.toFixed(3) + "," + _.control1.y.toFixed(3) + " ") + (_.control2.x.toFixed(3) + "," + _.control2.y.toFixed(3) + " ") + (_.endPoint.x.toFixed(3) + "," + _.endPoint.y.toFixed(3));
887
- j.setAttribute("d", f), j.setAttribute("stroke-width", (N.end * 2.25).toFixed(3)), j.setAttribute("stroke", R), j.setAttribute("fill", "none"), j.setAttribute("stroke-linecap", "round"), d.appendChild(j);
882
+ var e = this, a = this._data, r = this._canvas, t = Math.max(window.devicePixelRatio || 1, 1), n = 0, i = 0, c = r.width / t, o = r.height / t, v = document.createElementNS("http://www.w3.org/2000/svg", "svg");
883
+ v.setAttributeNS(null, "width", r.width), v.setAttributeNS(null, "height", r.height), this._fromData(a, function(g, F, $) {
884
+ var A = document.createElement("path");
885
+ if (!isNaN(g.control1.x) && !isNaN(g.control1.y) && !isNaN(g.control2.x) && !isNaN(g.control2.y)) {
886
+ 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));
887
+ A.setAttribute("d", f), A.setAttribute("stroke-width", (F.end * 2.25).toFixed(3)), A.setAttribute("stroke", $), A.setAttribute("fill", "none"), A.setAttribute("stroke-linecap", "round"), v.appendChild(A);
888
888
  }
889
- }, function(_) {
890
- var N = document.createElement("circle"), R = typeof e.dotSize == "function" ? e.dotSize() : e.dotSize;
891
- N.setAttribute("r", R), N.setAttribute("cx", _.x), N.setAttribute("cy", _.y), N.setAttribute("fill", _.color), d.appendChild(N);
889
+ }, function(g) {
890
+ var F = document.createElement("circle"), $ = typeof e.dotSize == "function" ? e.dotSize() : e.dotSize;
891
+ F.setAttribute("r", $), F.setAttribute("cx", g.x), F.setAttribute("cy", g.y), F.setAttribute("fill", g.color), v.appendChild(F);
892
892
  });
893
- var s = "data:image/svg+xml;base64,", u = '<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"' + (' viewBox="' + a + " " + o + " " + l + " " + c + '"') + (' width="' + l + '"') + (' height="' + c + '"') + ">", v = d.innerHTML;
894
- if (v === void 0) {
895
- var y = document.createElement("dummy"), b = d.childNodes;
896
- y.innerHTML = "";
897
- for (var x = 0; x < b.length; x += 1)
898
- y.appendChild(b[x].cloneNode(!0));
899
- v = y.innerHTML;
893
+ var u = "data:image/svg+xml;base64,", l = '<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"' + (' viewBox="' + n + " " + i + " " + c + " " + o + '"') + (' width="' + c + '"') + (' height="' + o + '"') + ">", d = v.innerHTML;
894
+ if (d === void 0) {
895
+ var m = document.createElement("dummy"), b = v.childNodes;
896
+ m.innerHTML = "";
897
+ for (var P = 0; P < b.length; P += 1)
898
+ m.appendChild(b[P].cloneNode(!0));
899
+ d = m.innerHTML;
900
900
  }
901
- var g = "</svg>", T = u + v + g;
902
- return s + btoa(T);
901
+ var _ = "</svg>", x = l + d + _;
902
+ return u + btoa(x);
903
903
  };
904
904
  z.prototype.fromData = function(e) {
905
- var n = this;
905
+ var a = this;
906
906
  this.clear(), this._fromData(e, function(r, t) {
907
- return n._drawCurve(r, t.start, t.end);
907
+ return a._drawCurve(r, t.start, t.end);
908
908
  }, function(r) {
909
- return n._drawDot(r);
909
+ return a._drawDot(r);
910
910
  }), this._data = e;
911
911
  };
912
912
  z.prototype.toData = function() {
@@ -916,164 +916,164 @@ const tt = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
916
916
  __proto__: null,
917
917
  default: z
918
918
  }, Symbol.toStringTag, { value: "Module" })), rt = /* @__PURE__ */ Ye(tt);
919
- var le = { exports: {} }, nt = le.exports, Ie;
919
+ var le = { exports: {} }, nt = le.exports, je;
920
920
  function at() {
921
- return Ie || (Ie = 1, (function(e, n) {
921
+ return je || (je = 1, (function(e, a) {
922
922
  (function(r, t) {
923
923
  e.exports = t();
924
924
  })(nt, function() {
925
925
  return (function(r) {
926
- function t(o) {
927
- if (a[o]) return a[o].exports;
928
- var l = a[o] = { exports: {}, id: o, loaded: !1 };
929
- return r[o].call(l.exports, l, l.exports, t), l.loaded = !0, l.exports;
926
+ function t(i) {
927
+ if (n[i]) return n[i].exports;
928
+ var c = n[i] = { exports: {}, id: i, loaded: !1 };
929
+ return r[i].call(c.exports, c, c.exports, t), c.loaded = !0, c.exports;
930
930
  }
931
- var a = {};
932
- return t.m = r, t.c = a, t.p = "", t(0);
931
+ var n = {};
932
+ return t.m = r, t.c = n, t.p = "", t(0);
933
933
  })([function(r, t) {
934
- function a(s) {
935
- var u = s.getContext("2d"), v = s.width, y = s.height, b = u.getImageData(0, 0, v, y).data, x = c(!0, v, y, b), g = c(!1, v, y, b), T = d(!0, v, y, b), _ = d(!1, v, y, b), N = _ - T + 1, R = g - x + 1, j = u.getImageData(T, x, N, R);
936
- return s.width = N, s.height = R, u.clearRect(0, 0, N, R), u.putImageData(j, 0, 0), s;
934
+ function n(u) {
935
+ var l = u.getContext("2d"), d = u.width, m = u.height, b = l.getImageData(0, 0, d, m).data, P = o(!0, d, m, b), _ = o(!1, d, m, b), x = v(!0, d, m, b), g = v(!1, d, m, b), F = g - x + 1, $ = _ - P + 1, A = l.getImageData(x, P, F, $);
936
+ return u.width = F, u.height = $, l.clearRect(0, 0, F, $), l.putImageData(A, 0, 0), u;
937
937
  }
938
- function o(s, u, v, y) {
939
- return { red: y[4 * (v * u + s)], green: y[4 * (v * u + s) + 1], blue: y[4 * (v * u + s) + 2], alpha: y[4 * (v * u + s) + 3] };
938
+ function i(u, l, d, m) {
939
+ return { red: m[4 * (d * l + u)], green: m[4 * (d * l + u) + 1], blue: m[4 * (d * l + u) + 2], alpha: m[4 * (d * l + u) + 3] };
940
940
  }
941
- function l(s, u, v, y) {
942
- return o(s, u, v, y).alpha;
941
+ function c(u, l, d, m) {
942
+ return i(u, l, d, m).alpha;
943
943
  }
944
- function c(s, u, v, y) {
945
- for (var b = s ? 1 : -1, x = s ? 0 : v - 1, g = x; s ? g < v : g > -1; g += b) for (var T = 0; T < u; T++) if (l(T, g, u, y)) return g;
944
+ function o(u, l, d, m) {
945
+ for (var b = u ? 1 : -1, P = u ? 0 : d - 1, _ = P; u ? _ < d : _ > -1; _ += b) for (var x = 0; x < l; x++) if (c(x, _, l, m)) return _;
946
946
  return null;
947
947
  }
948
- function d(s, u, v, y) {
949
- for (var b = s ? 1 : -1, x = s ? 0 : u - 1, g = x; s ? g < u : g > -1; g += b) for (var T = 0; T < v; T++) if (l(g, T, u, y)) return g;
948
+ function v(u, l, d, m) {
949
+ for (var b = u ? 1 : -1, P = u ? 0 : l - 1, _ = P; u ? _ < l : _ > -1; _ += b) for (var x = 0; x < d; x++) if (c(_, x, l, m)) return _;
950
950
  return null;
951
951
  }
952
- Object.defineProperty(t, "__esModule", { value: !0 }), t.default = a;
952
+ Object.defineProperty(t, "__esModule", { value: !0 }), t.default = n;
953
953
  }]);
954
954
  });
955
955
  })(le)), le.exports;
956
956
  }
957
- var ot = ce.exports, Le;
957
+ var ot = ce.exports, Ie;
958
958
  function it() {
959
- return Le || (Le = 1, (function(e, n) {
959
+ return Ie || (Ie = 1, (function(e, a) {
960
960
  (function(r, t) {
961
- e.exports = t(/* @__PURE__ */ Qe(), Ne, rt, at());
962
- })(ot, function(r, t, a, o) {
963
- return (function(l) {
964
- function c(s) {
965
- if (d[s]) return d[s].exports;
966
- var u = d[s] = { exports: {}, id: s, loaded: !1 };
967
- return l[s].call(u.exports, u, u.exports, c), u.loaded = !0, u.exports;
961
+ e.exports = t(/* @__PURE__ */ Qe(), We, rt, at());
962
+ })(ot, function(r, t, n, i) {
963
+ return (function(c) {
964
+ function o(u) {
965
+ if (v[u]) return v[u].exports;
966
+ var l = v[u] = { exports: {}, id: u, loaded: !1 };
967
+ return c[u].call(l.exports, l, l.exports, o), l.loaded = !0, l.exports;
968
968
  }
969
- var d = {};
970
- return c.m = l, c.c = d, c.p = "", c(0);
971
- })([function(l, c, d) {
972
- function s(A) {
973
- return A && A.__esModule ? A : { default: A };
969
+ var v = {};
970
+ return o.m = c, o.c = v, o.p = "", o(0);
971
+ })([function(c, o, v) {
972
+ function u(R) {
973
+ return R && R.__esModule ? R : { default: R };
974
974
  }
975
- function u(A, P) {
976
- var q = {};
977
- for (var F in A) P.indexOf(F) >= 0 || Object.prototype.hasOwnProperty.call(A, F) && (q[F] = A[F]);
978
- return q;
975
+ function l(R, w) {
976
+ var M = {};
977
+ for (var N in R) w.indexOf(N) >= 0 || Object.prototype.hasOwnProperty.call(R, N) && (M[N] = R[N]);
978
+ return M;
979
979
  }
980
- function v(A, P) {
981
- if (!(A instanceof P)) throw new TypeError("Cannot call a class as a function");
980
+ function d(R, w) {
981
+ if (!(R instanceof w)) throw new TypeError("Cannot call a class as a function");
982
982
  }
983
- function y(A, P) {
984
- if (!A) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
985
- return !P || typeof P != "object" && typeof P != "function" ? A : P;
983
+ function m(R, w) {
984
+ if (!R) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
985
+ return !w || typeof w != "object" && typeof w != "function" ? R : w;
986
986
  }
987
- function b(A, P) {
988
- if (typeof P != "function" && P !== null) throw new TypeError("Super expression must either be null or a function, not " + typeof P);
989
- A.prototype = Object.create(P && P.prototype, { constructor: { value: A, enumerable: !1, writable: !0, configurable: !0 } }), P && (Object.setPrototypeOf ? Object.setPrototypeOf(A, P) : A.__proto__ = P);
987
+ function b(R, w) {
988
+ if (typeof w != "function" && w !== null) throw new TypeError("Super expression must either be null or a function, not " + typeof w);
989
+ R.prototype = Object.create(w && w.prototype, { constructor: { value: R, enumerable: !1, writable: !0, configurable: !0 } }), w && (Object.setPrototypeOf ? Object.setPrototypeOf(R, w) : R.__proto__ = w);
990
990
  }
991
- Object.defineProperty(c, "__esModule", { value: !0 });
992
- var x = Object.assign || function(A) {
993
- for (var P = 1; P < arguments.length; P++) {
994
- var q = arguments[P];
995
- for (var F in q) Object.prototype.hasOwnProperty.call(q, F) && (A[F] = q[F]);
991
+ Object.defineProperty(o, "__esModule", { value: !0 });
992
+ var P = Object.assign || function(R) {
993
+ for (var w = 1; w < arguments.length; w++) {
994
+ var M = arguments[w];
995
+ for (var N in M) Object.prototype.hasOwnProperty.call(M, N) && (R[N] = M[N]);
996
996
  }
997
- return A;
998
- }, g = /* @__PURE__ */ (function() {
999
- function A(P, q) {
1000
- for (var F = 0; F < q.length; F++) {
1001
- var m = q[F];
1002
- m.enumerable = m.enumerable || !1, m.configurable = !0, "value" in m && (m.writable = !0), Object.defineProperty(P, m.key, m);
997
+ return R;
998
+ }, _ = /* @__PURE__ */ (function() {
999
+ function R(w, M) {
1000
+ for (var N = 0; N < M.length; N++) {
1001
+ var y = M[N];
1002
+ y.enumerable = y.enumerable || !1, y.configurable = !0, "value" in y && (y.writable = !0), Object.defineProperty(w, y.key, y);
1003
1003
  }
1004
1004
  }
1005
- return function(P, q, F) {
1006
- return q && A(P.prototype, q), F && A(P, F), P;
1005
+ return function(w, M, N) {
1006
+ return M && R(w.prototype, M), N && R(w, N), w;
1007
1007
  };
1008
- })(), T = d(1), _ = s(T), N = d(2), R = s(N), j = d(3), f = s(j), G = d(4), Q = s(G), K = (function(A) {
1009
- function P() {
1010
- var q, F, m, H;
1011
- v(this, P);
1012
- for (var ee = arguments.length, $ = Array(ee), Y = 0; Y < ee; Y++) $[Y] = arguments[Y];
1013
- return F = m = y(this, (q = P.__proto__ || Object.getPrototypeOf(P)).call.apply(q, [this].concat($))), m._sigPad = null, m._excludeOurProps = function() {
1014
- var B = m.props, J = (B.canvasProps, B.clearOnResize, u(B, ["canvasProps", "clearOnResize"]));
1008
+ })(), x = v(1), g = u(x), F = v(2), $ = u(F), A = v(3), f = u(A), Z = v(4), te = u(Z), K = (function(R) {
1009
+ function w() {
1010
+ var M, N, y, Y;
1011
+ d(this, w);
1012
+ for (var ne = arguments.length, V = Array(ne), X = 0; X < ne; X++) V[X] = arguments[X];
1013
+ return N = y = m(this, (M = w.__proto__ || Object.getPrototypeOf(w)).call.apply(M, [this].concat(V))), y._sigPad = null, y._excludeOurProps = function() {
1014
+ var q = y.props, J = (q.canvasProps, q.clearOnResize, l(q, ["canvasProps", "clearOnResize"]));
1015
1015
  return J;
1016
- }, m.getCanvas = function() {
1017
- return m._canvas;
1018
- }, m.getTrimmedCanvas = function() {
1019
- var B = document.createElement("canvas");
1020
- return B.width = m._canvas.width, B.height = m._canvas.height, B.getContext("2d").drawImage(m._canvas, 0, 0), (0, Q.default)(B);
1021
- }, m.getSignaturePad = function() {
1022
- return m._sigPad;
1023
- }, m._checkClearOnResize = function() {
1024
- m.props.clearOnResize && m._resizeCanvas();
1025
- }, m._resizeCanvas = function() {
1026
- var B = m.props.canvasProps || {}, J = B.width, i = B.height;
1027
- if (!J || !i) {
1028
- var h = m._canvas, w = Math.max(window.devicePixelRatio || 1, 1);
1029
- J || (h.width = h.offsetWidth * w), i || (h.height = h.offsetHeight * w), h.getContext("2d").scale(w, w), m.clear();
1016
+ }, y.getCanvas = function() {
1017
+ return y._canvas;
1018
+ }, y.getTrimmedCanvas = function() {
1019
+ var q = document.createElement("canvas");
1020
+ return q.width = y._canvas.width, q.height = y._canvas.height, q.getContext("2d").drawImage(y._canvas, 0, 0), (0, te.default)(q);
1021
+ }, y.getSignaturePad = function() {
1022
+ return y._sigPad;
1023
+ }, y._checkClearOnResize = function() {
1024
+ y.props.clearOnResize && y._resizeCanvas();
1025
+ }, y._resizeCanvas = function() {
1026
+ var q = y.props.canvasProps || {}, J = q.width, s = q.height;
1027
+ if (!J || !s) {
1028
+ var h = y._canvas, E = Math.max(window.devicePixelRatio || 1, 1);
1029
+ J || (h.width = h.offsetWidth * E), s || (h.height = h.offsetHeight * E), h.getContext("2d").scale(E, E), y.clear();
1030
1030
  }
1031
- }, m.on = function() {
1032
- return window.addEventListener("resize", m._checkClearOnResize), m._sigPad.on();
1033
- }, m.off = function() {
1034
- return window.removeEventListener("resize", m._checkClearOnResize), m._sigPad.off();
1035
- }, m.clear = function() {
1036
- return m._sigPad.clear();
1037
- }, m.isEmpty = function() {
1038
- return m._sigPad.isEmpty();
1039
- }, m.fromDataURL = function(B, J) {
1040
- return m._sigPad.fromDataURL(B, J);
1041
- }, m.toDataURL = function(B, J) {
1042
- return m._sigPad.toDataURL(B, J);
1043
- }, m.fromData = function(B) {
1044
- return m._sigPad.fromData(B);
1045
- }, m.toData = function() {
1046
- return m._sigPad.toData();
1047
- }, H = F, y(m, H);
1031
+ }, y.on = function() {
1032
+ return window.addEventListener("resize", y._checkClearOnResize), y._sigPad.on();
1033
+ }, y.off = function() {
1034
+ return window.removeEventListener("resize", y._checkClearOnResize), y._sigPad.off();
1035
+ }, y.clear = function() {
1036
+ return y._sigPad.clear();
1037
+ }, y.isEmpty = function() {
1038
+ return y._sigPad.isEmpty();
1039
+ }, y.fromDataURL = function(q, J) {
1040
+ return y._sigPad.fromDataURL(q, J);
1041
+ }, y.toDataURL = function(q, J) {
1042
+ return y._sigPad.toDataURL(q, J);
1043
+ }, y.fromData = function(q) {
1044
+ return y._sigPad.fromData(q);
1045
+ }, y.toData = function() {
1046
+ return y._sigPad.toData();
1047
+ }, Y = N, m(y, Y);
1048
1048
  }
1049
- return b(P, A), g(P, [{ key: "componentDidMount", value: function() {
1049
+ return b(w, R), _(w, [{ key: "componentDidMount", value: function() {
1050
1050
  this._sigPad = new f.default(this._canvas, this._excludeOurProps()), this._resizeCanvas(), this.on();
1051
1051
  } }, { key: "componentWillUnmount", value: function() {
1052
1052
  this.off();
1053
1053
  } }, { key: "componentDidUpdate", value: function() {
1054
1054
  Object.assign(this._sigPad, this._excludeOurProps());
1055
1055
  } }, { key: "render", value: function() {
1056
- var q = this, F = this.props.canvasProps;
1057
- return R.default.createElement("canvas", x({ ref: function(m) {
1058
- q._canvas = m;
1059
- } }, F));
1060
- } }]), P;
1061
- })(N.Component);
1062
- K.propTypes = { velocityFilterWeight: _.default.number, minWidth: _.default.number, maxWidth: _.default.number, minDistance: _.default.number, dotSize: _.default.oneOfType([_.default.number, _.default.func]), penColor: _.default.string, throttle: _.default.number, onEnd: _.default.func, onBegin: _.default.func, canvasProps: _.default.object, clearOnResize: _.default.bool }, K.defaultProps = { clearOnResize: !0 }, c.default = K;
1063
- }, function(l, c) {
1064
- l.exports = r;
1065
- }, function(l, c) {
1066
- l.exports = t;
1067
- }, function(l, c) {
1068
- l.exports = a;
1069
- }, function(l, c) {
1070
- l.exports = o;
1056
+ var M = this, N = this.props.canvasProps;
1057
+ return $.default.createElement("canvas", P({ ref: function(y) {
1058
+ M._canvas = y;
1059
+ } }, N));
1060
+ } }]), w;
1061
+ })(F.Component);
1062
+ K.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 }, K.defaultProps = { clearOnResize: !0 }, o.default = K;
1063
+ }, function(c, o) {
1064
+ c.exports = r;
1065
+ }, function(c, o) {
1066
+ c.exports = t;
1067
+ }, function(c, o) {
1068
+ c.exports = n;
1069
+ }, function(c, o) {
1070
+ c.exports = i;
1071
1071
  }]);
1072
1072
  });
1073
1073
  })(ce)), ce.exports;
1074
1074
  }
1075
1075
  var st = it();
1076
- const ut = /* @__PURE__ */ He(st), ct = "_Signature_1sp4s_1", lt = "_Main_1sp4s_7", ft = "_MainAuto_1sp4s_17", dt = "_MainManual_1sp4s_21", ht = "_Footer_1sp4s_27", pt = "_Header_1sp4s_37", vt = "_HeaderTitle_1sp4s_47", yt = "_HeaderManualDraw_1sp4s_52", mt = "_HeaderNotManualDraw_1sp4s_56", _t = "_HeaderReset_1sp4s_60", gt = "_ManualPanel_1sp4s_71", bt = "_ManualPanelButton_1sp4s_82", xt = "_AutoPanel_1sp4s_97", Pt = "_AutoPanelImage_1sp4s_104", wt = "_AutoPanelLoader_1sp4s_110", Et = "_AutoPanelButton_1sp4s_117", Tt = "_AutoPanelLabel_1sp4s_121", St = "_AutoPanelLabelIcon_1sp4s_129", Ot = "_AutoPanelLabelText_1sp4s_135", Ct = "_AutoPanelError_1sp4s_142", Rt = "_AutoPanelErrorTitle_1sp4s_151", U = {
1076
+ const ut = /* @__PURE__ */ He(st), ct = "_Signature_1sp4s_1", lt = "_Main_1sp4s_7", ft = "_MainAuto_1sp4s_17", dt = "_MainManual_1sp4s_21", ht = "_Footer_1sp4s_27", pt = "_Header_1sp4s_37", vt = "_HeaderTitle_1sp4s_47", yt = "_HeaderManualDraw_1sp4s_52", mt = "_HeaderNotManualDraw_1sp4s_56", _t = "_HeaderReset_1sp4s_60", gt = "_ManualPanel_1sp4s_71", bt = "_ManualPanelButton_1sp4s_82", xt = "_AutoPanel_1sp4s_97", Pt = "_AutoPanelImage_1sp4s_104", wt = "_AutoPanelLoader_1sp4s_110", Et = "_AutoPanelButton_1sp4s_117", Tt = "_AutoPanelLabel_1sp4s_121", St = "_AutoPanelLabelIcon_1sp4s_129", Ct = "_AutoPanelLabelText_1sp4s_135", Ot = "_AutoPanelError_1sp4s_142", At = "_AutoPanelErrorTitle_1sp4s_151", B = {
1077
1077
  Signature: ct,
1078
1078
  Main: lt,
1079
1079
  MainAuto: ft,
@@ -1092,105 +1092,93 @@ const ut = /* @__PURE__ */ He(st), ct = "_Signature_1sp4s_1", lt = "_Main_1sp4s_
1092
1092
  AutoPanelButton: Et,
1093
1093
  AutoPanelLabel: Tt,
1094
1094
  AutoPanelLabelIcon: St,
1095
- AutoPanelLabelText: Ot,
1096
- AutoPanelError: Ct,
1097
- AutoPanelErrorTitle: Rt
1098
- }, zt = ({
1095
+ AutoPanelLabelText: Ct,
1096
+ AutoPanelError: Ot,
1097
+ AutoPanelErrorTitle: At
1098
+ }, Nt = ({
1099
1099
  // Signature props
1100
- name: e,
1101
- auto: n,
1102
- manual: r,
1103
- getSignature: t,
1104
- onChangeManual: a,
1105
- onChangeAuto: o,
1100
+ auto: e,
1101
+ manual: a,
1102
+ getSignature: r,
1103
+ onChangeManual: t,
1104
+ onChangeAuto: n,
1106
1105
  // Base props
1107
- ...l
1106
+ ...i
1108
1107
  }) => {
1109
- const c = fe(null), d = fe(e), s = fe(!1), [u, v] = oe(null), [y, b] = oe(r ? "manual" : "auto"), [x, g] = oe(""), [T, _] = oe(!1), { width: N = 0, height: R = 0 } = ze({ ref: c, box: "border-box" }), j = y === "auto" ? n ? "auto-generated" : "auto-loading" : x ? "manual-drawn" : r ? "manual-stored" : "manual-blank", f = n !== "" || T, G = r || x, Q = re(
1110
- ($) => {
1111
- !u || !N || !R || !$ || u.fromDataURL($, {
1112
- width: +N.toFixed(),
1113
- height: +R.toFixed()
1108
+ const c = ze(null), [o, v] = oe(null), [u, l] = oe(a ? "manual" : "auto"), [d, m] = oe(""), [b, P] = oe(!1), { width: _ = 0, height: x = 0 } = Ne({ ref: c, box: "border-box" }), g = u === "auto" ? e ? "auto-generated" : "auto-loading" : d ? "manual-drawn" : a ? "manual-stored" : "manual-blank", F = e !== "" || b, $ = a || d, A = ee(
1109
+ (y) => {
1110
+ !o || !_ || !x || !y || o.fromDataURL(y, {
1111
+ width: +_.toFixed(),
1112
+ height: +x.toFixed()
1114
1113
  });
1115
1114
  },
1116
- [u, N, R]
1117
- ), K = re(() => {
1118
- if (!u) return;
1119
- const $ = u.getCanvas().toDataURL("image/png");
1120
- g($), a($);
1121
- }, [u, a]), A = re(() => {
1122
- u && (u.clear(), g(""), a(""));
1123
- }, [u, a]), P = re(() => {
1124
- b("auto"), g("");
1125
- }, []), q = re(() => {
1126
- b("manual");
1127
- }, []), F = re(() => {
1128
- b("auto"), g(""), a("");
1129
- }, [a]), m = re(() => {
1130
- x && g("");
1131
- }, [x]), H = ($) => $.includes(j);
1132
- de(() => {
1133
- y === "manual" && x && N && R && Q(x);
1134
- }, [y, x, N, R, Q]), de(() => {
1135
- console.log("NAME CHANGED", d.current === e), d.current !== e && (console.log(d.current, e), d.current = e, t().then(($) => {
1136
- const Y = `data:image/png;base64,${$.signature}`;
1137
- _(!1), o(Y);
1115
+ [o, _, x]
1116
+ ), f = ee(() => {
1117
+ if (!o) return;
1118
+ const y = o.getCanvas().toDataURL("image/png");
1119
+ m(y), t(y);
1120
+ }, [o, t]), Z = ee(() => {
1121
+ o && (o.clear(), m(""), t(""));
1122
+ }, [o, t]), te = ee(() => {
1123
+ l("auto"), m("");
1124
+ }, []), K = ee(() => {
1125
+ l("manual");
1126
+ }, []), R = ee(() => {
1127
+ l("auto"), m(""), t("");
1128
+ }, [t]), w = ee(() => {
1129
+ d && m("");
1130
+ }, [d]), M = (y) => y.includes(g);
1131
+ xe(() => {
1132
+ u === "manual" && d && _ && x && A(d);
1133
+ }, [u, d, _, x, A]), xe(() => {
1134
+ r().then((y) => {
1135
+ const Y = `data:image/png;base64,${y.signature}`;
1136
+ P(!1), n(Y);
1138
1137
  }).catch(() => {
1139
- _(!0);
1140
- }));
1141
- }, [e, o]), de(() => {
1142
- if (n) {
1143
- s.current = !1;
1144
- return;
1145
- }
1146
- s.current || (s.current = !0, t().then(($) => {
1147
- const Y = `data:image/png;base64,${$.signature}`;
1148
- _(!1), o(Y);
1149
- }).catch(() => {
1150
- _(!0);
1151
- }));
1152
- }, [n, e, t, o]);
1153
- const ee = re(() => {
1154
- _(!1), s.current = !0, t().then(($) => {
1155
- const Y = `data:image/png;base64,${$.signature}`;
1156
- _(!1), o(Y);
1138
+ P(!0);
1139
+ });
1140
+ }, []);
1141
+ const N = ee(() => {
1142
+ P(!1), r().then((y) => {
1143
+ const Y = `data:image/png;base64,${y.signature}`;
1144
+ P(!1), n(Y);
1157
1145
  }).catch(() => {
1158
- _(!0);
1146
+ P(!0);
1159
1147
  });
1160
- }, [t, o]);
1161
- return /* @__PURE__ */ te(
1148
+ }, [r, n]);
1149
+ return /* @__PURE__ */ Q(
1162
1150
  "div",
1163
1151
  {
1164
- "data-testid": Ee(l, "data-testid", "signature"),
1165
- className: he(U.Signature, Ee(l, "className")),
1152
+ "data-testid": we(i, "data-testid", "signature"),
1153
+ className: fe(B.Signature, we(i, "className")),
1166
1154
  children: [
1167
- /* @__PURE__ */ te(
1155
+ /* @__PURE__ */ Q(
1168
1156
  "div",
1169
1157
  {
1170
- className: he(U.Main, H(["auto-generated", "auto-loading"]) ? U.MainAuto : U.MainManual),
1158
+ className: fe(B.Main, M(["auto-generated", "auto-loading"]) ? B.MainAuto : B.MainManual),
1171
1159
  ref: c,
1172
1160
  children: [
1173
- /* @__PURE__ */ te("div", { className: he(U.Header, H(["manual-drawn"]) ? U.HeaderManualDraw : U.HeaderNotManualDraw), children: [
1174
- H(["auto-generated", "auto-loading"]) && /* @__PURE__ */ V("span", { className: U.HeaderTitle, children: "Wir haben eine digitale Signature Sie generiert." }),
1175
- H(["manual-blank", "manual-stored"]) && /* @__PURE__ */ V("span", { className: U.HeaderTitle, children: "Ihre Signatur:" }),
1176
- H(["manual-drawn"]) && /* @__PURE__ */ V(
1161
+ /* @__PURE__ */ Q("div", { className: fe(B.Header, M(["manual-drawn"]) ? B.HeaderManualDraw : B.HeaderNotManualDraw), children: [
1162
+ M(["auto-generated", "auto-loading"]) && /* @__PURE__ */ U("span", { className: B.HeaderTitle, children: "Wir haben eine digitale Signature Sie generiert." }),
1163
+ M(["manual-blank", "manual-stored"]) && /* @__PURE__ */ U("span", { className: B.HeaderTitle, children: "Ihre Signatur:" }),
1164
+ M(["manual-drawn"]) && /* @__PURE__ */ U(
1177
1165
  ie,
1178
1166
  {
1179
1167
  blurAfterClick: !0,
1180
1168
  text: "Neu starten",
1181
1169
  underlined: !0,
1182
- icon: /* @__PURE__ */ V(Fe, {}),
1183
- className: U.HeaderReset,
1184
- onClick: A
1170
+ icon: /* @__PURE__ */ U(Fe, {}),
1171
+ className: B.HeaderReset,
1172
+ onClick: Z
1185
1173
  }
1186
1174
  )
1187
1175
  ] }),
1188
- H(["auto-generated", "auto-loading"]) ? /* @__PURE__ */ te("div", { className: U.AutoPanel, children: [
1189
- n !== "" && /* @__PURE__ */ V("img", { className: U.AutoPanelImage, src: n, alt: "signature" }),
1190
- n === "" && !T && /* @__PURE__ */ V(Ue, { size: "sm", color: "accent-primary", className: U.AutoPanelLoader }),
1191
- n === "" && T && /* @__PURE__ */ te("div", { className: U.AutoPanelError, children: [
1192
- /* @__PURE__ */ V("span", { className: U.AutoPanelErrorTitle, children: "Automatische Signatur konnte nicht geladen werden." }),
1193
- /* @__PURE__ */ V(
1176
+ M(["auto-generated", "auto-loading"]) ? /* @__PURE__ */ Q("div", { className: B.AutoPanel, children: [
1177
+ e !== "" && /* @__PURE__ */ U("img", { className: B.AutoPanelImage, src: e, alt: "signature" }),
1178
+ e === "" && !b && /* @__PURE__ */ U(Ue, { size: "sm", color: "accent-primary", className: B.AutoPanelLoader }),
1179
+ e === "" && b && /* @__PURE__ */ Q("div", { className: B.AutoPanelError, children: [
1180
+ /* @__PURE__ */ U("span", { className: B.AutoPanelErrorTitle, children: "Automatische Signatur konnte nicht geladen werden." }),
1181
+ /* @__PURE__ */ U(
1194
1182
  ie,
1195
1183
  {
1196
1184
  blurAfterClick: !0,
@@ -1198,28 +1186,28 @@ const ut = /* @__PURE__ */ He(st), ct = "_Signature_1sp4s_1", lt = "_Main_1sp4s_
1198
1186
  text: "Erneut versuchen",
1199
1187
  size: "sm",
1200
1188
  iconPosition: "right",
1201
- icon: /* @__PURE__ */ V(qe, {}),
1202
- onClick: ee
1189
+ icon: /* @__PURE__ */ U(qe, {}),
1190
+ onClick: N
1203
1191
  }
1204
1192
  )
1205
1193
  ] }),
1206
- n !== "" && /* @__PURE__ */ te("div", { className: U.AutoPanelLabel, children: [
1207
- /* @__PURE__ */ V(Be, { className: U.AutoPanelLabelIcon }),
1208
- /* @__PURE__ */ V("span", { className: U.AutoPanelLabelText, children: "Diese Unterschrift ist ausreichend" })
1194
+ e !== "" && /* @__PURE__ */ Q("div", { className: B.AutoPanelLabel, children: [
1195
+ /* @__PURE__ */ U(Be, { className: B.AutoPanelLabelIcon }),
1196
+ /* @__PURE__ */ U("span", { className: B.AutoPanelLabelText, children: "Diese Unterschrift ist ausreichend" })
1209
1197
  ] }),
1210
- f && /* @__PURE__ */ V(
1198
+ F && /* @__PURE__ */ U(
1211
1199
  ie,
1212
1200
  {
1213
1201
  blurAfterClick: !0,
1214
1202
  color: "link",
1215
1203
  text: "Per Hand/Maus unterschreiben",
1216
1204
  underlined: !0,
1217
- className: U.AutoPanelButton,
1218
- onClick: q
1205
+ className: B.AutoPanelButton,
1206
+ onClick: K
1219
1207
  }
1220
1208
  )
1221
- ] }) : /* @__PURE__ */ te("div", { className: U.ManualPanel, children: [
1222
- H(["manual-stored"]) ? /* @__PURE__ */ V("img", { width: N, height: R, alt: "signature", src: G }) : /* @__PURE__ */ V(
1209
+ ] }) : /* @__PURE__ */ Q("div", { className: B.ManualPanel, children: [
1210
+ M(["manual-stored"]) ? /* @__PURE__ */ U("img", { width: _, height: x, alt: "signature", src: $ }) : /* @__PURE__ */ U(
1223
1211
  ut,
1224
1212
  {
1225
1213
  penColor: "#262626",
@@ -1227,37 +1215,37 @@ const ut = /* @__PURE__ */ He(st), ct = "_Signature_1sp4s_1", lt = "_Main_1sp4s_
1227
1215
  minWidth: 0.25,
1228
1216
  maxWidth: 2.75,
1229
1217
  throttle: 12,
1230
- canvasProps: { width: +(N || 0).toFixed(), height: +(R || 0).toFixed() },
1231
- ref: ($) => v($),
1218
+ canvasProps: { width: +(_ || 0).toFixed(), height: +(x || 0).toFixed() },
1219
+ ref: (y) => v(y),
1232
1220
  clearOnResize: !0,
1233
- onEnd: K
1221
+ onEnd: f
1234
1222
  }
1235
1223
  ),
1236
- H(["manual-stored"]) && /* @__PURE__ */ V(
1224
+ M(["manual-stored"]) && /* @__PURE__ */ U(
1237
1225
  ie,
1238
1226
  {
1239
1227
  blurAfterClick: !0,
1240
1228
  underlined: !0,
1241
1229
  text: "Zurücksetzen",
1242
- className: U.ManualPanelButton,
1243
- onClick: F
1230
+ className: B.ManualPanelButton,
1231
+ onClick: R
1244
1232
  }
1245
1233
  )
1246
1234
  ] })
1247
1235
  ]
1248
1236
  }
1249
1237
  ),
1250
- H(["manual-blank", "manual-drawn"]) && /* @__PURE__ */ te("div", { className: U.Footer, children: [
1251
- /* @__PURE__ */ V(we, { fullWidth: !0, blurAfterClick: !0, text: "Abbrechen", color: "tertiary", onClick: P }),
1252
- /* @__PURE__ */ V(
1253
- we,
1238
+ M(["manual-blank", "manual-drawn"]) && /* @__PURE__ */ Q("div", { className: B.Footer, children: [
1239
+ /* @__PURE__ */ U(Pe, { fullWidth: !0, blurAfterClick: !0, text: "Abbrechen", color: "tertiary", onClick: te }),
1240
+ /* @__PURE__ */ U(
1241
+ Pe,
1254
1242
  {
1255
1243
  fullWidth: !0,
1256
1244
  blurAfterClick: !0,
1257
1245
  text: "Speichern",
1258
1246
  color: "primary",
1259
- disabled: !x,
1260
- onClick: m
1247
+ disabled: !d,
1248
+ onClick: w
1261
1249
  }
1262
1250
  )
1263
1251
  ] })
@@ -1266,5 +1254,5 @@ const ut = /* @__PURE__ */ He(st), ct = "_Signature_1sp4s_1", lt = "_Main_1sp4s_
1266
1254
  );
1267
1255
  };
1268
1256
  export {
1269
- zt as Signature
1257
+ Nt as Signature
1270
1258
  };