@designbyadrian/react-interactive-input 2.0.2 → 3.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +40 -5
- package/dist/react-interactive-input.cjs.js +7 -15
- package/dist/react-interactive-input.es.js +397 -667
- package/dist/types/InteractiveInput.d.ts +9 -2
- package/dist/types/MaskedInput.d.ts +14 -2
- package/dist/types/masks.d.ts +9 -2
- package/dist/types/utils.d.ts +26 -1
- package/package.json +32 -22
|
@@ -1,757 +1,487 @@
|
|
|
1
|
-
import
|
|
2
|
-
var
|
|
1
|
+
import ie, { forwardRef as le, useRef as J, useImperativeHandle as fe, useState as Z, useEffect as se } from "react";
|
|
2
|
+
var q = { exports: {} }, D = {};
|
|
3
3
|
/**
|
|
4
4
|
* @license React
|
|
5
|
-
* react-jsx-runtime.production.
|
|
5
|
+
* react-jsx-runtime.production.js
|
|
6
6
|
*
|
|
7
|
-
* Copyright (c)
|
|
7
|
+
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
8
8
|
*
|
|
9
9
|
* This source code is licensed under the MIT license found in the
|
|
10
10
|
* LICENSE file in the root directory of this source tree.
|
|
11
11
|
*/
|
|
12
|
-
var
|
|
13
|
-
function
|
|
14
|
-
if (
|
|
15
|
-
|
|
16
|
-
var
|
|
17
|
-
function
|
|
18
|
-
var
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
12
|
+
var te;
|
|
13
|
+
function de() {
|
|
14
|
+
if (te) return D;
|
|
15
|
+
te = 1;
|
|
16
|
+
var a = Symbol.for("react.transitional.element"), d = Symbol.for("react.fragment");
|
|
17
|
+
function R(v, u, m) {
|
|
18
|
+
var g = null;
|
|
19
|
+
if (m !== void 0 && (g = "" + m), u.key !== void 0 && (g = "" + u.key), "key" in u) {
|
|
20
|
+
m = {};
|
|
21
|
+
for (var E in u)
|
|
22
|
+
E !== "key" && (m[E] = u[E]);
|
|
23
|
+
} else m = u;
|
|
24
|
+
return u = m.ref, {
|
|
25
|
+
$$typeof: a,
|
|
26
|
+
type: v,
|
|
27
|
+
key: g,
|
|
28
|
+
ref: u !== void 0 ? u : null,
|
|
29
|
+
props: m
|
|
30
|
+
};
|
|
23
31
|
}
|
|
24
|
-
return
|
|
32
|
+
return D.Fragment = d, D.jsx = R, D.jsxs = R, D;
|
|
25
33
|
}
|
|
26
|
-
var
|
|
34
|
+
var L = {};
|
|
27
35
|
/**
|
|
28
36
|
* @license React
|
|
29
37
|
* react-jsx-runtime.development.js
|
|
30
38
|
*
|
|
31
|
-
* Copyright (c)
|
|
39
|
+
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
32
40
|
*
|
|
33
41
|
* This source code is licensed under the MIT license found in the
|
|
34
42
|
* LICENSE file in the root directory of this source tree.
|
|
35
43
|
*/
|
|
36
|
-
var
|
|
37
|
-
function
|
|
38
|
-
return
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
if (
|
|
42
|
-
return null;
|
|
43
|
-
|
|
44
|
-
return typeof r == "function" ? r : null;
|
|
45
|
-
}
|
|
46
|
-
var D = g.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
|
|
47
|
-
function i(e) {
|
|
48
|
-
{
|
|
49
|
-
for (var r = arguments.length, t = new Array(r > 1 ? r - 1 : 0), n = 1; n < r; n++)
|
|
50
|
-
t[n - 1] = arguments[n];
|
|
51
|
-
R("error", e, t);
|
|
52
|
-
}
|
|
53
|
-
}
|
|
54
|
-
function R(e, r, t) {
|
|
55
|
-
{
|
|
56
|
-
var n = D.ReactDebugCurrentFrame, s = n.getStackAddendum();
|
|
57
|
-
s !== "" && (r += "%s", t = t.concat([s]));
|
|
58
|
-
var l = t.map(function(o) {
|
|
59
|
-
return String(o);
|
|
60
|
-
});
|
|
61
|
-
l.unshift("Warning: " + r), Function.prototype.apply.call(console[e], console, l);
|
|
62
|
-
}
|
|
63
|
-
}
|
|
64
|
-
var $ = !1, W = !1, B = !1, ne = !1, J = !1, Y;
|
|
65
|
-
Y = Symbol.for("react.module.reference");
|
|
66
|
-
function X(e) {
|
|
67
|
-
return !!(typeof e == "string" || typeof e == "function" || e === u || e === j || J || e === C || e === P || e === m || ne || e === b || $ || W || B || typeof e == "object" && e !== null && (e.$$typeof === c || e.$$typeof === T || e.$$typeof === O || e.$$typeof === h || e.$$typeof === d || // This needs to include all possible module reference object
|
|
68
|
-
// types supported by any Flight configuration anywhere since
|
|
69
|
-
// we don't know which Flight build this will end up being used
|
|
70
|
-
// with.
|
|
71
|
-
e.$$typeof === Y || e.getModuleId !== void 0));
|
|
72
|
-
}
|
|
73
|
-
function z(e, r, t) {
|
|
74
|
-
var n = e.displayName;
|
|
75
|
-
if (n)
|
|
76
|
-
return n;
|
|
77
|
-
var s = r.displayName || r.name || "";
|
|
78
|
-
return s !== "" ? t + "(" + s + ")" : t;
|
|
79
|
-
}
|
|
80
|
-
function G(e) {
|
|
81
|
-
return e.displayName || "Context";
|
|
82
|
-
}
|
|
83
|
-
function _(e) {
|
|
84
|
-
if (e == null)
|
|
85
|
-
return null;
|
|
86
|
-
if (typeof e.tag == "number" && i("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."), typeof e == "function")
|
|
87
|
-
return e.displayName || e.name || null;
|
|
88
|
-
if (typeof e == "string")
|
|
89
|
-
return e;
|
|
44
|
+
var re;
|
|
45
|
+
function me() {
|
|
46
|
+
return re || (re = 1, process.env.NODE_ENV !== "production" && (function() {
|
|
47
|
+
function a(e) {
|
|
48
|
+
if (e == null) return null;
|
|
49
|
+
if (typeof e == "function")
|
|
50
|
+
return e.$$typeof === x ? null : e.displayName || e.name || null;
|
|
51
|
+
if (typeof e == "string") return e;
|
|
90
52
|
switch (e) {
|
|
91
|
-
case
|
|
53
|
+
case A:
|
|
92
54
|
return "Fragment";
|
|
93
|
-
case k:
|
|
94
|
-
return "Portal";
|
|
95
|
-
case j:
|
|
96
|
-
return "Profiler";
|
|
97
55
|
case C:
|
|
98
|
-
return "
|
|
56
|
+
return "Profiler";
|
|
99
57
|
case P:
|
|
58
|
+
return "StrictMode";
|
|
59
|
+
case c:
|
|
100
60
|
return "Suspense";
|
|
101
|
-
case
|
|
61
|
+
case p:
|
|
102
62
|
return "SuspenseList";
|
|
63
|
+
case h:
|
|
64
|
+
return "Activity";
|
|
103
65
|
}
|
|
104
66
|
if (typeof e == "object")
|
|
105
|
-
switch (
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
return
|
|
112
|
-
case
|
|
113
|
-
return
|
|
114
|
-
case
|
|
115
|
-
var n = e.
|
|
116
|
-
return n !==
|
|
117
|
-
case
|
|
118
|
-
|
|
67
|
+
switch (typeof e.tag == "number" && console.error(
|
|
68
|
+
"Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."
|
|
69
|
+
), e.$$typeof) {
|
|
70
|
+
case I:
|
|
71
|
+
return "Portal";
|
|
72
|
+
case F:
|
|
73
|
+
return e.displayName || "Context";
|
|
74
|
+
case Y:
|
|
75
|
+
return (e._context.displayName || "Context") + ".Consumer";
|
|
76
|
+
case s:
|
|
77
|
+
var n = e.render;
|
|
78
|
+
return e = e.displayName, e || (e = n.displayName || n.name || "", e = e !== "" ? "ForwardRef(" + e + ")" : "ForwardRef"), e;
|
|
79
|
+
case i:
|
|
80
|
+
return n = e.displayName || null, n !== null ? n : a(e.type) || "Memo";
|
|
81
|
+
case k:
|
|
82
|
+
n = e._payload, e = e._init;
|
|
119
83
|
try {
|
|
120
|
-
return
|
|
84
|
+
return a(e(n));
|
|
121
85
|
} catch {
|
|
122
|
-
return null;
|
|
123
86
|
}
|
|
124
|
-
}
|
|
125
87
|
}
|
|
126
88
|
return null;
|
|
127
89
|
}
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
}
|
|
131
|
-
_e.__reactDisabledLog = !0;
|
|
132
|
-
function Ue() {
|
|
133
|
-
{
|
|
134
|
-
if (I === 0) {
|
|
135
|
-
H = console.log, ge = console.info, pe = console.warn, he = console.error, Ee = console.group, be = console.groupCollapsed, Re = console.groupEnd;
|
|
136
|
-
var e = {
|
|
137
|
-
configurable: !0,
|
|
138
|
-
enumerable: !0,
|
|
139
|
-
value: _e,
|
|
140
|
-
writable: !0
|
|
141
|
-
};
|
|
142
|
-
Object.defineProperties(console, {
|
|
143
|
-
info: e,
|
|
144
|
-
log: e,
|
|
145
|
-
warn: e,
|
|
146
|
-
error: e,
|
|
147
|
-
group: e,
|
|
148
|
-
groupCollapsed: e,
|
|
149
|
-
groupEnd: e
|
|
150
|
-
});
|
|
151
|
-
}
|
|
152
|
-
I++;
|
|
153
|
-
}
|
|
154
|
-
}
|
|
155
|
-
function Ne() {
|
|
156
|
-
{
|
|
157
|
-
if (I--, I === 0) {
|
|
158
|
-
var e = {
|
|
159
|
-
configurable: !0,
|
|
160
|
-
enumerable: !0,
|
|
161
|
-
writable: !0
|
|
162
|
-
};
|
|
163
|
-
Object.defineProperties(console, {
|
|
164
|
-
log: y({}, e, {
|
|
165
|
-
value: H
|
|
166
|
-
}),
|
|
167
|
-
info: y({}, e, {
|
|
168
|
-
value: ge
|
|
169
|
-
}),
|
|
170
|
-
warn: y({}, e, {
|
|
171
|
-
value: pe
|
|
172
|
-
}),
|
|
173
|
-
error: y({}, e, {
|
|
174
|
-
value: he
|
|
175
|
-
}),
|
|
176
|
-
group: y({}, e, {
|
|
177
|
-
value: Ee
|
|
178
|
-
}),
|
|
179
|
-
groupCollapsed: y({}, e, {
|
|
180
|
-
value: be
|
|
181
|
-
}),
|
|
182
|
-
groupEnd: y({}, e, {
|
|
183
|
-
value: Re
|
|
184
|
-
})
|
|
185
|
-
});
|
|
186
|
-
}
|
|
187
|
-
I < 0 && i("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
|
|
188
|
-
}
|
|
189
|
-
}
|
|
190
|
-
var ae = D.ReactCurrentDispatcher, oe;
|
|
191
|
-
function Z(e, r, t) {
|
|
192
|
-
{
|
|
193
|
-
if (oe === void 0)
|
|
194
|
-
try {
|
|
195
|
-
throw Error();
|
|
196
|
-
} catch (s) {
|
|
197
|
-
var n = s.stack.trim().match(/\n( *(at )?)/);
|
|
198
|
-
oe = n && n[1] || "";
|
|
199
|
-
}
|
|
200
|
-
return `
|
|
201
|
-
` + oe + e;
|
|
202
|
-
}
|
|
203
|
-
}
|
|
204
|
-
var ie = !1, Q;
|
|
205
|
-
{
|
|
206
|
-
var qe = typeof WeakMap == "function" ? WeakMap : Map;
|
|
207
|
-
Q = new qe();
|
|
90
|
+
function d(e) {
|
|
91
|
+
return "" + e;
|
|
208
92
|
}
|
|
209
|
-
function
|
|
210
|
-
if (!e || ie)
|
|
211
|
-
return "";
|
|
212
|
-
{
|
|
213
|
-
var t = Q.get(e);
|
|
214
|
-
if (t !== void 0)
|
|
215
|
-
return t;
|
|
216
|
-
}
|
|
217
|
-
var n;
|
|
218
|
-
ie = !0;
|
|
219
|
-
var s = Error.prepareStackTrace;
|
|
220
|
-
Error.prepareStackTrace = void 0;
|
|
221
|
-
var l;
|
|
222
|
-
l = ae.current, ae.current = null, Ue();
|
|
93
|
+
function R(e) {
|
|
223
94
|
try {
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
if (Object.defineProperty(o.prototype, "props", {
|
|
229
|
-
set: function() {
|
|
230
|
-
throw Error();
|
|
231
|
-
}
|
|
232
|
-
}), typeof Reflect == "object" && Reflect.construct) {
|
|
233
|
-
try {
|
|
234
|
-
Reflect.construct(o, []);
|
|
235
|
-
} catch (w) {
|
|
236
|
-
n = w;
|
|
237
|
-
}
|
|
238
|
-
Reflect.construct(e, [], o);
|
|
239
|
-
} else {
|
|
240
|
-
try {
|
|
241
|
-
o.call();
|
|
242
|
-
} catch (w) {
|
|
243
|
-
n = w;
|
|
244
|
-
}
|
|
245
|
-
e.call(o.prototype);
|
|
246
|
-
}
|
|
247
|
-
} else {
|
|
248
|
-
try {
|
|
249
|
-
throw Error();
|
|
250
|
-
} catch (w) {
|
|
251
|
-
n = w;
|
|
252
|
-
}
|
|
253
|
-
e();
|
|
254
|
-
}
|
|
255
|
-
} catch (w) {
|
|
256
|
-
if (w && n && typeof w.stack == "string") {
|
|
257
|
-
for (var a = w.stack.split(`
|
|
258
|
-
`), E = n.stack.split(`
|
|
259
|
-
`), f = a.length - 1, v = E.length - 1; f >= 1 && v >= 0 && a[f] !== E[v]; )
|
|
260
|
-
v--;
|
|
261
|
-
for (; f >= 1 && v >= 0; f--, v--)
|
|
262
|
-
if (a[f] !== E[v]) {
|
|
263
|
-
if (f !== 1 || v !== 1)
|
|
264
|
-
do
|
|
265
|
-
if (f--, v--, v < 0 || a[f] !== E[v]) {
|
|
266
|
-
var x = `
|
|
267
|
-
` + a[f].replace(" at new ", " at ");
|
|
268
|
-
return e.displayName && x.includes("<anonymous>") && (x = x.replace("<anonymous>", e.displayName)), typeof e == "function" && Q.set(e, x), x;
|
|
269
|
-
}
|
|
270
|
-
while (f >= 1 && v >= 0);
|
|
271
|
-
break;
|
|
272
|
-
}
|
|
273
|
-
}
|
|
274
|
-
} finally {
|
|
275
|
-
ie = !1, ae.current = l, Ne(), Error.prepareStackTrace = s;
|
|
276
|
-
}
|
|
277
|
-
var L = e ? e.displayName || e.name : "", A = L ? Z(L) : "";
|
|
278
|
-
return typeof e == "function" && Q.set(e, A), A;
|
|
279
|
-
}
|
|
280
|
-
function Be(e, r, t) {
|
|
281
|
-
return we(e, !1);
|
|
282
|
-
}
|
|
283
|
-
function Je(e) {
|
|
284
|
-
var r = e.prototype;
|
|
285
|
-
return !!(r && r.isReactComponent);
|
|
286
|
-
}
|
|
287
|
-
function ee(e, r, t) {
|
|
288
|
-
if (e == null)
|
|
289
|
-
return "";
|
|
290
|
-
if (typeof e == "function")
|
|
291
|
-
return we(e, Je(e));
|
|
292
|
-
if (typeof e == "string")
|
|
293
|
-
return Z(e);
|
|
294
|
-
switch (e) {
|
|
295
|
-
case P:
|
|
296
|
-
return Z("Suspense");
|
|
297
|
-
case m:
|
|
298
|
-
return Z("SuspenseList");
|
|
299
|
-
}
|
|
300
|
-
if (typeof e == "object")
|
|
301
|
-
switch (e.$$typeof) {
|
|
302
|
-
case d:
|
|
303
|
-
return Be(e.render);
|
|
304
|
-
case T:
|
|
305
|
-
return ee(e.type, r, t);
|
|
306
|
-
case c: {
|
|
307
|
-
var n = e, s = n._payload, l = n._init;
|
|
308
|
-
try {
|
|
309
|
-
return ee(l(s), r, t);
|
|
310
|
-
} catch {
|
|
311
|
-
}
|
|
312
|
-
}
|
|
313
|
-
}
|
|
314
|
-
return "";
|
|
315
|
-
}
|
|
316
|
-
var K = Object.prototype.hasOwnProperty, Te = {}, Se = D.ReactDebugCurrentFrame;
|
|
317
|
-
function re(e) {
|
|
318
|
-
if (e) {
|
|
319
|
-
var r = e._owner, t = ee(e.type, e._source, r ? r.type : null);
|
|
320
|
-
Se.setExtraStackFrame(t);
|
|
321
|
-
} else
|
|
322
|
-
Se.setExtraStackFrame(null);
|
|
323
|
-
}
|
|
324
|
-
function Xe(e, r, t, n, s) {
|
|
325
|
-
{
|
|
326
|
-
var l = Function.call.bind(K);
|
|
327
|
-
for (var o in e)
|
|
328
|
-
if (l(e, o)) {
|
|
329
|
-
var a = void 0;
|
|
330
|
-
try {
|
|
331
|
-
if (typeof e[o] != "function") {
|
|
332
|
-
var E = Error((n || "React class") + ": " + t + " type `" + o + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof e[o] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");
|
|
333
|
-
throw E.name = "Invariant Violation", E;
|
|
334
|
-
}
|
|
335
|
-
a = e[o](r, o, n, t, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
|
|
336
|
-
} catch (f) {
|
|
337
|
-
a = f;
|
|
338
|
-
}
|
|
339
|
-
a && !(a instanceof Error) && (re(s), i("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).", n || "React class", t, o, typeof a), re(null)), a instanceof Error && !(a.message in Te) && (Te[a.message] = !0, re(s), i("Failed %s type: %s", t, a.message), re(null));
|
|
340
|
-
}
|
|
95
|
+
d(e);
|
|
96
|
+
var n = !1;
|
|
97
|
+
} catch {
|
|
98
|
+
n = !0;
|
|
341
99
|
}
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
return t;
|
|
100
|
+
if (n) {
|
|
101
|
+
n = console;
|
|
102
|
+
var o = n.error, l = typeof Symbol == "function" && Symbol.toStringTag && e[Symbol.toStringTag] || e.constructor.name || "Object";
|
|
103
|
+
return o.call(
|
|
104
|
+
n,
|
|
105
|
+
"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",
|
|
106
|
+
l
|
|
107
|
+
), d(e);
|
|
351
108
|
}
|
|
352
109
|
}
|
|
353
|
-
function
|
|
110
|
+
function v(e) {
|
|
111
|
+
if (e === A) return "<>";
|
|
112
|
+
if (typeof e == "object" && e !== null && e.$$typeof === k)
|
|
113
|
+
return "<...>";
|
|
354
114
|
try {
|
|
355
|
-
|
|
115
|
+
var n = a(e);
|
|
116
|
+
return n ? "<" + n + ">" : "<...>";
|
|
356
117
|
} catch {
|
|
357
|
-
return
|
|
118
|
+
return "<...>";
|
|
358
119
|
}
|
|
359
120
|
}
|
|
360
|
-
function
|
|
361
|
-
|
|
121
|
+
function u() {
|
|
122
|
+
var e = w.A;
|
|
123
|
+
return e === null ? null : e.getOwner();
|
|
362
124
|
}
|
|
363
|
-
function
|
|
364
|
-
|
|
365
|
-
return i("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", Ge(e)), Ce(e);
|
|
366
|
-
}
|
|
367
|
-
var U = D.ReactCurrentOwner, Ze = {
|
|
368
|
-
key: !0,
|
|
369
|
-
ref: !0,
|
|
370
|
-
__self: !0,
|
|
371
|
-
__source: !0
|
|
372
|
-
}, xe, Pe, se;
|
|
373
|
-
se = {};
|
|
374
|
-
function Qe(e) {
|
|
375
|
-
if (K.call(e, "ref")) {
|
|
376
|
-
var r = Object.getOwnPropertyDescriptor(e, "ref").get;
|
|
377
|
-
if (r && r.isReactWarning)
|
|
378
|
-
return !1;
|
|
379
|
-
}
|
|
380
|
-
return e.ref !== void 0;
|
|
125
|
+
function m() {
|
|
126
|
+
return Error("react-stack-top-frame");
|
|
381
127
|
}
|
|
382
|
-
function
|
|
383
|
-
if (
|
|
384
|
-
var
|
|
385
|
-
if (
|
|
386
|
-
return !1;
|
|
128
|
+
function g(e) {
|
|
129
|
+
if (V.call(e, "key")) {
|
|
130
|
+
var n = Object.getOwnPropertyDescriptor(e, "key").get;
|
|
131
|
+
if (n && n.isReactWarning) return !1;
|
|
387
132
|
}
|
|
388
133
|
return e.key !== void 0;
|
|
389
134
|
}
|
|
390
|
-
function
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
function tr(e, r) {
|
|
397
|
-
{
|
|
398
|
-
var t = function() {
|
|
399
|
-
xe || (xe = !0, i("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", r));
|
|
400
|
-
};
|
|
401
|
-
t.isReactWarning = !0, Object.defineProperty(e, "key", {
|
|
402
|
-
get: t,
|
|
403
|
-
configurable: !0
|
|
404
|
-
});
|
|
135
|
+
function E(e, n) {
|
|
136
|
+
function o() {
|
|
137
|
+
y || (y = !0, console.error(
|
|
138
|
+
"%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)",
|
|
139
|
+
n
|
|
140
|
+
));
|
|
405
141
|
}
|
|
142
|
+
o.isReactWarning = !0, Object.defineProperty(e, "key", {
|
|
143
|
+
get: o,
|
|
144
|
+
configurable: !0
|
|
145
|
+
});
|
|
406
146
|
}
|
|
407
|
-
function
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
t.isReactWarning = !0, Object.defineProperty(e, "ref", {
|
|
413
|
-
get: t,
|
|
414
|
-
configurable: !0
|
|
415
|
-
});
|
|
416
|
-
}
|
|
147
|
+
function N() {
|
|
148
|
+
var e = a(this.type);
|
|
149
|
+
return X[e] || (X[e] = !0, console.error(
|
|
150
|
+
"Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release."
|
|
151
|
+
)), e = this.props.ref, e !== void 0 ? e : null;
|
|
417
152
|
}
|
|
418
|
-
|
|
419
|
-
var
|
|
420
|
-
|
|
421
|
-
$$typeof:
|
|
422
|
-
// Built-in properties that belong on the element
|
|
153
|
+
function j(e, n, o, l, U, B) {
|
|
154
|
+
var f = o.ref;
|
|
155
|
+
return e = {
|
|
156
|
+
$$typeof: O,
|
|
423
157
|
type: e,
|
|
424
|
-
key:
|
|
425
|
-
ref: t,
|
|
158
|
+
key: n,
|
|
426
159
|
props: o,
|
|
427
|
-
// Record the component responsible for creating this element.
|
|
428
160
|
_owner: l
|
|
429
|
-
}
|
|
430
|
-
|
|
161
|
+
}, (f !== void 0 ? f : null) !== null ? Object.defineProperty(e, "ref", {
|
|
162
|
+
enumerable: !1,
|
|
163
|
+
get: N
|
|
164
|
+
}) : Object.defineProperty(e, "ref", { enumerable: !1, value: null }), e._store = {}, Object.defineProperty(e._store, "validated", {
|
|
431
165
|
configurable: !1,
|
|
432
166
|
enumerable: !1,
|
|
433
167
|
writable: !0,
|
|
434
|
-
value:
|
|
435
|
-
}), Object.defineProperty(
|
|
168
|
+
value: 0
|
|
169
|
+
}), Object.defineProperty(e, "_debugInfo", {
|
|
436
170
|
configurable: !1,
|
|
437
171
|
enumerable: !1,
|
|
438
|
-
writable: !
|
|
439
|
-
value:
|
|
440
|
-
}), Object.defineProperty(
|
|
172
|
+
writable: !0,
|
|
173
|
+
value: null
|
|
174
|
+
}), Object.defineProperty(e, "_debugStack", {
|
|
441
175
|
configurable: !1,
|
|
442
176
|
enumerable: !1,
|
|
443
|
-
writable: !
|
|
444
|
-
value:
|
|
445
|
-
}), Object.
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
}
|
|
473
|
-
var ce;
|
|
474
|
-
ce = !1;
|
|
475
|
-
function fe(e) {
|
|
476
|
-
return typeof e == "object" && e !== null && e.$$typeof === p;
|
|
477
|
-
}
|
|
478
|
-
function je() {
|
|
479
|
-
{
|
|
480
|
-
if (le.current) {
|
|
481
|
-
var e = _(le.current.type);
|
|
482
|
-
if (e)
|
|
483
|
-
return `
|
|
484
|
-
|
|
485
|
-
Check the render method of \`` + e + "`.";
|
|
486
|
-
}
|
|
487
|
-
return "";
|
|
488
|
-
}
|
|
489
|
-
}
|
|
490
|
-
function ir(e) {
|
|
491
|
-
return "";
|
|
492
|
-
}
|
|
493
|
-
var De = {};
|
|
494
|
-
function ur(e) {
|
|
495
|
-
{
|
|
496
|
-
var r = je();
|
|
497
|
-
if (!r) {
|
|
498
|
-
var t = typeof e == "string" ? e : e.displayName || e.name;
|
|
499
|
-
t && (r = `
|
|
500
|
-
|
|
501
|
-
Check the top-level render call using <` + t + ">.");
|
|
502
|
-
}
|
|
503
|
-
return r;
|
|
504
|
-
}
|
|
505
|
-
}
|
|
506
|
-
function Fe(e, r) {
|
|
507
|
-
{
|
|
508
|
-
if (!e._store || e._store.validated || e.key != null)
|
|
509
|
-
return;
|
|
510
|
-
e._store.validated = !0;
|
|
511
|
-
var t = ur(r);
|
|
512
|
-
if (De[t])
|
|
513
|
-
return;
|
|
514
|
-
De[t] = !0;
|
|
515
|
-
var n = "";
|
|
516
|
-
e && e._owner && e._owner !== le.current && (n = " It was passed a child from " + _(e._owner.type) + "."), M(e), i('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', t, n), M(null);
|
|
517
|
-
}
|
|
518
|
-
}
|
|
519
|
-
function Ae(e, r) {
|
|
520
|
-
{
|
|
521
|
-
if (typeof e != "object")
|
|
522
|
-
return;
|
|
523
|
-
if (ue(e))
|
|
524
|
-
for (var t = 0; t < e.length; t++) {
|
|
525
|
-
var n = e[t];
|
|
526
|
-
fe(n) && Fe(n, r);
|
|
527
|
-
}
|
|
528
|
-
else if (fe(e))
|
|
529
|
-
e._store && (e._store.validated = !0);
|
|
530
|
-
else if (e) {
|
|
531
|
-
var s = V(e);
|
|
532
|
-
if (typeof s == "function" && s !== e.entries)
|
|
533
|
-
for (var l = s.call(e), o; !(o = l.next()).done; )
|
|
534
|
-
fe(o.value) && Fe(o.value, r);
|
|
535
|
-
}
|
|
536
|
-
}
|
|
537
|
-
}
|
|
538
|
-
function sr(e) {
|
|
539
|
-
{
|
|
540
|
-
var r = e.type;
|
|
541
|
-
if (r == null || typeof r == "string")
|
|
542
|
-
return;
|
|
543
|
-
var t;
|
|
544
|
-
if (typeof r == "function")
|
|
545
|
-
t = r.propTypes;
|
|
546
|
-
else if (typeof r == "object" && (r.$$typeof === d || // Note: Memo only checks outer props here.
|
|
547
|
-
// Inner props are checked in the reconciler.
|
|
548
|
-
r.$$typeof === T))
|
|
549
|
-
t = r.propTypes;
|
|
550
|
-
else
|
|
551
|
-
return;
|
|
552
|
-
if (t) {
|
|
553
|
-
var n = _(r);
|
|
554
|
-
Xe(t, e.props, "prop", n, e);
|
|
555
|
-
} else if (r.PropTypes !== void 0 && !ce) {
|
|
556
|
-
ce = !0;
|
|
557
|
-
var s = _(r);
|
|
558
|
-
i("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", s || "Unknown");
|
|
559
|
-
}
|
|
560
|
-
typeof r.getDefaultProps == "function" && !r.getDefaultProps.isReactClassApproved && i("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
|
|
561
|
-
}
|
|
562
|
-
}
|
|
563
|
-
function lr(e) {
|
|
564
|
-
{
|
|
565
|
-
for (var r = Object.keys(e.props), t = 0; t < r.length; t++) {
|
|
566
|
-
var n = r[t];
|
|
567
|
-
if (n !== "children" && n !== "key") {
|
|
568
|
-
M(e), i("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", n), M(null);
|
|
569
|
-
break;
|
|
570
|
-
}
|
|
571
|
-
}
|
|
572
|
-
e.ref !== null && (M(e), i("Invalid attribute `ref` supplied to `React.Fragment`."), M(null));
|
|
573
|
-
}
|
|
574
|
-
}
|
|
575
|
-
var Ve = {};
|
|
576
|
-
function Ie(e, r, t, n, s, l) {
|
|
577
|
-
{
|
|
578
|
-
var o = X(e);
|
|
579
|
-
if (!o) {
|
|
580
|
-
var a = "";
|
|
581
|
-
(e === void 0 || typeof e == "object" && e !== null && Object.keys(e).length === 0) && (a += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
|
|
582
|
-
var E = ir();
|
|
583
|
-
E ? a += E : a += je();
|
|
584
|
-
var f;
|
|
585
|
-
e === null ? f = "null" : ue(e) ? f = "array" : e !== void 0 && e.$$typeof === p ? (f = "<" + (_(e.type) || "Unknown") + " />", a = " Did you accidentally export a JSX literal instead of a component?") : f = typeof e, i("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", f, a);
|
|
586
|
-
}
|
|
587
|
-
var v = or(e, r, t, s, l);
|
|
588
|
-
if (v == null)
|
|
589
|
-
return v;
|
|
590
|
-
if (o) {
|
|
591
|
-
var x = r.children;
|
|
592
|
-
if (x !== void 0)
|
|
593
|
-
if (n)
|
|
594
|
-
if (ue(x)) {
|
|
595
|
-
for (var L = 0; L < x.length; L++)
|
|
596
|
-
Ae(x[L], e);
|
|
597
|
-
Object.freeze && Object.freeze(x);
|
|
598
|
-
} else
|
|
599
|
-
i("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");
|
|
600
|
-
else
|
|
601
|
-
Ae(x, e);
|
|
602
|
-
}
|
|
603
|
-
if (K.call(r, "key")) {
|
|
604
|
-
var A = _(e), w = Object.keys(r).filter(function(yr) {
|
|
605
|
-
return yr !== "key";
|
|
606
|
-
}), de = w.length > 0 ? "{key: someKey, " + w.join(": ..., ") + ": ...}" : "{key: someKey}";
|
|
607
|
-
if (!Ve[A + de]) {
|
|
608
|
-
var mr = w.length > 0 ? "{" + w.join(": ..., ") + ": ...}" : "{}";
|
|
609
|
-
i(`A props object containing a "key" prop is being spread into JSX:
|
|
177
|
+
writable: !0,
|
|
178
|
+
value: U
|
|
179
|
+
}), Object.defineProperty(e, "_debugTask", {
|
|
180
|
+
configurable: !1,
|
|
181
|
+
enumerable: !1,
|
|
182
|
+
writable: !0,
|
|
183
|
+
value: B
|
|
184
|
+
}), Object.freeze && (Object.freeze(e.props), Object.freeze(e)), e;
|
|
185
|
+
}
|
|
186
|
+
function b(e, n, o, l, U, B) {
|
|
187
|
+
var f = n.children;
|
|
188
|
+
if (f !== void 0)
|
|
189
|
+
if (l)
|
|
190
|
+
if (t(f)) {
|
|
191
|
+
for (l = 0; l < f.length; l++)
|
|
192
|
+
_(f[l]);
|
|
193
|
+
Object.freeze && Object.freeze(f);
|
|
194
|
+
} else
|
|
195
|
+
console.error(
|
|
196
|
+
"React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead."
|
|
197
|
+
);
|
|
198
|
+
else _(f);
|
|
199
|
+
if (V.call(n, "key")) {
|
|
200
|
+
f = a(e);
|
|
201
|
+
var M = Object.keys(n).filter(function(ue) {
|
|
202
|
+
return ue !== "key";
|
|
203
|
+
});
|
|
204
|
+
l = 0 < M.length ? "{key: someKey, " + M.join(": ..., ") + ": ...}" : "{key: someKey}", $[f + l] || (M = 0 < M.length ? "{" + M.join(": ..., ") + ": ...}" : "{}", console.error(
|
|
205
|
+
`A props object containing a "key" prop is being spread into JSX:
|
|
610
206
|
let props = %s;
|
|
611
207
|
<%s {...props} />
|
|
612
208
|
React keys must be passed directly to JSX without using spread:
|
|
613
209
|
let props = %s;
|
|
614
|
-
<%s key={someKey} {...props} />`,
|
|
615
|
-
|
|
616
|
-
|
|
617
|
-
|
|
210
|
+
<%s key={someKey} {...props} />`,
|
|
211
|
+
l,
|
|
212
|
+
f,
|
|
213
|
+
M,
|
|
214
|
+
f
|
|
215
|
+
), $[f + l] = !0);
|
|
618
216
|
}
|
|
217
|
+
if (f = null, o !== void 0 && (R(o), f = "" + o), g(n) && (R(n.key), f = "" + n.key), "key" in n) {
|
|
218
|
+
o = {};
|
|
219
|
+
for (var K in n)
|
|
220
|
+
K !== "key" && (o[K] = n[K]);
|
|
221
|
+
} else o = n;
|
|
222
|
+
return f && E(
|
|
223
|
+
o,
|
|
224
|
+
typeof e == "function" ? e.displayName || e.name || "Unknown" : e
|
|
225
|
+
), j(
|
|
226
|
+
e,
|
|
227
|
+
f,
|
|
228
|
+
o,
|
|
229
|
+
u(),
|
|
230
|
+
U,
|
|
231
|
+
B
|
|
232
|
+
);
|
|
619
233
|
}
|
|
620
|
-
function
|
|
621
|
-
|
|
234
|
+
function _(e) {
|
|
235
|
+
S(e) ? e._store && (e._store.validated = 1) : typeof e == "object" && e !== null && e.$$typeof === k && (e._payload.status === "fulfilled" ? S(e._payload.value) && e._payload.value._store && (e._payload.value._store.validated = 1) : e._store && (e._store.validated = 1));
|
|
622
236
|
}
|
|
623
|
-
function
|
|
624
|
-
return
|
|
237
|
+
function S(e) {
|
|
238
|
+
return typeof e == "object" && e !== null && e.$$typeof === O;
|
|
625
239
|
}
|
|
626
|
-
var
|
|
627
|
-
|
|
628
|
-
|
|
240
|
+
var T = ie, O = Symbol.for("react.transitional.element"), I = Symbol.for("react.portal"), A = Symbol.for("react.fragment"), P = Symbol.for("react.strict_mode"), C = Symbol.for("react.profiler"), Y = Symbol.for("react.consumer"), F = Symbol.for("react.context"), s = Symbol.for("react.forward_ref"), c = Symbol.for("react.suspense"), p = Symbol.for("react.suspense_list"), i = Symbol.for("react.memo"), k = Symbol.for("react.lazy"), h = Symbol.for("react.activity"), x = Symbol.for("react.client.reference"), w = T.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, V = Object.prototype.hasOwnProperty, t = Array.isArray, r = console.createTask ? console.createTask : function() {
|
|
241
|
+
return null;
|
|
242
|
+
};
|
|
243
|
+
T = {
|
|
244
|
+
react_stack_bottom_frame: function(e) {
|
|
245
|
+
return e();
|
|
246
|
+
}
|
|
247
|
+
};
|
|
248
|
+
var y, X = {}, z = T.react_stack_bottom_frame.bind(
|
|
249
|
+
T,
|
|
250
|
+
m
|
|
251
|
+
)(), W = r(v(m)), $ = {};
|
|
252
|
+
L.Fragment = A, L.jsx = function(e, n, o) {
|
|
253
|
+
var l = 1e4 > w.recentlyCreatedOwnerStacks++;
|
|
254
|
+
return b(
|
|
255
|
+
e,
|
|
256
|
+
n,
|
|
257
|
+
o,
|
|
258
|
+
!1,
|
|
259
|
+
l ? Error("react-stack-top-frame") : z,
|
|
260
|
+
l ? r(v(e)) : W
|
|
261
|
+
);
|
|
262
|
+
}, L.jsxs = function(e, n, o) {
|
|
263
|
+
var l = 1e4 > w.recentlyCreatedOwnerStacks++;
|
|
264
|
+
return b(
|
|
265
|
+
e,
|
|
266
|
+
n,
|
|
267
|
+
o,
|
|
268
|
+
!0,
|
|
269
|
+
l ? Error("react-stack-top-frame") : z,
|
|
270
|
+
l ? r(v(e)) : W
|
|
271
|
+
);
|
|
272
|
+
};
|
|
273
|
+
})()), L;
|
|
629
274
|
}
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
|
|
633
|
-
let g = "";
|
|
634
|
-
return function(k) {
|
|
635
|
-
const u = /^-?\d*([.,]?)\d*$/, C = k.match(u);
|
|
636
|
-
return C && (g = C[0]), g;
|
|
637
|
-
};
|
|
275
|
+
var ne;
|
|
276
|
+
function be() {
|
|
277
|
+
return ne || (ne = 1, process.env.NODE_ENV === "production" ? q.exports = de() : q.exports = me()), q.exports;
|
|
638
278
|
}
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
650
|
-
|
|
651
|
-
|
|
652
|
-
|
|
653
|
-
|
|
654
|
-
|
|
655
|
-
|
|
656
|
-
|
|
657
|
-
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
|
|
664
|
-
|
|
665
|
-
|
|
666
|
-
|
|
279
|
+
var oe = be();
|
|
280
|
+
const Ee = /^-?\d*[.,]?\d*$/, ae = (a, d) => Ee.test(a) ? a : d, Q = (a) => {
|
|
281
|
+
const d = a.toString().split(".");
|
|
282
|
+
return d.length > 1 ? d[1].length : 0;
|
|
283
|
+
}, ce = (a) => a.replace(",", "."), ee = (a) => parseFloat(ce(a)), G = (a) => Number.isFinite(a) ? String(a) : "", ve = (a) => G(ee(a)), H = (a, d) => {
|
|
284
|
+
var v;
|
|
285
|
+
if (a.value === d) return;
|
|
286
|
+
const R = (v = Object.getOwnPropertyDescriptor(
|
|
287
|
+
HTMLInputElement.prototype,
|
|
288
|
+
"value"
|
|
289
|
+
)) == null ? void 0 : v.set;
|
|
290
|
+
R ? R.call(a, d) : a.value = d, a.dispatchEvent(new Event("input", { bubbles: !0 })), R && (a.value = a.value);
|
|
291
|
+
}, Re = le(
|
|
292
|
+
({
|
|
293
|
+
defaultValue: a,
|
|
294
|
+
mask: d = ae,
|
|
295
|
+
onBlur: R,
|
|
296
|
+
onChange: v,
|
|
297
|
+
onFocus: u,
|
|
298
|
+
onKeyDown: m,
|
|
299
|
+
step: g = 1,
|
|
300
|
+
value: E,
|
|
301
|
+
...N
|
|
302
|
+
}, j) => {
|
|
303
|
+
const b = J(null);
|
|
304
|
+
fe(
|
|
305
|
+
j,
|
|
306
|
+
() => b.current
|
|
307
|
+
);
|
|
308
|
+
const [_, S] = Z(
|
|
309
|
+
E ?? (a != null ? String(a) : "")
|
|
310
|
+
), T = J(_);
|
|
311
|
+
T.current = _;
|
|
312
|
+
const O = J(!1), I = d === ae;
|
|
313
|
+
se(() => {
|
|
314
|
+
E === void 0 || O.current || S(E);
|
|
315
|
+
}, [E]);
|
|
316
|
+
const A = (s) => {
|
|
317
|
+
const c = s.target, p = c.value, i = d(p, T.current);
|
|
318
|
+
if (i !== p) {
|
|
319
|
+
const h = c.selectionStart ?? p.length, x = Math.min(
|
|
320
|
+
i.length,
|
|
321
|
+
Math.max(0, h - (p.length - i.length))
|
|
322
|
+
);
|
|
323
|
+
c.value = i, c.setSelectionRange(x, x);
|
|
324
|
+
return;
|
|
667
325
|
}
|
|
668
|
-
|
|
669
|
-
|
|
326
|
+
if (T.current = i, S(i), !v) return;
|
|
327
|
+
const k = ce(i);
|
|
328
|
+
if (k !== i) {
|
|
329
|
+
const h = c.selectionStart ?? i.length, x = c.selectionEnd ?? i.length;
|
|
330
|
+
c.value = k, v(s), c.value = i, c.setSelectionRange(h, x);
|
|
331
|
+
} else
|
|
332
|
+
v(s);
|
|
333
|
+
}, P = (s) => {
|
|
334
|
+
const c = b.current;
|
|
335
|
+
if (!c) return;
|
|
336
|
+
const p = ee(T.current), i = Number(g) || 1, k = Q(i);
|
|
337
|
+
let h = (Number.isFinite(p) ? p : 0) + s * i;
|
|
338
|
+
const x = N.min !== void 0 ? Number(N.min) : NaN, w = N.max !== void 0 ? Number(N.max) : NaN;
|
|
339
|
+
Number.isNaN(x) || (h = Math.max(h, x)), Number.isNaN(w) || (h = Math.min(h, w)), H(c, h.toFixed(k));
|
|
340
|
+
}, C = (s) => {
|
|
341
|
+
m == null || m(s), !s.defaultPrevented && (s.key === "ArrowUp" ? (s.preventDefault(), P(1)) : s.key === "ArrowDown" && (s.preventDefault(), P(-1)));
|
|
342
|
+
}, Y = (s) => {
|
|
343
|
+
O.current = !0, u == null || u(s);
|
|
344
|
+
}, F = (s) => {
|
|
345
|
+
O.current = !1;
|
|
346
|
+
const c = T.current, p = I ? ve(c) : c;
|
|
347
|
+
p !== c ? H(s.target, p) : E !== void 0 && E !== c && S(E), R == null || R(s);
|
|
670
348
|
};
|
|
671
|
-
return
|
|
672
|
-
h(u || "");
|
|
673
|
-
}, [u]), /* @__PURE__ */ Ye.jsx(
|
|
349
|
+
return /* @__PURE__ */ oe.jsx(
|
|
674
350
|
"input",
|
|
675
351
|
{
|
|
676
|
-
|
|
352
|
+
inputMode: "decimal",
|
|
353
|
+
...N,
|
|
677
354
|
type: "text",
|
|
678
|
-
ref:
|
|
679
|
-
value:
|
|
680
|
-
|
|
681
|
-
|
|
355
|
+
ref: b,
|
|
356
|
+
value: _,
|
|
357
|
+
onBlur: F,
|
|
358
|
+
onChange: A,
|
|
359
|
+
onFocus: Y,
|
|
360
|
+
onKeyDown: C
|
|
682
361
|
}
|
|
683
362
|
);
|
|
684
363
|
}
|
|
685
|
-
)
|
|
686
|
-
|
|
687
|
-
|
|
688
|
-
|
|
364
|
+
), _e = [
|
|
365
|
+
"metaKey",
|
|
366
|
+
"ctrlKey",
|
|
367
|
+
"altKey",
|
|
368
|
+
"shiftKey"
|
|
369
|
+
], pe = 3;
|
|
370
|
+
function he({
|
|
371
|
+
value: a,
|
|
372
|
+
modifiers: d = {
|
|
689
373
|
altKey: 1,
|
|
690
374
|
ctrlKey: 1,
|
|
691
375
|
metaKey: 1,
|
|
692
376
|
shiftKey: 0.1
|
|
693
377
|
},
|
|
694
|
-
style:
|
|
695
|
-
|
|
378
|
+
style: R = {},
|
|
379
|
+
onBlur: v,
|
|
380
|
+
onFocus: u,
|
|
381
|
+
onKeyDown: m,
|
|
382
|
+
onPointerCancel: g,
|
|
383
|
+
onPointerDown: E,
|
|
384
|
+
onPointerMove: N,
|
|
385
|
+
onPointerUp: j,
|
|
386
|
+
...b
|
|
696
387
|
}) {
|
|
697
|
-
const
|
|
698
|
-
|
|
699
|
-
|
|
700
|
-
|
|
701
|
-
|
|
702
|
-
|
|
703
|
-
|
|
704
|
-
|
|
705
|
-
|
|
706
|
-
const z = m * X, G = Ke(z);
|
|
707
|
-
let _ = Math.sqrt(J * J + Y * Y) * z;
|
|
708
|
-
$ < B && (_ = -_);
|
|
709
|
-
let y = P.current + _;
|
|
710
|
-
if (u.min && (y = Math.max(y, +u.min)), u.max && (y = Math.min(y, +u.max)), y = +y.toFixed(G), y && j(String(y)), y && u.onChange) {
|
|
711
|
-
const H = {
|
|
712
|
-
...new Event("change", { bubbles: !0 }),
|
|
713
|
-
target: {
|
|
714
|
-
...i.target,
|
|
715
|
-
value: y
|
|
716
|
-
}
|
|
717
|
-
};
|
|
718
|
-
u.onChange(
|
|
719
|
-
H
|
|
720
|
-
);
|
|
721
|
-
}
|
|
722
|
-
return R;
|
|
723
|
-
});
|
|
724
|
-
},
|
|
725
|
-
[O, u.max, u.min, m, p]
|
|
726
|
-
), S = ve(() => {
|
|
727
|
-
document.removeEventListener("mousemove", b), document.removeEventListener("mouseup", S);
|
|
728
|
-
}, [b]), F = ve(
|
|
729
|
-
(i) => {
|
|
730
|
-
let R = +C;
|
|
731
|
-
isNaN(R) && (R = +(u.defaultValue || u.min || 0)), P.current = R, d([i.clientX, i.clientY]), document.addEventListener("mousemove", b), document.addEventListener("mouseup", S);
|
|
388
|
+
const _ = J(null), [S, T] = Z(!1), [O, I] = Z(!1), A = b.step ? +b.step : 1, P = b.min !== void 0 ? +b.min : void 0, C = b.max !== void 0 ? +b.max : void 0, Y = {
|
|
389
|
+
cursor: S && !O ? void 0 : "ew-resize",
|
|
390
|
+
touchAction: "none",
|
|
391
|
+
...R
|
|
392
|
+
};
|
|
393
|
+
se(
|
|
394
|
+
() => () => {
|
|
395
|
+
const t = _.current;
|
|
396
|
+
t != null && t.scrubbing && (document.body.style.cursor = t.previousBodyCursor);
|
|
732
397
|
},
|
|
733
|
-
[
|
|
734
|
-
)
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
|
|
398
|
+
[]
|
|
399
|
+
);
|
|
400
|
+
const F = (t) => {
|
|
401
|
+
for (const r of _e)
|
|
402
|
+
if (t[r]) return d[r] ?? 1;
|
|
403
|
+
return 1;
|
|
404
|
+
}, s = (t, r, y) => {
|
|
405
|
+
if (_.current = null, !!r.scrubbing) {
|
|
406
|
+
I(!1), document.body.style.cursor = r.previousBodyCursor;
|
|
407
|
+
try {
|
|
408
|
+
t.releasePointerCapture(r.pointerId);
|
|
409
|
+
} catch {
|
|
410
|
+
}
|
|
411
|
+
y && H(t, G(r.startValue)), t.blur();
|
|
412
|
+
}
|
|
413
|
+
}, c = (t) => {
|
|
414
|
+
if (E == null || E(t), t.defaultPrevented || t.button !== 0 || b.disabled || b.readOnly) return;
|
|
415
|
+
const r = t.currentTarget;
|
|
416
|
+
if (document.activeElement === r) return;
|
|
417
|
+
let y = ee(r.value);
|
|
418
|
+
Number.isFinite(y) || (y = Number(b.defaultValue ?? P ?? 0) || 0), _.current = {
|
|
419
|
+
pointerId: t.pointerId,
|
|
420
|
+
startX: t.clientX,
|
|
421
|
+
lastX: t.clientX,
|
|
422
|
+
startValue: y,
|
|
423
|
+
accumulated: y,
|
|
424
|
+
scrubbing: !1,
|
|
425
|
+
previousBodyCursor: ""
|
|
426
|
+
};
|
|
427
|
+
}, p = (t) => {
|
|
428
|
+
N == null || N(t);
|
|
429
|
+
const r = _.current;
|
|
430
|
+
if (!r || r.pointerId !== t.pointerId) return;
|
|
431
|
+
const y = t.currentTarget;
|
|
432
|
+
if (t.buttons === 0) {
|
|
433
|
+
_.current = null;
|
|
434
|
+
return;
|
|
435
|
+
}
|
|
436
|
+
if (!r.scrubbing) {
|
|
437
|
+
if (Math.abs(t.clientX - r.startX) < pe) return;
|
|
438
|
+
r.scrubbing = !0, r.lastX = t.clientX, I(!0), r.previousBodyCursor = document.body.style.cursor, document.body.style.cursor = "ew-resize";
|
|
439
|
+
try {
|
|
440
|
+
y.setPointerCapture(t.pointerId);
|
|
441
|
+
} catch {
|
|
442
|
+
}
|
|
443
|
+
}
|
|
444
|
+
const X = F(t), z = A * X, W = Q(A) + Q(X);
|
|
445
|
+
r.accumulated += (t.clientX - r.lastX) * z, r.lastX = t.clientX, P !== void 0 && (r.accumulated = Math.max(r.accumulated, P)), C !== void 0 && (r.accumulated = Math.min(r.accumulated, C));
|
|
446
|
+
const $ = +r.accumulated.toFixed(W);
|
|
447
|
+
Number.isNaN($) || H(y, G($));
|
|
448
|
+
}, i = (t) => {
|
|
449
|
+
const r = _.current;
|
|
450
|
+
!r || r.pointerId !== t.pointerId || s(t.currentTarget, r, !1);
|
|
451
|
+
}, k = (t) => {
|
|
452
|
+
j == null || j(t), i(t);
|
|
453
|
+
}, h = (t) => {
|
|
454
|
+
g == null || g(t), i(t);
|
|
455
|
+
}, x = (t) => {
|
|
456
|
+
const r = _.current;
|
|
457
|
+
if (t.key === "Escape" && (r != null && r.scrubbing)) {
|
|
458
|
+
t.preventDefault(), s(t.currentTarget, r, !0);
|
|
459
|
+
return;
|
|
460
|
+
}
|
|
461
|
+
m == null || m(t);
|
|
462
|
+
}, w = (t) => {
|
|
463
|
+
T(!0), u == null || u(t);
|
|
464
|
+
}, V = (t) => {
|
|
465
|
+
T(!1), v == null || v(t);
|
|
738
466
|
};
|
|
739
|
-
return
|
|
740
|
-
|
|
741
|
-
}, [g]), me(() => (document.addEventListener("keydown", V), document.addEventListener("keyup", D), () => {
|
|
742
|
-
document.removeEventListener("mousemove", b), document.removeEventListener("mouseup", S), document.removeEventListener("keydown", V), document.removeEventListener("keyup", D);
|
|
743
|
-
}), []), /* @__PURE__ */ Ye.jsx(
|
|
744
|
-
Rr,
|
|
467
|
+
return /* @__PURE__ */ oe.jsx(
|
|
468
|
+
Re,
|
|
745
469
|
{
|
|
746
|
-
...
|
|
747
|
-
|
|
748
|
-
|
|
749
|
-
|
|
750
|
-
|
|
470
|
+
...b,
|
|
471
|
+
defaultValue: b.defaultValue ?? 0,
|
|
472
|
+
style: Y,
|
|
473
|
+
value: a !== void 0 ? G(a) : void 0,
|
|
474
|
+
onBlur: V,
|
|
475
|
+
onFocus: w,
|
|
476
|
+
onKeyDown: x,
|
|
477
|
+
onPointerCancel: h,
|
|
478
|
+
onPointerDown: c,
|
|
479
|
+
onPointerMove: p,
|
|
480
|
+
onPointerUp: k
|
|
751
481
|
}
|
|
752
482
|
);
|
|
753
483
|
}
|
|
754
484
|
export {
|
|
755
|
-
|
|
756
|
-
|
|
485
|
+
he as InteractiveInput,
|
|
486
|
+
Re as MaskedInput
|
|
757
487
|
};
|