@arkyn/components 1.2.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.
Files changed (151) hide show
  1. package/dist/bundle.js +1348 -0
  2. package/dist/bundle.umd.cjs +32 -0
  3. package/dist/components/Badge/index.d.ts +5 -0
  4. package/dist/components/Badge/index.d.ts.map +1 -0
  5. package/dist/components/Badge/index.js +8 -0
  6. package/dist/components/Breadcrumb/index.d.ts +6 -0
  7. package/dist/components/Breadcrumb/index.d.ts.map +1 -0
  8. package/dist/components/Breadcrumb/index.js +18 -0
  9. package/dist/components/Button/index.d.ts +5 -0
  10. package/dist/components/Button/index.d.ts.map +1 -0
  11. package/dist/components/Button/index.js +9 -0
  12. package/dist/components/Divider/index.d.ts +5 -0
  13. package/dist/components/Divider/index.d.ts.map +1 -0
  14. package/dist/components/Divider/index.js +8 -0
  15. package/dist/components/Form/FormController/index.d.ts +6 -0
  16. package/dist/components/Form/FormController/index.d.ts.map +1 -0
  17. package/dist/components/Form/FormController/index.js +17 -0
  18. package/dist/components/Form/FormError/index.d.ts +4 -0
  19. package/dist/components/Form/FormError/index.d.ts.map +1 -0
  20. package/dist/components/Form/FormError/index.js +10 -0
  21. package/dist/components/Form/FormLabel/index.d.ts +5 -0
  22. package/dist/components/Form/FormLabel/index.d.ts.map +1 -0
  23. package/dist/components/Form/FormLabel/index.js +9 -0
  24. package/dist/components/Form/index.d.ts +4 -0
  25. package/dist/components/Form/index.d.ts.map +1 -0
  26. package/dist/components/Form/index.js +3 -0
  27. package/dist/components/IconButton/index.d.ts +5 -0
  28. package/dist/components/IconButton/index.d.ts.map +1 -0
  29. package/dist/components/IconButton/index.js +15 -0
  30. package/dist/components/Input/CpfCpnjInput/getConfig.d.ts +308 -0
  31. package/dist/components/Input/CpfCpnjInput/getConfig.d.ts.map +1 -0
  32. package/dist/components/Input/CpfCpnjInput/getConfig.js +35 -0
  33. package/dist/components/Input/CpfCpnjInput/index.d.ts +4 -0
  34. package/dist/components/Input/CpfCpnjInput/index.d.ts.map +1 -0
  35. package/dist/components/Input/CpfCpnjInput/index.js +47 -0
  36. package/dist/components/Input/CpfCpnjInput/utils.d.ts +10 -0
  37. package/dist/components/Input/CpfCpnjInput/utils.d.ts.map +1 -0
  38. package/dist/components/Input/CpfCpnjInput/utils.js +24 -0
  39. package/dist/components/Input/CurrencyInput/getConfig.d.ts +309 -0
  40. package/dist/components/Input/CurrencyInput/getConfig.d.ts.map +1 -0
  41. package/dist/components/Input/CurrencyInput/getConfig.js +37 -0
  42. package/dist/components/Input/CurrencyInput/index.d.ts +4 -0
  43. package/dist/components/Input/CurrencyInput/index.d.ts.map +1 -0
  44. package/dist/components/Input/CurrencyInput/index.js +41 -0
  45. package/dist/components/Input/CurrencyInput/utils.d.ts +11 -0
  46. package/dist/components/Input/CurrencyInput/utils.d.ts.map +1 -0
  47. package/dist/components/Input/CurrencyInput/utils.js +39 -0
  48. package/dist/components/Input/MaskInput/getConfig.d.ts +312 -0
  49. package/dist/components/Input/MaskInput/getConfig.d.ts.map +1 -0
  50. package/dist/components/Input/MaskInput/getConfig.js +36 -0
  51. package/dist/components/Input/MaskInput/index.d.ts +4 -0
  52. package/dist/components/Input/MaskInput/index.d.ts.map +1 -0
  53. package/dist/components/Input/MaskInput/index.js +42 -0
  54. package/dist/components/Input/SimpleInput/getConfig.d.ts +308 -0
  55. package/dist/components/Input/SimpleInput/getConfig.d.ts.map +1 -0
  56. package/dist/components/Input/SimpleInput/getConfig.js +35 -0
  57. package/dist/components/Input/SimpleInput/index.d.ts +4 -0
  58. package/dist/components/Input/SimpleInput/index.d.ts.map +1 -0
  59. package/dist/components/Input/SimpleInput/index.js +34 -0
  60. package/dist/components/Input/index.d.ts +5 -0
  61. package/dist/components/Input/index.d.ts.map +1 -0
  62. package/dist/components/Input/index.js +16 -0
  63. package/dist/components/Input/utils/morpheme.d.ts +4 -0
  64. package/dist/components/Input/utils/morpheme.d.ts.map +1 -0
  65. package/dist/components/Input/utils/morpheme.js +10 -0
  66. package/dist/components/Modal/Container/index.d.ts +10 -0
  67. package/dist/components/Modal/Container/index.d.ts.map +1 -0
  68. package/dist/components/Modal/Container/index.js +12 -0
  69. package/dist/components/Modal/Footer/index.d.ts +5 -0
  70. package/dist/components/Modal/Footer/index.d.ts.map +1 -0
  71. package/dist/components/Modal/Footer/index.js +8 -0
  72. package/dist/components/Modal/Header/index.d.ts +5 -0
  73. package/dist/components/Modal/Header/index.d.ts.map +1 -0
  74. package/dist/components/Modal/Header/index.js +13 -0
  75. package/dist/components/Modal/index.d.ts +9 -0
  76. package/dist/components/Modal/index.d.ts.map +1 -0
  77. package/dist/components/Modal/index.js +4 -0
  78. package/dist/components/Tooltip/index.d.ts +5 -0
  79. package/dist/components/Tooltip/index.d.ts.map +1 -0
  80. package/dist/components/Tooltip/index.js +7 -0
  81. package/dist/config/buildBadgeConfig.d.ts +274 -0
  82. package/dist/config/buildBadgeConfig.d.ts.map +1 -0
  83. package/dist/config/buildBadgeConfig.js +15 -0
  84. package/dist/config/buildBreadcrumLinkConfig.d.ts +288 -0
  85. package/dist/config/buildBreadcrumLinkConfig.d.ts.map +1 -0
  86. package/dist/config/buildBreadcrumLinkConfig.js +14 -0
  87. package/dist/config/buildBreadcrumbConfig.d.ts +272 -0
  88. package/dist/config/buildBreadcrumbConfig.d.ts.map +1 -0
  89. package/dist/config/buildBreadcrumbConfig.js +6 -0
  90. package/dist/config/buildButtonConfig.d.ts +286 -0
  91. package/dist/config/buildButtonConfig.d.ts.map +1 -0
  92. package/dist/config/buildButtonConfig.js +18 -0
  93. package/dist/config/buildFormLabelConfig.d.ts +274 -0
  94. package/dist/config/buildFormLabelConfig.d.ts.map +1 -0
  95. package/dist/config/buildFormLabelConfig.js +10 -0
  96. package/dist/index.d.ts +10 -0
  97. package/dist/index.d.ts.map +1 -0
  98. package/dist/index.js +13 -0
  99. package/dist/style.css +1 -0
  100. package/dist/utils/generateIcon.d.ts +4 -0
  101. package/dist/utils/generateIcon.d.ts.map +1 -0
  102. package/dist/utils/generateIcon.js +7 -0
  103. package/package.json +30 -0
  104. package/src/components/Badge/index.tsx +18 -0
  105. package/src/components/Badge/styles.css +119 -0
  106. package/src/components/Breadcrumb/index.tsx +35 -0
  107. package/src/components/Breadcrumb/styles.css +39 -0
  108. package/src/components/Button/index.tsx +27 -0
  109. package/src/components/Button/styles.css +363 -0
  110. package/src/components/Divider/index.tsx +17 -0
  111. package/src/components/Divider/styles.css +17 -0
  112. package/src/components/Form/FormController/index.tsx +36 -0
  113. package/src/components/Form/FormController/styles.css +5 -0
  114. package/src/components/Form/FormError/index.tsx +11 -0
  115. package/src/components/Form/FormError/styles.css +6 -0
  116. package/src/components/Form/FormLabel/index.tsx +13 -0
  117. package/src/components/Form/FormLabel/styles.css +15 -0
  118. package/src/components/Form/index.ts +3 -0
  119. package/src/components/IconButton/index.tsx +44 -0
  120. package/src/components/IconButton/styles.css +318 -0
  121. package/src/components/Input/CpfCpnjInput/getConfig.tsx +60 -0
  122. package/src/components/Input/CpfCpnjInput/index.tsx +112 -0
  123. package/src/components/Input/CpfCpnjInput/utils.ts +30 -0
  124. package/src/components/Input/CurrencyInput/getConfig.tsx +64 -0
  125. package/src/components/Input/CurrencyInput/index.tsx +103 -0
  126. package/src/components/Input/CurrencyInput/utils.ts +56 -0
  127. package/src/components/Input/MaskInput/getConfig.tsx +62 -0
  128. package/src/components/Input/MaskInput/index.tsx +89 -0
  129. package/src/components/Input/SimpleInput/getConfig.tsx +60 -0
  130. package/src/components/Input/SimpleInput/index.tsx +87 -0
  131. package/src/components/Input/index.tsx +17 -0
  132. package/src/components/Input/styles.css +223 -0
  133. package/src/components/Input/utils/morpheme.tsx +19 -0
  134. package/src/components/Modal/Container/index.tsx +53 -0
  135. package/src/components/Modal/Container/styles.css +35 -0
  136. package/src/components/Modal/Footer/index.tsx +12 -0
  137. package/src/components/Modal/Footer/styles.css +27 -0
  138. package/src/components/Modal/Header/index.tsx +26 -0
  139. package/src/components/Modal/Header/styles.css +36 -0
  140. package/src/components/Modal/index.ts +5 -0
  141. package/src/components/Tooltip/index.tsx +26 -0
  142. package/src/components/Tooltip/styles.css +112 -0
  143. package/src/config/buildBadgeConfig.tsx +32 -0
  144. package/src/config/buildBreadcrumLinkConfig.tsx +27 -0
  145. package/src/config/buildBreadcrumbConfig.tsx +12 -0
  146. package/src/config/buildButtonConfig.tsx +38 -0
  147. package/src/config/buildFormLabelConfig.tsx +17 -0
  148. package/src/index.ts +16 -0
  149. package/src/utils/generateIcon.tsx +9 -0
  150. package/tsconfig.json +23 -0
  151. package/vite.config.js +25 -0
package/dist/bundle.js ADDED
@@ -0,0 +1,1348 @@
1
+ import Xe, { createContext as He, useRef as de, useId as kr, useContext as Ze, useState as ie } from "react";
2
+ import { Loader2 as oe, ChevronRight as Me, X as Nr } from "lucide-react";
3
+ import { useActionData as $r, useLocation as Pr, Link as Ir } from "@remix-run/react";
4
+ import { InputMask as wr } from "@react-input/mask";
5
+ import { AnimatePresence as Tr, motion as Ue } from "framer-motion";
6
+ var ke = { exports: {} }, le = {};
7
+ /**
8
+ * @license React
9
+ * react-jsx-runtime.production.min.js
10
+ *
11
+ * Copyright (c) Facebook, Inc. and its affiliates.
12
+ *
13
+ * This source code is licensed under the MIT license found in the
14
+ * LICENSE file in the root directory of this source tree.
15
+ */
16
+ var Ke;
17
+ function Or() {
18
+ if (Ke)
19
+ return le;
20
+ Ke = 1;
21
+ var n = Xe, s = Symbol.for("react.element"), t = Symbol.for("react.fragment"), a = Object.prototype.hasOwnProperty, c = n.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, l = { key: !0, ref: !0, __self: !0, __source: !0 };
22
+ function h(u, f, m) {
23
+ var v, x = {}, R = null, E = null;
24
+ m !== void 0 && (R = "" + m), f.key !== void 0 && (R = "" + f.key), f.ref !== void 0 && (E = f.ref);
25
+ for (v in f)
26
+ a.call(f, v) && !l.hasOwnProperty(v) && (x[v] = f[v]);
27
+ if (u && u.defaultProps)
28
+ for (v in f = u.defaultProps, f)
29
+ x[v] === void 0 && (x[v] = f[v]);
30
+ return { $$typeof: s, type: u, key: R, ref: E, props: x, _owner: c.current };
31
+ }
32
+ return le.Fragment = t, le.jsx = h, le.jsxs = h, le;
33
+ }
34
+ var fe = {};
35
+ /**
36
+ * @license React
37
+ * react-jsx-runtime.development.js
38
+ *
39
+ * Copyright (c) Facebook, Inc. and its affiliates.
40
+ *
41
+ * This source code is licensed under the MIT license found in the
42
+ * LICENSE file in the root directory of this source tree.
43
+ */
44
+ var Je;
45
+ function Fr() {
46
+ return Je || (Je = 1, process.env.NODE_ENV !== "production" && function() {
47
+ var n = Xe, s = Symbol.for("react.element"), t = Symbol.for("react.portal"), a = Symbol.for("react.fragment"), c = Symbol.for("react.strict_mode"), l = Symbol.for("react.profiler"), h = Symbol.for("react.provider"), u = Symbol.for("react.context"), f = Symbol.for("react.forward_ref"), m = Symbol.for("react.suspense"), v = Symbol.for("react.suspense_list"), x = Symbol.for("react.memo"), R = Symbol.for("react.lazy"), E = Symbol.for("react.offscreen"), P = Symbol.iterator, I = "@@iterator";
48
+ function w(e) {
49
+ if (e === null || typeof e != "object")
50
+ return null;
51
+ var r = P && e[P] || e[I];
52
+ return typeof r == "function" ? r : null;
53
+ }
54
+ var b = n.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
55
+ function g(e) {
56
+ {
57
+ for (var r = arguments.length, i = new Array(r > 1 ? r - 1 : 0), d = 1; d < r; d++)
58
+ i[d - 1] = arguments[d];
59
+ C("error", e, i);
60
+ }
61
+ }
62
+ function C(e, r, i) {
63
+ {
64
+ var d = b.ReactDebugCurrentFrame, _ = d.getStackAddendum();
65
+ _ !== "" && (r += "%s", i = i.concat([_]));
66
+ var S = i.map(function(y) {
67
+ return String(y);
68
+ });
69
+ S.unshift("Warning: " + r), Function.prototype.apply.call(console[e], console, S);
70
+ }
71
+ }
72
+ var O = !1, A = !1, F = !1, L = !1, B = !1, T;
73
+ T = Symbol.for("react.module.reference");
74
+ function D(e) {
75
+ return !!(typeof e == "string" || typeof e == "function" || e === a || e === l || B || e === c || e === m || e === v || L || e === E || O || A || F || typeof e == "object" && e !== null && (e.$$typeof === R || e.$$typeof === x || e.$$typeof === h || e.$$typeof === u || e.$$typeof === f || // This needs to include all possible module reference object
76
+ // types supported by any Flight configuration anywhere since
77
+ // we don't know which Flight build this will end up being used
78
+ // with.
79
+ e.$$typeof === T || e.getModuleId !== void 0));
80
+ }
81
+ function k(e, r, i) {
82
+ var d = e.displayName;
83
+ if (d)
84
+ return d;
85
+ var _ = r.displayName || r.name || "";
86
+ return _ !== "" ? i + "(" + _ + ")" : i;
87
+ }
88
+ function z(e) {
89
+ return e.displayName || "Context";
90
+ }
91
+ function j(e) {
92
+ if (e == null)
93
+ return null;
94
+ if (typeof e.tag == "number" && g("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."), typeof e == "function")
95
+ return e.displayName || e.name || null;
96
+ if (typeof e == "string")
97
+ return e;
98
+ switch (e) {
99
+ case a:
100
+ return "Fragment";
101
+ case t:
102
+ return "Portal";
103
+ case l:
104
+ return "Profiler";
105
+ case c:
106
+ return "StrictMode";
107
+ case m:
108
+ return "Suspense";
109
+ case v:
110
+ return "SuspenseList";
111
+ }
112
+ if (typeof e == "object")
113
+ switch (e.$$typeof) {
114
+ case u:
115
+ var r = e;
116
+ return z(r) + ".Consumer";
117
+ case h:
118
+ var i = e;
119
+ return z(i._context) + ".Provider";
120
+ case f:
121
+ return k(e, e.render, "ForwardRef");
122
+ case x:
123
+ var d = e.displayName || null;
124
+ return d !== null ? d : j(e.type) || "Memo";
125
+ case R: {
126
+ var _ = e, S = _._payload, y = _._init;
127
+ try {
128
+ return j(y(S));
129
+ } catch {
130
+ return null;
131
+ }
132
+ }
133
+ }
134
+ return null;
135
+ }
136
+ var Y = Object.assign, K = 0, q, Z, Q, ee, re, ne, M;
137
+ function J() {
138
+ }
139
+ J.__reactDisabledLog = !0;
140
+ function G() {
141
+ {
142
+ if (K === 0) {
143
+ q = console.log, Z = console.info, Q = console.warn, ee = console.error, re = console.group, ne = console.groupCollapsed, M = console.groupEnd;
144
+ var e = {
145
+ configurable: !0,
146
+ enumerable: !0,
147
+ value: J,
148
+ writable: !0
149
+ };
150
+ Object.defineProperties(console, {
151
+ info: e,
152
+ log: e,
153
+ warn: e,
154
+ error: e,
155
+ group: e,
156
+ groupCollapsed: e,
157
+ groupEnd: e
158
+ });
159
+ }
160
+ K++;
161
+ }
162
+ }
163
+ function $e() {
164
+ {
165
+ if (K--, K === 0) {
166
+ var e = {
167
+ configurable: !0,
168
+ enumerable: !0,
169
+ writable: !0
170
+ };
171
+ Object.defineProperties(console, {
172
+ log: Y({}, e, {
173
+ value: q
174
+ }),
175
+ info: Y({}, e, {
176
+ value: Z
177
+ }),
178
+ warn: Y({}, e, {
179
+ value: Q
180
+ }),
181
+ error: Y({}, e, {
182
+ value: ee
183
+ }),
184
+ group: Y({}, e, {
185
+ value: re
186
+ }),
187
+ groupCollapsed: Y({}, e, {
188
+ value: ne
189
+ }),
190
+ groupEnd: Y({}, e, {
191
+ value: M
192
+ })
193
+ });
194
+ }
195
+ K < 0 && g("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
196
+ }
197
+ }
198
+ var xe = b.ReactCurrentDispatcher, ye;
199
+ function he(e, r, i) {
200
+ {
201
+ if (ye === void 0)
202
+ try {
203
+ throw Error();
204
+ } catch (_) {
205
+ var d = _.stack.trim().match(/\n( *(at )?)/);
206
+ ye = d && d[1] || "";
207
+ }
208
+ return `
209
+ ` + ye + e;
210
+ }
211
+ }
212
+ var be = !1, me;
213
+ {
214
+ var nr = typeof WeakMap == "function" ? WeakMap : Map;
215
+ me = new nr();
216
+ }
217
+ function Pe(e, r) {
218
+ if (!e || be)
219
+ return "";
220
+ {
221
+ var i = me.get(e);
222
+ if (i !== void 0)
223
+ return i;
224
+ }
225
+ var d;
226
+ be = !0;
227
+ var _ = Error.prepareStackTrace;
228
+ Error.prepareStackTrace = void 0;
229
+ var S;
230
+ S = xe.current, xe.current = null, G();
231
+ try {
232
+ if (r) {
233
+ var y = function() {
234
+ throw Error();
235
+ };
236
+ if (Object.defineProperty(y.prototype, "props", {
237
+ set: function() {
238
+ throw Error();
239
+ }
240
+ }), typeof Reflect == "object" && Reflect.construct) {
241
+ try {
242
+ Reflect.construct(y, []);
243
+ } catch (V) {
244
+ d = V;
245
+ }
246
+ Reflect.construct(e, [], y);
247
+ } else {
248
+ try {
249
+ y.call();
250
+ } catch (V) {
251
+ d = V;
252
+ }
253
+ e.call(y.prototype);
254
+ }
255
+ } else {
256
+ try {
257
+ throw Error();
258
+ } catch (V) {
259
+ d = V;
260
+ }
261
+ e();
262
+ }
263
+ } catch (V) {
264
+ if (V && d && typeof V.stack == "string") {
265
+ for (var p = V.stack.split(`
266
+ `), W = d.stack.split(`
267
+ `), N = p.length - 1, $ = W.length - 1; N >= 1 && $ >= 0 && p[N] !== W[$]; )
268
+ $--;
269
+ for (; N >= 1 && $ >= 0; N--, $--)
270
+ if (p[N] !== W[$]) {
271
+ if (N !== 1 || $ !== 1)
272
+ do
273
+ if (N--, $--, $ < 0 || p[N] !== W[$]) {
274
+ var U = `
275
+ ` + p[N].replace(" at new ", " at ");
276
+ return e.displayName && U.includes("<anonymous>") && (U = U.replace("<anonymous>", e.displayName)), typeof e == "function" && me.set(e, U), U;
277
+ }
278
+ while (N >= 1 && $ >= 0);
279
+ break;
280
+ }
281
+ }
282
+ } finally {
283
+ be = !1, xe.current = S, $e(), Error.prepareStackTrace = _;
284
+ }
285
+ var se = e ? e.displayName || e.name : "", H = se ? he(se) : "";
286
+ return typeof e == "function" && me.set(e, H), H;
287
+ }
288
+ function tr(e, r, i) {
289
+ return Pe(e, !1);
290
+ }
291
+ function sr(e) {
292
+ var r = e.prototype;
293
+ return !!(r && r.isReactComponent);
294
+ }
295
+ function ve(e, r, i) {
296
+ if (e == null)
297
+ return "";
298
+ if (typeof e == "function")
299
+ return Pe(e, sr(e));
300
+ if (typeof e == "string")
301
+ return he(e);
302
+ switch (e) {
303
+ case m:
304
+ return he("Suspense");
305
+ case v:
306
+ return he("SuspenseList");
307
+ }
308
+ if (typeof e == "object")
309
+ switch (e.$$typeof) {
310
+ case f:
311
+ return tr(e.render);
312
+ case x:
313
+ return ve(e.type, r, i);
314
+ case R: {
315
+ var d = e, _ = d._payload, S = d._init;
316
+ try {
317
+ return ve(S(_), r, i);
318
+ } catch {
319
+ }
320
+ }
321
+ }
322
+ return "";
323
+ }
324
+ var ce = Object.prototype.hasOwnProperty, Ie = {}, we = b.ReactDebugCurrentFrame;
325
+ function ge(e) {
326
+ if (e) {
327
+ var r = e._owner, i = ve(e.type, e._source, r ? r.type : null);
328
+ we.setExtraStackFrame(i);
329
+ } else
330
+ we.setExtraStackFrame(null);
331
+ }
332
+ function ir(e, r, i, d, _) {
333
+ {
334
+ var S = Function.call.bind(ce);
335
+ for (var y in e)
336
+ if (S(e, y)) {
337
+ var p = void 0;
338
+ try {
339
+ if (typeof e[y] != "function") {
340
+ var W = Error((d || "React class") + ": " + i + " type `" + y + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof e[y] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");
341
+ throw W.name = "Invariant Violation", W;
342
+ }
343
+ p = e[y](r, y, d, i, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
344
+ } catch (N) {
345
+ p = N;
346
+ }
347
+ p && !(p instanceof Error) && (ge(_), g("%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).", d || "React class", i, y, typeof p), ge(null)), p instanceof Error && !(p.message in Ie) && (Ie[p.message] = !0, ge(_), g("Failed %s type: %s", i, p.message), ge(null));
348
+ }
349
+ }
350
+ }
351
+ var or = Array.isArray;
352
+ function _e(e) {
353
+ return or(e);
354
+ }
355
+ function ar(e) {
356
+ {
357
+ var r = typeof Symbol == "function" && Symbol.toStringTag, i = r && e[Symbol.toStringTag] || e.constructor.name || "Object";
358
+ return i;
359
+ }
360
+ }
361
+ function cr(e) {
362
+ try {
363
+ return Te(e), !1;
364
+ } catch {
365
+ return !0;
366
+ }
367
+ }
368
+ function Te(e) {
369
+ return "" + e;
370
+ }
371
+ function Oe(e) {
372
+ if (cr(e))
373
+ return g("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", ar(e)), Te(e);
374
+ }
375
+ var ue = b.ReactCurrentOwner, ur = {
376
+ key: !0,
377
+ ref: !0,
378
+ __self: !0,
379
+ __source: !0
380
+ }, Fe, Le, Re;
381
+ Re = {};
382
+ function lr(e) {
383
+ if (ce.call(e, "ref")) {
384
+ var r = Object.getOwnPropertyDescriptor(e, "ref").get;
385
+ if (r && r.isReactWarning)
386
+ return !1;
387
+ }
388
+ return e.ref !== void 0;
389
+ }
390
+ function fr(e) {
391
+ if (ce.call(e, "key")) {
392
+ var r = Object.getOwnPropertyDescriptor(e, "key").get;
393
+ if (r && r.isReactWarning)
394
+ return !1;
395
+ }
396
+ return e.key !== void 0;
397
+ }
398
+ function dr(e, r) {
399
+ if (typeof e.ref == "string" && ue.current && r && ue.current.stateNode !== r) {
400
+ var i = j(ue.current.type);
401
+ Re[i] || (g('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref', j(ue.current.type), e.ref), Re[i] = !0);
402
+ }
403
+ }
404
+ function hr(e, r) {
405
+ {
406
+ var i = function() {
407
+ Fe || (Fe = !0, g("%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));
408
+ };
409
+ i.isReactWarning = !0, Object.defineProperty(e, "key", {
410
+ get: i,
411
+ configurable: !0
412
+ });
413
+ }
414
+ }
415
+ function mr(e, r) {
416
+ {
417
+ var i = function() {
418
+ Le || (Le = !0, g("%s: `ref` 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));
419
+ };
420
+ i.isReactWarning = !0, Object.defineProperty(e, "ref", {
421
+ get: i,
422
+ configurable: !0
423
+ });
424
+ }
425
+ }
426
+ var vr = function(e, r, i, d, _, S, y) {
427
+ var p = {
428
+ // This tag allows us to uniquely identify this as a React Element
429
+ $$typeof: s,
430
+ // Built-in properties that belong on the element
431
+ type: e,
432
+ key: r,
433
+ ref: i,
434
+ props: y,
435
+ // Record the component responsible for creating this element.
436
+ _owner: S
437
+ };
438
+ return p._store = {}, Object.defineProperty(p._store, "validated", {
439
+ configurable: !1,
440
+ enumerable: !1,
441
+ writable: !0,
442
+ value: !1
443
+ }), Object.defineProperty(p, "_self", {
444
+ configurable: !1,
445
+ enumerable: !1,
446
+ writable: !1,
447
+ value: d
448
+ }), Object.defineProperty(p, "_source", {
449
+ configurable: !1,
450
+ enumerable: !1,
451
+ writable: !1,
452
+ value: _
453
+ }), Object.freeze && (Object.freeze(p.props), Object.freeze(p)), p;
454
+ };
455
+ function gr(e, r, i, d, _) {
456
+ {
457
+ var S, y = {}, p = null, W = null;
458
+ i !== void 0 && (Oe(i), p = "" + i), fr(r) && (Oe(r.key), p = "" + r.key), lr(r) && (W = r.ref, dr(r, _));
459
+ for (S in r)
460
+ ce.call(r, S) && !ur.hasOwnProperty(S) && (y[S] = r[S]);
461
+ if (e && e.defaultProps) {
462
+ var N = e.defaultProps;
463
+ for (S in N)
464
+ y[S] === void 0 && (y[S] = N[S]);
465
+ }
466
+ if (p || W) {
467
+ var $ = typeof e == "function" ? e.displayName || e.name || "Unknown" : e;
468
+ p && hr(y, $), W && mr(y, $);
469
+ }
470
+ return vr(e, p, W, _, d, ue.current, y);
471
+ }
472
+ }
473
+ var Se = b.ReactCurrentOwner, ze = b.ReactDebugCurrentFrame;
474
+ function te(e) {
475
+ if (e) {
476
+ var r = e._owner, i = ve(e.type, e._source, r ? r.type : null);
477
+ ze.setExtraStackFrame(i);
478
+ } else
479
+ ze.setExtraStackFrame(null);
480
+ }
481
+ var Ee;
482
+ Ee = !1;
483
+ function Ce(e) {
484
+ return typeof e == "object" && e !== null && e.$$typeof === s;
485
+ }
486
+ function De() {
487
+ {
488
+ if (Se.current) {
489
+ var e = j(Se.current.type);
490
+ if (e)
491
+ return `
492
+
493
+ Check the render method of \`` + e + "`.";
494
+ }
495
+ return "";
496
+ }
497
+ }
498
+ function pr(e) {
499
+ {
500
+ if (e !== void 0) {
501
+ var r = e.fileName.replace(/^.*[\\\/]/, ""), i = e.lineNumber;
502
+ return `
503
+
504
+ Check your code at ` + r + ":" + i + ".";
505
+ }
506
+ return "";
507
+ }
508
+ }
509
+ var We = {};
510
+ function xr(e) {
511
+ {
512
+ var r = De();
513
+ if (!r) {
514
+ var i = typeof e == "string" ? e : e.displayName || e.name;
515
+ i && (r = `
516
+
517
+ Check the top-level render call using <` + i + ">.");
518
+ }
519
+ return r;
520
+ }
521
+ }
522
+ function Ae(e, r) {
523
+ {
524
+ if (!e._store || e._store.validated || e.key != null)
525
+ return;
526
+ e._store.validated = !0;
527
+ var i = xr(r);
528
+ if (We[i])
529
+ return;
530
+ We[i] = !0;
531
+ var d = "";
532
+ e && e._owner && e._owner !== Se.current && (d = " It was passed a child from " + j(e._owner.type) + "."), te(e), g('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', i, d), te(null);
533
+ }
534
+ }
535
+ function Be(e, r) {
536
+ {
537
+ if (typeof e != "object")
538
+ return;
539
+ if (_e(e))
540
+ for (var i = 0; i < e.length; i++) {
541
+ var d = e[i];
542
+ Ce(d) && Ae(d, r);
543
+ }
544
+ else if (Ce(e))
545
+ e._store && (e._store.validated = !0);
546
+ else if (e) {
547
+ var _ = w(e);
548
+ if (typeof _ == "function" && _ !== e.entries)
549
+ for (var S = _.call(e), y; !(y = S.next()).done; )
550
+ Ce(y.value) && Ae(y.value, r);
551
+ }
552
+ }
553
+ }
554
+ function yr(e) {
555
+ {
556
+ var r = e.type;
557
+ if (r == null || typeof r == "string")
558
+ return;
559
+ var i;
560
+ if (typeof r == "function")
561
+ i = r.propTypes;
562
+ else if (typeof r == "object" && (r.$$typeof === f || // Note: Memo only checks outer props here.
563
+ // Inner props are checked in the reconciler.
564
+ r.$$typeof === x))
565
+ i = r.propTypes;
566
+ else
567
+ return;
568
+ if (i) {
569
+ var d = j(r);
570
+ ir(i, e.props, "prop", d, e);
571
+ } else if (r.PropTypes !== void 0 && !Ee) {
572
+ Ee = !0;
573
+ var _ = j(r);
574
+ g("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", _ || "Unknown");
575
+ }
576
+ typeof r.getDefaultProps == "function" && !r.getDefaultProps.isReactClassApproved && g("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
577
+ }
578
+ }
579
+ function br(e) {
580
+ {
581
+ for (var r = Object.keys(e.props), i = 0; i < r.length; i++) {
582
+ var d = r[i];
583
+ if (d !== "children" && d !== "key") {
584
+ te(e), g("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", d), te(null);
585
+ break;
586
+ }
587
+ }
588
+ e.ref !== null && (te(e), g("Invalid attribute `ref` supplied to `React.Fragment`."), te(null));
589
+ }
590
+ }
591
+ var Ve = {};
592
+ function Ye(e, r, i, d, _, S) {
593
+ {
594
+ var y = D(e);
595
+ if (!y) {
596
+ var p = "";
597
+ (e === void 0 || typeof e == "object" && e !== null && Object.keys(e).length === 0) && (p += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
598
+ var W = pr(_);
599
+ W ? p += W : p += De();
600
+ var N;
601
+ e === null ? N = "null" : _e(e) ? N = "array" : e !== void 0 && e.$$typeof === s ? (N = "<" + (j(e.type) || "Unknown") + " />", p = " Did you accidentally export a JSX literal instead of a component?") : N = typeof e, g("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", N, p);
602
+ }
603
+ var $ = gr(e, r, i, _, S);
604
+ if ($ == null)
605
+ return $;
606
+ if (y) {
607
+ var U = r.children;
608
+ if (U !== void 0)
609
+ if (d)
610
+ if (_e(U)) {
611
+ for (var se = 0; se < U.length; se++)
612
+ Be(U[se], e);
613
+ Object.freeze && Object.freeze(U);
614
+ } else
615
+ g("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");
616
+ else
617
+ Be(U, e);
618
+ }
619
+ if (ce.call(r, "key")) {
620
+ var H = j(e), V = Object.keys(r).filter(function(jr) {
621
+ return jr !== "key";
622
+ }), je = V.length > 0 ? "{key: someKey, " + V.join(": ..., ") + ": ...}" : "{key: someKey}";
623
+ if (!Ve[H + je]) {
624
+ var Cr = V.length > 0 ? "{" + V.join(": ..., ") + ": ...}" : "{}";
625
+ g(`A props object containing a "key" prop is being spread into JSX:
626
+ let props = %s;
627
+ <%s {...props} />
628
+ React keys must be passed directly to JSX without using spread:
629
+ let props = %s;
630
+ <%s key={someKey} {...props} />`, je, H, Cr, H), Ve[H + je] = !0;
631
+ }
632
+ }
633
+ return e === a ? br($) : yr($), $;
634
+ }
635
+ }
636
+ function _r(e, r, i) {
637
+ return Ye(e, r, i, !0);
638
+ }
639
+ function Rr(e, r, i) {
640
+ return Ye(e, r, i, !1);
641
+ }
642
+ var Sr = Rr, Er = _r;
643
+ fe.Fragment = a, fe.jsx = Sr, fe.jsxs = Er;
644
+ }()), fe;
645
+ }
646
+ process.env.NODE_ENV === "production" ? ke.exports = Or() : ke.exports = Fr();
647
+ var o = ke.exports;
648
+ function pe(n, s) {
649
+ return s ? /* @__PURE__ */ o.jsx(s, { size: n, strokeWidth: 2.5 }) : /* @__PURE__ */ o.jsx(o.Fragment, {});
650
+ }
651
+ function Lr(n) {
652
+ const {
653
+ variant: s = "ghost",
654
+ scheme: t = "primary",
655
+ size: a = "md",
656
+ leftIcon: c,
657
+ rightIcon: l,
658
+ className: h = "",
659
+ children: u,
660
+ ...f
661
+ } = n, v = { md: 12, lg: 14 }[a];
662
+ return {
663
+ className: `arkyn_badge ${s} ${t} ${a} ${h}`.trim(),
664
+ children: u,
665
+ leftIcon: pe(v, c),
666
+ rightIcon: pe(v, l),
667
+ ...f
668
+ };
669
+ }
670
+ function fn(n) {
671
+ const { leftIcon: s, children: t, rightIcon: a, ...c } = Lr(n);
672
+ return /* @__PURE__ */ o.jsxs("div", { ...c, children: [
673
+ s,
674
+ t,
675
+ a
676
+ ] });
677
+ }
678
+ function dn(n) {
679
+ const {
680
+ className: s,
681
+ orientation: t = "horizontal",
682
+ ...a
683
+ } = n, c = `arkyn_divider ${t} ${s}`;
684
+ return /* @__PURE__ */ o.jsx("div", { className: c, ...a });
685
+ }
686
+ function zr(n) {
687
+ const {
688
+ isLoading: s = !1,
689
+ scheme: t = "primary",
690
+ variant: a = "solid",
691
+ loadingText: c,
692
+ size: l = "md",
693
+ leftIcon: h,
694
+ rightIcon: u,
695
+ disabled: f,
696
+ className: m = "",
697
+ children: v,
698
+ ...x
699
+ } = n, E = { xs: 12, sm: 16, md: 20, lg: 24 }[l];
700
+ return {
701
+ className: `arkyn_button loading_text_${!!c} ${a} ${t} ${l} loading_${s} ${m}`.trim(),
702
+ loadingText: c,
703
+ children: v,
704
+ iconSize: E,
705
+ disabled: f || s,
706
+ leftIcon: pe(E, h),
707
+ rightIcon: pe(E, u),
708
+ ...x
709
+ };
710
+ }
711
+ function hn(n) {
712
+ const { leftIcon: s, rightIcon: t, iconSize: a, children: c, loadingText: l, ...h } = zr(n);
713
+ return /* @__PURE__ */ o.jsxs("button", { ...h, children: [
714
+ /* @__PURE__ */ o.jsxs("div", { className: "spinner", children: [
715
+ /* @__PURE__ */ o.jsx(oe, { size: a, strokeWidth: 2.5 }),
716
+ l && l
717
+ ] }),
718
+ /* @__PURE__ */ o.jsxs("div", { className: "content", children: [
719
+ s,
720
+ c,
721
+ t
722
+ ] })
723
+ ] });
724
+ }
725
+ const Qe = He({});
726
+ function mn({ children: n, ...s }) {
727
+ var u, f;
728
+ const t = $r(), a = de(null), c = ((u = a.current) == null ? void 0 : u.name) || "", l = ((f = t == null ? void 0 : t.fieldErrors) == null ? void 0 : f[c]) || null, h = kr();
729
+ return /* @__PURE__ */ o.jsx(Qe.Provider, { value: { error: l, id: h, inputRef: a }, children: /* @__PURE__ */ o.jsx("section", { className: "arkyn_form_controller", ...s, children: n }) });
730
+ }
731
+ function ae() {
732
+ return Ze(Qe);
733
+ }
734
+ function vn() {
735
+ const { error: n } = ae();
736
+ return n ? /* @__PURE__ */ o.jsx("strong", { className: "arkyn_form_error", children: n }) : /* @__PURE__ */ o.jsx(o.Fragment, {});
737
+ }
738
+ function Dr(n) {
739
+ const { showAsterisk: s = !1, className: t = "", ...a } = n;
740
+ return {
741
+ className: `arkyn_form_label ${s ? "show-asterisk" : ""} ${t}`.trim(),
742
+ ...a
743
+ };
744
+ }
745
+ function gn(n) {
746
+ const { id: s } = ae();
747
+ return /* @__PURE__ */ o.jsx("label", { ...Dr(n), htmlFor: s });
748
+ }
749
+ const qe = {
750
+ xs: 12,
751
+ sm: 16,
752
+ md: 20,
753
+ lg: 24
754
+ };
755
+ function pn(n) {
756
+ const {
757
+ isLoading: s = !1,
758
+ scheme: t = "primary",
759
+ variant: a = "solid",
760
+ size: c = "md",
761
+ icon: l,
762
+ disabled: h,
763
+ className: u = "",
764
+ ...f
765
+ } = n, m = `arkyn_icon_button ${a} ${t} ${c} loading_${s} ${u}`;
766
+ return /* @__PURE__ */ o.jsxs(
767
+ "button",
768
+ {
769
+ disabled: h || s,
770
+ className: m.trim(),
771
+ ...f,
772
+ children: [
773
+ /* @__PURE__ */ o.jsx("div", { className: "spinner", children: /* @__PURE__ */ o.jsx(oe, { size: qe[c], strokeWidth: 2.5 }) }),
774
+ /* @__PURE__ */ o.jsx("div", { className: "content " + c, children: /* @__PURE__ */ o.jsx(l, { size: qe[c], strokeWidth: 2.5 }) })
775
+ ]
776
+ }
777
+ );
778
+ }
779
+ function X(n, s, t) {
780
+ if (!n)
781
+ return /* @__PURE__ */ o.jsx(o.Fragment, {});
782
+ if (typeof n == "string")
783
+ return /* @__PURE__ */ o.jsx("p", { className: t, children: n });
784
+ const a = n;
785
+ return /* @__PURE__ */ o.jsx("p", { className: t, children: /* @__PURE__ */ o.jsx(a, { color: "var(--secondary-600)", size: s, strokeWidth: 2.5 }) });
786
+ }
787
+ function Wr(n, s) {
788
+ const {
789
+ isLoading: t,
790
+ isError: a,
791
+ size: c = "md",
792
+ className: l = "",
793
+ variant: h = "solid",
794
+ prefix: u,
795
+ sufix: f,
796
+ leftIcon: m,
797
+ rightIcon: v,
798
+ disabled: x,
799
+ readOnly: R,
800
+ onFocus: E,
801
+ onBlur: P,
802
+ title: I,
803
+ style: w,
804
+ onChange: b,
805
+ ...g
806
+ } = n, C = v ? "right" : "left", T = `arkyn_input ${u ? "hasPrefix" : ""} ${f ? "hasSufix" : ""} ${h} ${c} ${x || R || t ? "opacity" : ""} ${a ? "errored" : ""} ${s ? "focused" : ""} ${l}`, k = { md: 14, lg: 16 }[c];
807
+ return {
808
+ isLoading: t,
809
+ className: T,
810
+ prefix: X(u, k, "prefix"),
811
+ sufix: X(f, k, "sufix"),
812
+ LeftIcon: m,
813
+ RightIcon: v,
814
+ disabled: x,
815
+ readOnly: R,
816
+ onFocus: E,
817
+ onBlur: P,
818
+ title: I,
819
+ style: w,
820
+ onChange: b,
821
+ loadingPosition: C,
822
+ iconSize: k,
823
+ Spinner: /* @__PURE__ */ o.jsx(oe, { className: "spinner", size: k, strokeWidth: 2.5 }),
824
+ ...g
825
+ };
826
+ }
827
+ function Ne(n) {
828
+ return n && n.replace(/[^0-9]/g, "");
829
+ }
830
+ function Ar(n, s) {
831
+ let t = "", a = 0;
832
+ return Array.from(n).forEach((c, l) => {
833
+ s[l + a].match(/[0-9]/) || (t += s[l + a], a++), t += c;
834
+ }), t;
835
+ }
836
+ function Br(n) {
837
+ return n.length > 11 ? "CNPJ" : "CPF";
838
+ }
839
+ const er = {
840
+ CPF: "999.999.999-999",
841
+ CNPJ: "99.999.999/9999-99"
842
+ }, Vr = Ne(er.CNPJ).length;
843
+ function Yr(n) {
844
+ const [s, t] = ie(!1), [a, c] = ie(
845
+ Ne((n == null ? void 0 : n.defaultValue) || "")
846
+ ), l = de(null), { inputRef: h, id: u, error: f } = ae(), m = h || l, v = n.isError || !!f, {
847
+ disabled: x,
848
+ title: R,
849
+ style: E,
850
+ className: P,
851
+ prefix: I,
852
+ sufix: w,
853
+ iconSize: b,
854
+ loadingPosition: g,
855
+ isLoading: C,
856
+ LeftIcon: O,
857
+ readOnly: A,
858
+ onFocus: F,
859
+ onBlur: L,
860
+ RightIcon: B,
861
+ Spinner: T,
862
+ onChange: D,
863
+ value: k,
864
+ defaultValue: z = "",
865
+ ...j
866
+ } = Wr({ ...n, id: u, isError: v }, s), Y = O && !C, K = B && !C, q = g === "left" && C, Z = g === "right" && C;
867
+ function Q() {
868
+ x || !(m != null && m.current) || (t(!0), m.current.focus());
869
+ }
870
+ function ee(M) {
871
+ let J = Ne(M.target.value);
872
+ const G = Br(J);
873
+ J.length > Vr || (J = Ar(J, er[G]), M.target.value = J, c(J), D && D(M));
874
+ }
875
+ function re(M) {
876
+ t(!0), F && F(M);
877
+ }
878
+ function ne(M) {
879
+ t(!1), L && L(M);
880
+ }
881
+ return /* @__PURE__ */ o.jsxs(
882
+ "section",
883
+ {
884
+ title: R,
885
+ style: E,
886
+ onClick: Q,
887
+ className: P,
888
+ children: [
889
+ I,
890
+ q && T,
891
+ Y && /* @__PURE__ */ o.jsx(O, { size: b, strokeWidth: 2.5 }),
892
+ /* @__PURE__ */ o.jsx(
893
+ "input",
894
+ {
895
+ disabled: x || C,
896
+ readOnly: A,
897
+ ref: m,
898
+ value: k || a,
899
+ onFocus: re,
900
+ onChange: ee,
901
+ onBlur: ne,
902
+ ...j
903
+ }
904
+ ),
905
+ K && /* @__PURE__ */ o.jsx(B, { size: b, strokeWidth: 2.5 }),
906
+ Z && T,
907
+ w
908
+ ]
909
+ }
910
+ );
911
+ }
912
+ function Mr(n, s) {
913
+ const {
914
+ isLoading: t,
915
+ isError: a,
916
+ size: c = "md",
917
+ className: l = "",
918
+ variant: h = "solid",
919
+ prefix: u,
920
+ sufix: f,
921
+ leftIcon: m,
922
+ rightIcon: v,
923
+ disabled: x,
924
+ readOnly: R,
925
+ onFocus: E,
926
+ onBlur: P,
927
+ title: I,
928
+ style: w,
929
+ showCents: b = !1,
930
+ max: g = 1e9,
931
+ onChange: C,
932
+ ...O
933
+ } = n, A = v ? "right" : "left", k = `arkyn_input ${u ? "hasPrefix" : ""} ${f ? "hasSufix" : ""} ${h} ${c} ${x || R || t ? "opacity" : ""} ${a ? "errored" : ""} ${s ? "focused" : ""} ${l}`, j = { md: 14, lg: 16 }[c];
934
+ return {
935
+ isLoading: t,
936
+ className: k,
937
+ prefix: X(u, j, "prefix"),
938
+ sufix: X(f, j, "sufix"),
939
+ LeftIcon: m,
940
+ RightIcon: v,
941
+ disabled: x,
942
+ readOnly: R,
943
+ onFocus: E,
944
+ onBlur: P,
945
+ title: I,
946
+ style: w,
947
+ max: g,
948
+ onChange: C,
949
+ showCents: b,
950
+ loadingPosition: A,
951
+ iconSize: j,
952
+ Spinner: /* @__PURE__ */ o.jsx(oe, { className: "spinner", size: j, strokeWidth: 2.5 }),
953
+ ...O
954
+ };
955
+ }
956
+ const Ur = /^[1-9]{1}$/, Kr = /^[0-9]{1}$/, Ge = 8;
957
+ function Jr(n, s) {
958
+ if (n === 0)
959
+ return "";
960
+ const t = (n / 100).toLocaleString("pt-BR", {
961
+ style: "currency",
962
+ currency: "BRL"
963
+ });
964
+ return s ? t : t.replace("R$", "").trim();
965
+ }
966
+ function qr(n) {
967
+ const { currencyValue: s, event: t, max: a, setCurrencyValue: c } = n, { key: l, keyCode: h } = t;
968
+ if (s === 0 && !Ur.test(l) || s !== 0 && !Kr.test(l) && h !== Ge)
969
+ return;
970
+ const u = s.toString();
971
+ let f;
972
+ if (h !== Ge) {
973
+ const m = s === 0 ? l : `${u}${l}`;
974
+ f = Number.parseInt(m, 10);
975
+ } else {
976
+ const m = u.slice(0, -1);
977
+ f = m === "" ? 0 : Number.parseInt(m, 10);
978
+ }
979
+ f > Number(a) || c(f);
980
+ }
981
+ function Gr(n) {
982
+ const [s, t] = ie(!1), [a, c] = ie(n.defaultValue || 0), l = de(null), { inputRef: h, id: u, error: f } = ae(), m = h || l, v = n.isError || !!f, {
983
+ disabled: x,
984
+ title: R,
985
+ style: E,
986
+ className: P,
987
+ prefix: I,
988
+ sufix: w,
989
+ iconSize: b,
990
+ loadingPosition: g,
991
+ isLoading: C,
992
+ LeftIcon: O,
993
+ readOnly: A,
994
+ onFocus: F,
995
+ onBlur: L,
996
+ RightIcon: B,
997
+ Spinner: T,
998
+ value: D,
999
+ max: k,
1000
+ onKeyDown: z,
1001
+ onChange: j,
1002
+ showCents: Y,
1003
+ ...K
1004
+ } = Mr({ ...n, id: u, isError: v }, s), q = O && !C, Z = B && !C, Q = g === "left" && C, ee = g === "right" && C;
1005
+ function re() {
1006
+ x || !(m != null && m.current) || (t(!0), m.current.focus());
1007
+ }
1008
+ function ne(G) {
1009
+ qr({ currencyValue: a, event: G, max: k, setCurrencyValue: c }), j && j(a), z && z(G);
1010
+ }
1011
+ function M(G) {
1012
+ t(!0), F && F(G);
1013
+ }
1014
+ function J(G) {
1015
+ t(!1), L && L(G);
1016
+ }
1017
+ return /* @__PURE__ */ o.jsxs(
1018
+ "section",
1019
+ {
1020
+ title: R,
1021
+ style: E,
1022
+ onClick: re,
1023
+ className: P,
1024
+ children: [
1025
+ I,
1026
+ Q && T,
1027
+ q && /* @__PURE__ */ o.jsx(O, { size: b, strokeWidth: 2.5 }),
1028
+ /* @__PURE__ */ o.jsx(
1029
+ "input",
1030
+ {
1031
+ value: Jr(D || a, Y),
1032
+ onKeyDown: ne,
1033
+ disabled: x || C,
1034
+ readOnly: A,
1035
+ ref: m,
1036
+ onFocus: M,
1037
+ onChange: () => {
1038
+ },
1039
+ onBlur: J,
1040
+ ...K
1041
+ }
1042
+ ),
1043
+ ee && T,
1044
+ Z && /* @__PURE__ */ o.jsx(B, { size: b, strokeWidth: 2.5 }),
1045
+ w
1046
+ ]
1047
+ }
1048
+ );
1049
+ }
1050
+ function Xr(n, s) {
1051
+ const {
1052
+ isLoading: t,
1053
+ isError: a,
1054
+ size: c = "md",
1055
+ className: l = "",
1056
+ variant: h = "solid",
1057
+ prefix: u,
1058
+ sufix: f,
1059
+ leftIcon: m,
1060
+ rightIcon: v,
1061
+ disabled: x,
1062
+ readOnly: R,
1063
+ onFocus: E,
1064
+ onBlur: P,
1065
+ title: I,
1066
+ style: w,
1067
+ onChange: b,
1068
+ showMask: g = !0,
1069
+ ...C
1070
+ } = n, O = v ? "right" : "left", D = `arkyn_input ${u ? "hasPrefix" : ""} ${f ? "hasSufix" : ""} ${h} ${c} ${x || R || t ? "opacity" : ""} ${a ? "errored" : ""} ${s ? "focused" : ""} ${l}`, z = { md: 14, lg: 16 }[c];
1071
+ return {
1072
+ isLoading: t,
1073
+ className: D,
1074
+ prefix: X(u, z, "prefix"),
1075
+ sufix: X(f, z, "sufix"),
1076
+ LeftIcon: m,
1077
+ RightIcon: v,
1078
+ disabled: x,
1079
+ readOnly: R,
1080
+ onFocus: E,
1081
+ onBlur: P,
1082
+ title: I,
1083
+ style: w,
1084
+ onChange: b,
1085
+ loadingPosition: O,
1086
+ iconSize: z,
1087
+ showMask: g,
1088
+ Spinner: /* @__PURE__ */ o.jsx(oe, { className: "spinner", size: z, strokeWidth: 2.5 }),
1089
+ ...C
1090
+ };
1091
+ }
1092
+ function Hr(n) {
1093
+ const [s, t] = ie(!1), a = de(null), { inputRef: c, id: l, error: h } = ae(), u = c || a, f = n.isError || !!h, {
1094
+ disabled: m,
1095
+ title: v,
1096
+ style: x,
1097
+ className: R,
1098
+ prefix: E,
1099
+ sufix: P,
1100
+ iconSize: I,
1101
+ loadingPosition: w,
1102
+ isLoading: b,
1103
+ LeftIcon: g,
1104
+ readOnly: C,
1105
+ onFocus: O,
1106
+ onBlur: A,
1107
+ RightIcon: F,
1108
+ Spinner: L,
1109
+ ...B
1110
+ } = Xr({ ...n, id: l, isError: f }, s), T = g && !b, D = F && !b, k = w === "left" && b, z = w === "right" && b;
1111
+ function j() {
1112
+ m || !(u != null && u.current) || (t(!0), u.current.focus());
1113
+ }
1114
+ return /* @__PURE__ */ o.jsxs(
1115
+ "section",
1116
+ {
1117
+ title: v,
1118
+ style: x,
1119
+ onClick: j,
1120
+ className: R,
1121
+ children: [
1122
+ E,
1123
+ k && L,
1124
+ T && /* @__PURE__ */ o.jsx(g, { size: I, strokeWidth: 2.5 }),
1125
+ /* @__PURE__ */ o.jsx(
1126
+ wr,
1127
+ {}
1128
+ ),
1129
+ D && /* @__PURE__ */ o.jsx(F, { size: I, strokeWidth: 2.5 }),
1130
+ z && L,
1131
+ P
1132
+ ]
1133
+ }
1134
+ );
1135
+ }
1136
+ function Zr(n, s) {
1137
+ const {
1138
+ isLoading: t,
1139
+ isError: a,
1140
+ size: c = "md",
1141
+ className: l = "",
1142
+ variant: h = "solid",
1143
+ prefix: u,
1144
+ sufix: f,
1145
+ leftIcon: m,
1146
+ rightIcon: v,
1147
+ disabled: x,
1148
+ readOnly: R,
1149
+ onFocus: E,
1150
+ onBlur: P,
1151
+ title: I,
1152
+ style: w,
1153
+ onChange: b,
1154
+ ...g
1155
+ } = n, C = v ? "right" : "left", T = `arkyn_input ${u ? "hasPrefix" : ""} ${f ? "hasSufix" : ""} ${h} ${c} ${x || R || t ? "opacity" : ""} ${a ? "errored" : ""} ${s ? "focused" : ""} ${l}`, k = { md: 14, lg: 16 }[c];
1156
+ return {
1157
+ isLoading: t,
1158
+ className: T,
1159
+ prefix: X(u, k, "prefix"),
1160
+ sufix: X(f, k, "sufix"),
1161
+ LeftIcon: m,
1162
+ RightIcon: v,
1163
+ disabled: x,
1164
+ readOnly: R,
1165
+ onFocus: E,
1166
+ onBlur: P,
1167
+ title: I,
1168
+ style: w,
1169
+ onChange: b,
1170
+ loadingPosition: C,
1171
+ iconSize: k,
1172
+ Spinner: /* @__PURE__ */ o.jsx(oe, { className: "spinner", size: k, strokeWidth: 2.5 }),
1173
+ ...g
1174
+ };
1175
+ }
1176
+ function Qr(n) {
1177
+ const [s, t] = ie(!1), a = de(null), { inputRef: c, id: l, error: h } = ae(), u = c || a, f = n.isError || !!h, {
1178
+ disabled: m,
1179
+ title: v,
1180
+ style: x,
1181
+ className: R,
1182
+ prefix: E,
1183
+ sufix: P,
1184
+ iconSize: I,
1185
+ loadingPosition: w,
1186
+ isLoading: b,
1187
+ LeftIcon: g,
1188
+ readOnly: C,
1189
+ onFocus: O,
1190
+ onBlur: A,
1191
+ RightIcon: F,
1192
+ Spinner: L,
1193
+ ...B
1194
+ } = Zr({ ...n, id: l, isError: f }, s), T = g && !b, D = F && !b, k = w === "left" && b, z = w === "right" && b;
1195
+ function j() {
1196
+ m || !(u != null && u.current) || (t(!0), u.current.focus());
1197
+ }
1198
+ function Y(q) {
1199
+ t(!0), O && O(q);
1200
+ }
1201
+ function K(q) {
1202
+ t(!1), A && A(q);
1203
+ }
1204
+ return /* @__PURE__ */ o.jsxs(
1205
+ "section",
1206
+ {
1207
+ title: v,
1208
+ style: x,
1209
+ onClick: j,
1210
+ className: R,
1211
+ children: [
1212
+ E,
1213
+ k && L,
1214
+ T && /* @__PURE__ */ o.jsx(g, { size: I, strokeWidth: 2.5 }),
1215
+ /* @__PURE__ */ o.jsx(
1216
+ "input",
1217
+ {
1218
+ disabled: m || b,
1219
+ readOnly: C,
1220
+ ref: u,
1221
+ onFocus: Y,
1222
+ onBlur: K,
1223
+ ...B
1224
+ }
1225
+ ),
1226
+ D && /* @__PURE__ */ o.jsx(F, { size: I, strokeWidth: 2.5 }),
1227
+ z && L,
1228
+ P
1229
+ ]
1230
+ }
1231
+ );
1232
+ }
1233
+ function xn(n) {
1234
+ return n.type === "currency" ? /* @__PURE__ */ o.jsx(Gr, { ...n }) : n.type === "masked" ? /* @__PURE__ */ o.jsx(Hr, { ...n }) : n.type === "cpf-cpnj" ? /* @__PURE__ */ o.jsx(Yr, { ...n }) : /* @__PURE__ */ o.jsx(Qr, { ...n });
1235
+ }
1236
+ function en(n) {
1237
+ const { className: s = "", ...t } = n;
1238
+ return { className: `arkyn_breadcrumb ${s}`.trim(), ...t };
1239
+ }
1240
+ function rn(n) {
1241
+ const { pathname: s } = Pr(), {
1242
+ className: t = "",
1243
+ disabled: a = !1,
1244
+ to: c,
1245
+ ...l
1246
+ } = n, h = s === c ? "active" : "inactive", u = `arkyn_breadcrumb_link ${h} ${t}`;
1247
+ return {
1248
+ to: c,
1249
+ className: u.trim(),
1250
+ disabled: a || h === "active",
1251
+ ...l
1252
+ };
1253
+ }
1254
+ function yn(n) {
1255
+ const { className: s, ...t } = en(n);
1256
+ return /* @__PURE__ */ o.jsx("nav", { className: s, ...t });
1257
+ }
1258
+ function bn(n) {
1259
+ const { children: s, className: t, disabled: a, ...c } = rn(n);
1260
+ return a ? /* @__PURE__ */ o.jsxs("p", { className: t, children: [
1261
+ /* @__PURE__ */ o.jsx(Me, { size: 14, strokeWidth: 2.5 }),
1262
+ s
1263
+ ] }) : /* @__PURE__ */ o.jsxs(Ir, { className: t, ...c, children: [
1264
+ /* @__PURE__ */ o.jsx(Me, { size: 14, strokeWidth: 2.5 }),
1265
+ s
1266
+ ] });
1267
+ }
1268
+ const rr = He({});
1269
+ function nn(n) {
1270
+ const {
1271
+ isVisibled: s,
1272
+ makeInvisible: t,
1273
+ children: a,
1274
+ className: c = "",
1275
+ ...l
1276
+ } = n, u = `arkyn_modal_container ${s ? "visible" : ""} ${c}`;
1277
+ return /* @__PURE__ */ o.jsx(rr.Provider, { value: { makeInvisible: t }, children: /* @__PURE__ */ o.jsx(Tr, { children: s && /* @__PURE__ */ o.jsxs("aside", { className: u.trim(), ...l, children: [
1278
+ /* @__PURE__ */ o.jsx(
1279
+ Ue.div,
1280
+ {
1281
+ className: "overlay",
1282
+ transition: { duration: 0.15, ease: "easeOut" },
1283
+ initial: { opacity: 0 },
1284
+ animate: { opacity: 1 },
1285
+ exit: { opacity: 0 },
1286
+ onClick: t
1287
+ }
1288
+ ),
1289
+ /* @__PURE__ */ o.jsx(
1290
+ Ue.div,
1291
+ {
1292
+ className: "content",
1293
+ transition: { duration: 0.15, ease: "easeOut" },
1294
+ initial: { opacity: 0, scale: 0.75 },
1295
+ animate: { opacity: 1, scale: 1 },
1296
+ exit: { opacity: 0, scale: 0 },
1297
+ children: a
1298
+ }
1299
+ )
1300
+ ] }) }) });
1301
+ }
1302
+ function tn(n) {
1303
+ const { alignment: s = "right", className: t, ...a } = n, c = `arkyn_modal_footer ${s} ${t}`;
1304
+ return /* @__PURE__ */ o.jsx("footer", { className: c.trim(), ...a });
1305
+ }
1306
+ function sn(n) {
1307
+ const { showCloseButton: s, className: t, children: a, ...c } = n, { makeInvisible: l } = Ze(rr), u = `arkyn_modal_header ${s ? "show-close" : ""} ${t}`;
1308
+ return /* @__PURE__ */ o.jsxs("header", { className: u.trim(), ...c, children: [
1309
+ a,
1310
+ /* @__PURE__ */ o.jsx("button", { type: "button", onClick: l, children: /* @__PURE__ */ o.jsx(Nr, { size: 24 }) })
1311
+ ] });
1312
+ }
1313
+ const _n = { Container: nn, Header: sn, Footer: tn };
1314
+ function Rn(n) {
1315
+ const {
1316
+ text: s,
1317
+ size: t = "lg",
1318
+ children: a,
1319
+ orientation: c = "top",
1320
+ className: l,
1321
+ ...h
1322
+ } = n;
1323
+ return /* @__PURE__ */ o.jsxs(
1324
+ "div",
1325
+ {
1326
+ className: `arkyn_tooltip ${t} ${c} ${l}`,
1327
+ ...h,
1328
+ children: [
1329
+ a,
1330
+ /* @__PURE__ */ o.jsx("div", { className: "arkyn_tooltip_text", children: s })
1331
+ ]
1332
+ }
1333
+ );
1334
+ }
1335
+ export {
1336
+ fn as Badge,
1337
+ yn as Breadcrumb,
1338
+ bn as BreadcrumbLink,
1339
+ hn as Button,
1340
+ dn as Divider,
1341
+ mn as FormController,
1342
+ vn as FormError,
1343
+ gn as FormLabel,
1344
+ pn as IconButton,
1345
+ xn as Input,
1346
+ _n as Modal,
1347
+ Rn as Tooltip
1348
+ };