@hortiview/default-components 1.3.0 → 1.4.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 (41) hide show
  1. package/dist/{HealthCheckFailed-BA_vyKwG.js → HealthCheckFailed-CqLYAwpc.js} +12 -11
  2. package/dist/Iconify-Cjdr-ccS.js +82 -0
  3. package/dist/{LoadingSpinner-5JYKhDod.js → LoadingSpinner-FRQEZvxs.js} +26 -25
  4. package/dist/OfflineView-HbuDPpQL-kqlzfoUS.js +46 -0
  5. package/dist/assets/DefaultFormSelect.css +1 -0
  6. package/dist/{component-DsB0poTj-uxpi4oSj.js → component-DsB0poTj-BDGiEcbP.js} +1 -1
  7. package/dist/components/DefaultFormNumber/DefaultFormNumber.js +239 -251
  8. package/dist/components/DefaultFormSelect/DefaultFormSelect.d.ts +14 -0
  9. package/dist/components/DefaultFormSelect/DefaultFormSelect.js +189 -0
  10. package/dist/components/DefaultLoadingSpinner/DefaultLoadingSpinner.js +2 -2
  11. package/dist/components/GenericTable/GenericTable.js +9928 -23562
  12. package/dist/components/HealthChecks/DataBaseHealthCheck.js +2 -2
  13. package/dist/components/HealthChecks/DefaultHealthCheck.js +2 -2
  14. package/dist/components/HealthChecks/IotServiceHealthCheck.js +2 -2
  15. package/dist/components/HealthChecks/PlatformHealthCheck.js +2 -2
  16. package/dist/components/ImpatienceLoadingSpinner/ImpatienceLoadingSpinner.js +2 -2
  17. package/dist/components/OfflineView/OfflineView.js +2 -2
  18. package/dist/index.es--yyG47az-DBKBm3yD.js +825 -0
  19. package/dist/{index.es-CiqbARoC-D-muiSwa.js → index.es-Bx1E5MPK-CaV59rEP.js} +31 -31
  20. package/dist/index.es-CzUKBF7E-C0X-mcdY.js +13567 -0
  21. package/dist/{index.es-D-CKRzIB-DPq2PQz-.js → index.es-D-ph6ImM-CWxTa_iD.js} +15 -15
  22. package/dist/index.es-DDo_AHL0-VqD9ikmU.js +1033 -0
  23. package/dist/index.es-Kg9soDed-BkTwDySy.js +440 -0
  24. package/dist/index.es-U5-b20Gv-ChQ_O81C.js +1010 -0
  25. package/dist/locales/en-US.js +9 -7
  26. package/dist/locales/en-US.json.d.ts +8 -2
  27. package/dist/locales/es-MX.js +8 -6
  28. package/dist/locales/es-MX.json.d.ts +8 -2
  29. package/dist/locales/tr-TR.js +15 -13
  30. package/dist/locales/tr-TR.json.d.ts +8 -2
  31. package/dist/main.d.ts +3 -1
  32. package/dist/main.js +22 -20
  33. package/dist/{index.es-25EARqhH-CciUgLci.js → omit-1Eom1PmQ-BLY9iMqj.js} +748 -1314
  34. package/dist/useHelperText-DD9_Dtkk.js +21 -0
  35. package/dist/useTranslation-B_ODv8uN.js +4306 -0
  36. package/package.json +3 -3
  37. package/dist/Iconify-B42tJF6q.js +0 -979
  38. package/dist/OfflineView-BW19N4Cu-CpgiY6nC.js +0 -45
  39. package/dist/index.es-6TJ1S8Jr-C4X_iaSC.js +0 -1468
  40. package/dist/useTranslation-v0qSkb40.js +0 -4223
  41. /package/dist/assets/{OfflineView-BW19N4Cu.css → OfflineView-HbuDPpQL.css} +0 -0
@@ -1,13 +1,12 @@
1
- import { jsx as at } from "react/jsx-runtime";
2
- import { useFormContext as mt, Controller as Rt } from "react-hook-form";
3
- import X, { useRef as Y, useState as bt, useEffect as vt, useLayoutEffect as kt, useMemo as tt } from "react";
4
- import { t as Wt, u as Lt } from "../../useTranslation-v0qSkb40.js";
5
- import { Z as _t, x as Kt } from "../../index.es-25EARqhH-CciUgLci.js";
6
- import { t as $t } from "../../i18n-CCQpJsQK.js";
1
+ import { jsx as rt } from "react/jsx-runtime";
2
+ import { useFormContext as yt, Controller as Pt } from "react-hook-form";
3
+ import X, { useRef as Y, useState as bt, useEffect as vt, useLayoutEffect as Rt, useMemo as ut } from "react";
4
+ import { a as kt, v as Wt } from "../../useHelperText-DD9_Dtkk.js";
5
+ import { x as _t, M as Kt } from "../../omit-1Eom1PmQ-BLY9iMqj.js";
6
+ import { t as Lt } from "../../i18n-CCQpJsQK.js";
7
7
  import { InternationalizationWrapper as Ut } from "../InternationalizationWrapper/InternationalizationWrapper.js";
8
- import '../../assets/DefaultFormNumber.css';var qt = _t();
9
- const Vt = /* @__PURE__ */ Wt(qt);
10
- function Nt(t, e) {
8
+ import { u as $t } from "../../useTranslation-B_ODv8uN.js";
9
+ import '../../assets/DefaultFormNumber.css';function Vt(t, e) {
11
10
  var r = {};
12
11
  for (var n in t)
13
12
  Object.prototype.hasOwnProperty.call(t, n) && e.indexOf(n) < 0 && (r[n] = t[n]);
@@ -16,13 +15,13 @@ function Nt(t, e) {
16
15
  e.indexOf(n[a]) < 0 && Object.prototype.propertyIsEnumerable.call(t, n[a]) && (r[n[a]] = t[n[a]]);
17
16
  return r;
18
17
  }
19
- var nt;
18
+ var at;
20
19
  (function(t) {
21
20
  t.event = "event", t.props = "prop";
22
- })(nt || (nt = {}));
21
+ })(at || (at = {}));
23
22
  function q() {
24
23
  }
25
- function Zt(t) {
24
+ function qt(t) {
26
25
  var e, r = void 0;
27
26
  return function() {
28
27
  for (var n = [], a = arguments.length; a--; ) n[a] = arguments[a];
@@ -31,7 +30,7 @@ function Zt(t) {
31
30
  }) || (e = n, r = t.apply(void 0, n)), r;
32
31
  };
33
32
  }
34
- function ot(t) {
33
+ function nt(t) {
35
34
  return !!(t || "").match(/\d/);
36
35
  }
37
36
  function Q(t) {
@@ -40,10 +39,10 @@ function Q(t) {
40
39
  function Gt(t) {
41
40
  return typeof t == "number" && isNaN(t);
42
41
  }
43
- function wt(t) {
42
+ function Nt(t) {
44
43
  return Q(t) || Gt(t) || typeof t == "number" && !isFinite(t);
45
44
  }
46
- function Tt(t) {
45
+ function wt(t) {
47
46
  return t.replace(/[-[\]/{}()*+?.\\^$|]/g, "\\$&");
48
47
  }
49
48
  function Ht(t) {
@@ -57,11 +56,11 @@ function Ht(t) {
57
56
  return /(\d)(?=(\d{3})+(?!\d))/g;
58
57
  }
59
58
  }
60
- function zt(t, e, r) {
59
+ function Zt(t, e, r) {
61
60
  var n = Ht(r), a = t.search(/[1-9]/);
62
61
  return a = a === -1 ? t.length : a, t.substring(0, a) + t.substring(a, t.length).replace(n, "$1" + e);
63
62
  }
64
- function Jt(t) {
63
+ function zt(t) {
65
64
  var e = Y(t);
66
65
  e.current = t;
67
66
  var r = Y(function() {
@@ -70,7 +69,7 @@ function Jt(t) {
70
69
  });
71
70
  return r.current;
72
71
  }
73
- function gt(t, e) {
72
+ function mt(t, e) {
74
73
  e === void 0 && (e = !0);
75
74
  var r = t[0] === "-", n = r && e;
76
75
  t = t.replace("-", "");
@@ -82,7 +81,7 @@ function gt(t, e) {
82
81
  addNegation: n
83
82
  };
84
83
  }
85
- function Xt(t) {
84
+ function Jt(t) {
86
85
  if (!t)
87
86
  return t;
88
87
  var e = t[0] === "-";
@@ -90,15 +89,15 @@ function Xt(t) {
90
89
  var r = t.split("."), n = r[0].replace(/^0+/, "") || "0", a = r[1] || "";
91
90
  return (e ? "-" : "") + n + (a ? "." + a : "");
92
91
  }
93
- function Dt(t, e, r) {
92
+ function Tt(t, e, r) {
94
93
  for (var n = "", a = r ? "0" : "", o = 0; o <= e - 1; o++)
95
94
  n += t[o] || a;
96
95
  return n;
97
96
  }
98
- function ht(t, e) {
97
+ function pt(t, e) {
99
98
  return Array(e + 1).join(t);
100
99
  }
101
- function Ct(t) {
100
+ function Dt(t) {
102
101
  var e = t + "", r = e[0] === "-" ? "-" : "";
103
102
  r && (e = e.substring(1));
104
103
  var n = e.split(/[eE]/g), a = n[0], o = n[1];
@@ -106,19 +105,19 @@ function Ct(t) {
106
105
  return r + a;
107
106
  a = a.replace(".", "");
108
107
  var l = 1 + o, d = a.length;
109
- return l < 0 ? a = "0." + ht("0", Math.abs(l)) + a : l >= d ? a = a + ht("0", l - d) : a = (a.substring(0, l) || "0") + "." + a.substring(l), r + a;
108
+ return l < 0 ? a = "0." + pt("0", Math.abs(l)) + a : l >= d ? a = a + pt("0", l - d) : a = (a.substring(0, l) || "0") + "." + a.substring(l), r + a;
110
109
  }
111
- function St(t, e, r) {
110
+ function ht(t, e, r) {
112
111
  if (["", "-"].indexOf(t) !== -1)
113
112
  return t;
114
- var n = (t.indexOf(".") !== -1 || r) && e, a = gt(t), o = a.beforeDecimal, l = a.afterDecimal, d = a.hasNegation, m = parseFloat("0." + (l || "0")), S = l.length <= e ? "0." + l : m.toFixed(e), x = S.split("."), p = o;
115
- o && Number(x[0]) && (p = o.split("").reverse().reduce(function(V, C, g) {
116
- return V.length > g ? (Number(V[0]) + Number(C)).toString() + V.substring(1, V.length) : C + V;
117
- }, x[0]));
118
- var y = Dt(x[1] || "", e, r), h = d ? "-" : "", s = n ? "." : "";
119
- return "" + h + p + s + y;
120
- }
121
- function H(t, e) {
113
+ var n = (t.indexOf(".") !== -1 || r) && e, a = mt(t), o = a.beforeDecimal, l = a.afterDecimal, d = a.hasNegation, m = parseFloat("0." + (l || "0")), x = l.length <= e ? "0." + l : m.toFixed(e), S = x.split("."), p = o;
114
+ o && Number(S[0]) && (p = o.split("").reverse().reduce(function(V, O, g) {
115
+ return V.length > g ? (Number(V[0]) + Number(O)).toString() + V.substring(1, V.length) : O + V;
116
+ }, S[0]));
117
+ var y = Tt(S[1] || "", e, r), h = d ? "-" : "", c = n ? "." : "";
118
+ return "" + h + p + c + y;
119
+ }
120
+ function Z(t, e) {
122
121
  if (t.value = t.value, t !== null) {
123
122
  if (t.createTextRange) {
124
123
  var r = t.createTextRange();
@@ -127,7 +126,7 @@ function H(t, e) {
127
126
  return t.selectionStart || t.selectionStart === 0 ? (t.focus(), t.setSelectionRange(e, e), !0) : (t.focus(), !1);
128
127
  }
129
128
  }
130
- var Ot = Zt(function(t, e) {
129
+ var Ot = qt(function(t, e) {
131
130
  for (var r = 0, n = 0, a = t.length, o = e.length; t[r] === e[r] && r < a; )
132
131
  r++;
133
132
  for (; t[a - 1 - n] === e[o - 1 - n] && o - n > r && a - n > r; )
@@ -136,23 +135,23 @@ var Ot = Zt(function(t, e) {
136
135
  from: { start: r, end: a - n },
137
136
  to: { start: r, end: o - n }
138
137
  };
139
- }), Yt = function(t, e) {
138
+ }), Xt = function(t, e) {
140
139
  var r = Math.min(t.selectionStart, e);
141
140
  return {
142
141
  from: { start: r, end: t.selectionEnd },
143
142
  to: { start: r, end: e }
144
143
  };
145
144
  };
146
- function Qt(t, e, r) {
145
+ function Yt(t, e, r) {
147
146
  return Math.min(Math.max(t, e), r);
148
147
  }
149
148
  function dt(t) {
150
149
  return Math.max(t.selectionStart, t.selectionEnd);
151
150
  }
152
- function te() {
151
+ function Qt() {
153
152
  return typeof navigator < "u" && !(navigator.platform && /iPhone|iPod/.test(navigator.platform));
154
153
  }
155
- function ee(t) {
154
+ function te(t) {
156
155
  return {
157
156
  from: {
158
157
  start: 0,
@@ -165,43 +164,43 @@ function ee(t) {
165
164
  lastValue: ""
166
165
  };
167
166
  }
168
- function re(t) {
167
+ function ee(t) {
169
168
  var e = t.currentValue, r = t.formattedValue, n = t.currentValueIndex, a = t.formattedValueIndex;
170
169
  return e[n] === r[a];
171
170
  }
172
- function ae(t, e, r, n, a, o, l) {
173
- l === void 0 && (l = re);
171
+ function re(t, e, r, n, a, o, l) {
172
+ l === void 0 && (l = ee);
174
173
  var d = a.findIndex(function(k) {
175
174
  return k;
176
175
  }), m = t.slice(0, d);
177
176
  !e && !r.startsWith(m) && (e = m, r = m + r, n = n + m.length);
178
- for (var S = r.length, x = t.length, p = {}, y = new Array(S), h = 0; h < S; h++) {
177
+ for (var x = r.length, S = t.length, p = {}, y = new Array(x), h = 0; h < x; h++) {
179
178
  y[h] = -1;
180
- for (var s = 0, V = x; s < V; s++) {
181
- var C = l({
179
+ for (var c = 0, V = S; c < V; c++) {
180
+ var O = l({
182
181
  currentValue: r,
183
182
  lastValue: e,
184
183
  formattedValue: t,
185
184
  currentValueIndex: h,
186
- formattedValueIndex: s
185
+ formattedValueIndex: c
187
186
  });
188
- if (C && p[s] !== !0) {
189
- y[h] = s, p[s] = !0;
187
+ if (O && p[c] !== !0) {
188
+ y[h] = c, p[c] = !0;
190
189
  break;
191
190
  }
192
191
  }
193
192
  }
194
- for (var g = n; g < S && (y[g] === -1 || !o(r[g])); )
193
+ for (var g = n; g < x && (y[g] === -1 || !o(r[g])); )
195
194
  g++;
196
- var B = g === S || y[g] === -1 ? x : y[g];
195
+ var E = g === x || y[g] === -1 ? S : y[g];
197
196
  for (g = n - 1; g > 0 && y[g] === -1; )
198
197
  g--;
199
198
  var j = g === -1 || y[g] === -1 ? 0 : y[g] + 1;
200
- return j > B ? B : n - j < B - n ? j : B;
199
+ return j > E ? E : n - j < E - n ? j : E;
201
200
  }
202
- function xt(t, e, r, n) {
201
+ function St(t, e, r, n) {
203
202
  var a = t.length;
204
- if (e = Qt(e, 0, a), n === "left") {
203
+ if (e = Yt(e, 0, a), n === "left") {
205
204
  for (; e >= 0 && !r[e]; )
206
205
  e--;
207
206
  e === -1 && (e = r.indexOf(!0));
@@ -212,64 +211,64 @@ function xt(t, e, r, n) {
212
211
  }
213
212
  return e === -1 && (e = a), e;
214
213
  }
215
- function ne(t) {
214
+ function ae(t) {
216
215
  for (var e = Array.from({ length: t.length + 1 }).map(function() {
217
216
  return !0;
218
217
  }), r = 0, n = e.length; r < n; r++)
219
- e[r] = !!(ot(t[r]) || ot(t[r - 1]));
218
+ e[r] = !!(nt(t[r]) || nt(t[r - 1]));
220
219
  return e;
221
220
  }
222
- function At(t, e, r, n, a, o) {
221
+ function Ct(t, e, r, n, a, o) {
223
222
  o === void 0 && (o = q);
224
- var l = Jt(function(s, V) {
225
- var C, g;
226
- return wt(s) ? (g = "", C = "") : typeof s == "number" || V ? (g = typeof s == "number" ? Ct(s) : s, C = n(g)) : (g = a(s, void 0), C = n(g)), { formattedValue: C, numAsString: g };
223
+ var l = zt(function(c, V) {
224
+ var O, g;
225
+ return Nt(c) ? (g = "", O = "") : typeof c == "number" || V ? (g = typeof c == "number" ? Dt(c) : c, O = n(g)) : (g = a(c, void 0), O = n(g)), { formattedValue: O, numAsString: g };
227
226
  }), d = bt(function() {
228
227
  return l(Q(t) ? e : t, r);
229
- }), m = d[0], S = d[1], x = function(s, V) {
230
- s.formattedValue !== m.formattedValue && S({
231
- formattedValue: s.formattedValue,
232
- numAsString: s.value
233
- }), o(s, V);
228
+ }), m = d[0], x = d[1], S = function(c, V) {
229
+ c.formattedValue !== m.formattedValue && x({
230
+ formattedValue: c.formattedValue,
231
+ numAsString: c.value
232
+ }), o(c, V);
234
233
  }, p = t, y = r;
235
234
  Q(t) && (p = m.numAsString, y = !0);
236
235
  var h = l(p, y);
237
- return tt(function() {
238
- S(h);
239
- }, [h.formattedValue]), [m, x];
236
+ return ut(function() {
237
+ x(h);
238
+ }, [h.formattedValue]), [m, S];
240
239
  }
241
- function oe(t) {
240
+ function ne(t) {
242
241
  return t.replace(/[^0-9]/g, "");
243
242
  }
244
- function ue(t) {
243
+ function oe(t) {
245
244
  return t;
246
245
  }
247
- function ie(t) {
246
+ function ue(t) {
248
247
  var e = t.type;
249
248
  e === void 0 && (e = "text");
250
249
  var r = t.displayType;
251
250
  r === void 0 && (r = "input");
252
251
  var n = t.customInput, a = t.renderText, o = t.getInputRef, l = t.format;
253
- l === void 0 && (l = ue);
252
+ l === void 0 && (l = oe);
254
253
  var d = t.removeFormatting;
255
- d === void 0 && (d = oe);
256
- var m = t.defaultValue, S = t.valueIsNumericString, x = t.onValueChange, p = t.isAllowed, y = t.onChange;
254
+ d === void 0 && (d = ne);
255
+ var m = t.defaultValue, x = t.valueIsNumericString, S = t.onValueChange, p = t.isAllowed, y = t.onChange;
257
256
  y === void 0 && (y = q);
258
257
  var h = t.onKeyDown;
259
258
  h === void 0 && (h = q);
260
- var s = t.onMouseUp;
261
- s === void 0 && (s = q);
259
+ var c = t.onMouseUp;
260
+ c === void 0 && (c = q);
262
261
  var V = t.onFocus;
263
262
  V === void 0 && (V = q);
264
- var C = t.onBlur;
265
- C === void 0 && (C = q);
266
- var g = t.value, B = t.getCaretBoundary;
267
- B === void 0 && (B = ne);
263
+ var O = t.onBlur;
264
+ O === void 0 && (O = q);
265
+ var g = t.value, E = t.getCaretBoundary;
266
+ E === void 0 && (E = ae);
268
267
  var j = t.isValidInputCharacter;
269
- j === void 0 && (j = ot);
270
- var k = t.isCharacterSame, M = Nt(t, ["type", "displayType", "customInput", "renderText", "getInputRef", "format", "removeFormatting", "defaultValue", "valueIsNumericString", "onValueChange", "isAllowed", "onChange", "onKeyDown", "onMouseUp", "onFocus", "onBlur", "value", "getCaretBoundary", "isValidInputCharacter", "isCharacterSame"]), Z = At(g, m, !!S, l, d, x), W = Z[0], N = W.formattedValue, P = W.numAsString, G = Z[1], R = Y(), _ = Y({ formattedValue: N, numAsString: P }), K = function(u, i) {
271
- _.current = { formattedValue: u.formattedValue, numAsString: u.value }, G(u, i);
272
- }, z = bt(!1), et = z[0], v = z[1], c = Y(null), w = Y({
268
+ j === void 0 && (j = nt);
269
+ var k = t.isCharacterSame, M = Vt(t, ["type", "displayType", "customInput", "renderText", "getInputRef", "format", "removeFormatting", "defaultValue", "valueIsNumericString", "onValueChange", "isAllowed", "onChange", "onKeyDown", "onMouseUp", "onFocus", "onBlur", "value", "getCaretBoundary", "isValidInputCharacter", "isCharacterSame"]), G = Ct(g, m, !!x, l, d, S), W = G[0], N = W.formattedValue, P = W.numAsString, H = G[1], R = Y(), K = Y({ formattedValue: N, numAsString: P }), L = function(u, i) {
270
+ K.current = { formattedValue: u.formattedValue, numAsString: u.value }, H(u, i);
271
+ }, z = bt(!1), tt = z[0], v = z[1], s = Y(null), w = Y({
273
272
  setCaretTimeout: null,
274
273
  focusTimeout: null
275
274
  });
@@ -285,119 +284,119 @@ function ie(t) {
285
284
  value: i,
286
285
  floatValue: isNaN(f) ? void 0 : f
287
286
  };
288
- }, O = function(u, i, f) {
289
- u.selectionStart === 0 && u.selectionEnd === u.value.length || (H(u, i), w.current.setCaretTimeout = setTimeout(function() {
290
- u.value === f && u.selectionStart !== i && H(u, i);
287
+ }, C = function(u, i, f) {
288
+ u.selectionStart === 0 && u.selectionEnd === u.value.length || (Z(u, i), w.current.setCaretTimeout = setTimeout(function() {
289
+ u.value === f && u.selectionStart !== i && Z(u, i);
291
290
  }, 0));
292
- }, E = function(u, i, f) {
293
- return xt(u, i, B(u), f);
291
+ }, B = function(u, i, f) {
292
+ return St(u, i, E(u), f);
294
293
  }, J = function(u, i, f) {
295
- var T = B(i), F = ae(i, N, u, f, T, j, k);
296
- return F = xt(i, F, T), F;
294
+ var T = E(i), F = re(i, N, u, f, T, j, k);
295
+ return F = St(i, F, T), F;
297
296
  }, lt = function(u) {
298
297
  var i = u.formattedValue;
299
298
  i === void 0 && (i = "");
300
299
  var f = u.input, T = u.source, F = u.event, D = u.numAsString, b;
301
300
  if (f) {
302
- var L = u.inputValue || f.value, $ = dt(f);
303
- f.value = i, b = J(L, i, $), b !== void 0 && O(f, b, i);
301
+ var _ = u.inputValue || f.value, U = dt(f);
302
+ f.value = i, b = J(_, i, U), b !== void 0 && C(f, b, i);
304
303
  }
305
- i !== N && K(I(i, D), { event: F, source: T });
304
+ i !== N && L(I(i, D), { event: F, source: T });
306
305
  };
307
306
  vt(function() {
308
- var u = _.current, i = u.formattedValue, f = u.numAsString;
309
- (N !== i || P !== f) && K(I(N, P), {
307
+ var u = K.current, i = u.formattedValue, f = u.numAsString;
308
+ (N !== i || P !== f) && L(I(N, P), {
310
309
  event: void 0,
311
- source: nt.props
310
+ source: at.props
312
311
  });
313
312
  }, [N, P]);
314
- var rt = c.current ? dt(c.current) : void 0, ut = typeof window < "u" ? kt : vt;
315
- ut(function() {
316
- var u = c.current;
317
- if (N !== _.current.formattedValue && u) {
318
- var i = J(_.current.formattedValue, N, rt);
319
- u.value = N, O(u, i, N);
313
+ var et = s.current ? dt(s.current) : void 0, ot = typeof window < "u" ? Rt : vt;
314
+ ot(function() {
315
+ var u = s.current;
316
+ if (N !== K.current.formattedValue && u) {
317
+ var i = J(K.current.formattedValue, N, et);
318
+ u.value = N, C(u, i, N);
320
319
  }
321
320
  }, [N]);
322
- var st = function(u, i, f) {
323
- var T = i.target, F = R.current ? Yt(R.current, T.selectionEnd) : Ot(N, u), D = Object.assign(Object.assign({}, F), { lastValue: N }), b = d(u, D), L = A(b);
324
- if (b = d(L, void 0), p && !p(I(L, b))) {
325
- var $ = i.target, U = dt($), ft = J(u, N, U);
326
- return $.value = N, O($, ft, N), !1;
321
+ var ct = function(u, i, f) {
322
+ var T = i.target, F = R.current ? Xt(R.current, T.selectionEnd) : Ot(N, u), D = Object.assign(Object.assign({}, F), { lastValue: N }), b = d(u, D), _ = A(b);
323
+ if (b = d(_, void 0), p && !p(I(_, b))) {
324
+ var U = i.target, $ = dt(U), ft = J(u, N, $);
325
+ return U.value = N, C(U, ft, N), !1;
327
326
  }
328
327
  return lt({
329
- formattedValue: L,
328
+ formattedValue: _,
330
329
  numAsString: b,
331
330
  inputValue: u,
332
331
  event: i,
333
332
  source: f,
334
333
  input: i.target
335
334
  }), !0;
336
- }, ct = function(u, i) {
335
+ }, st = function(u, i) {
337
336
  i === void 0 && (i = 0);
338
337
  var f = u.selectionStart, T = u.selectionEnd;
339
338
  R.current = { selectionStart: f, selectionEnd: T + i };
340
- }, It = function(u) {
341
- var i = u.target, f = i.value, T = st(f, u, nt.event);
339
+ }, At = function(u) {
340
+ var i = u.target, f = i.value, T = ct(f, u, at.event);
342
341
  T && y(u), R.current = void 0;
343
- }, Et = function(u) {
342
+ }, It = function(u) {
344
343
  var i = u.target, f = u.key, T = i.selectionStart, F = i.selectionEnd, D = i.value;
345
344
  D === void 0 && (D = "");
346
345
  var b;
347
346
  f === "ArrowLeft" || f === "Backspace" ? b = Math.max(T - 1, 0) : f === "ArrowRight" ? b = Math.min(T + 1, D.length) : f === "Delete" && (b = T);
348
- var L = 0;
349
- f === "Delete" && T === F && (L = 1);
350
- var $ = f === "ArrowLeft" || f === "ArrowRight";
351
- if (b === void 0 || T !== F && !$) {
352
- h(u), ct(i, L);
347
+ var _ = 0;
348
+ f === "Delete" && T === F && (_ = 1);
349
+ var U = f === "ArrowLeft" || f === "ArrowRight";
350
+ if (b === void 0 || T !== F && !U) {
351
+ h(u), st(i, _);
353
352
  return;
354
353
  }
355
- var U = b;
356
- if ($) {
354
+ var $ = b;
355
+ if (U) {
357
356
  var ft = f === "ArrowLeft" ? "left" : "right";
358
- U = E(D, b, ft), U !== b && u.preventDefault();
359
- } else f === "Delete" && !j(D[b]) ? U = E(D, b, "right") : f === "Backspace" && !j(D[b]) && (U = E(D, b, "left"));
360
- U !== b && O(i, U, D), h(u), ct(i, L);
357
+ $ = B(D, b, ft), $ !== b && u.preventDefault();
358
+ } else f === "Delete" && !j(D[b]) ? $ = B(D, b, "right") : f === "Backspace" && !j(D[b]) && ($ = B(D, b, "left"));
359
+ $ !== b && C(i, $, D), h(u), st(i, _);
361
360
  }, Bt = function(u) {
362
361
  var i = u.target, f = function() {
363
362
  var T = i.selectionStart, F = i.selectionEnd, D = i.value;
364
363
  if (D === void 0 && (D = ""), T === F) {
365
- var b = E(D, T);
366
- b !== T && O(i, b, D);
364
+ var b = B(D, T);
365
+ b !== T && C(i, b, D);
367
366
  }
368
367
  };
369
368
  f(), requestAnimationFrame(function() {
370
369
  f();
371
- }), s(u), ct(i);
372
- }, jt = function(u) {
370
+ }), c(u), st(i);
371
+ }, Et = function(u) {
373
372
  u.persist && u.persist();
374
373
  var i = u.target, f = u.currentTarget;
375
- c.current = i, w.current.focusTimeout = setTimeout(function() {
374
+ s.current = i, w.current.focusTimeout = setTimeout(function() {
376
375
  var T = i.selectionStart, F = i.selectionEnd, D = i.value;
377
376
  D === void 0 && (D = "");
378
- var b = E(D, T);
379
- b !== T && !(T === 0 && F === D.length) && O(i, b, D), V(Object.assign(Object.assign({}, u), { currentTarget: f }));
377
+ var b = B(D, T);
378
+ b !== T && !(T === 0 && F === D.length) && C(i, b, D), V(Object.assign(Object.assign({}, u), { currentTarget: f }));
380
379
  }, 0);
381
- }, Ft = function(u) {
382
- c.current = null, clearTimeout(w.current.focusTimeout), clearTimeout(w.current.setCaretTimeout), C(u);
383
- }, Mt = et && te() ? "numeric" : void 0, pt = Object.assign({ inputMode: Mt }, M, {
380
+ }, jt = function(u) {
381
+ s.current = null, clearTimeout(w.current.focusTimeout), clearTimeout(w.current.setCaretTimeout), O(u);
382
+ }, Ft = tt && Qt() ? "numeric" : void 0, gt = Object.assign({ inputMode: Ft }, M, {
384
383
  type: e,
385
384
  value: N,
386
- onChange: It,
387
- onKeyDown: Et,
385
+ onChange: At,
386
+ onKeyDown: It,
388
387
  onMouseUp: Bt,
389
- onFocus: jt,
390
- onBlur: Ft
388
+ onFocus: Et,
389
+ onBlur: jt
391
390
  });
392
391
  if (r === "text")
393
392
  return a ? X.createElement(X.Fragment, null, a(N, M) || null) : X.createElement("span", Object.assign({}, M, { ref: o }), N);
394
393
  if (n) {
395
- var Pt = n;
396
- return X.createElement(Pt, Object.assign({}, pt, { ref: o }));
394
+ var Mt = n;
395
+ return X.createElement(Mt, Object.assign({}, gt, { ref: o }));
397
396
  }
398
- return X.createElement("input", Object.assign({}, pt, { ref: o }));
397
+ return X.createElement("input", Object.assign({}, gt, { ref: o }));
399
398
  }
400
- function yt(t, e) {
399
+ function xt(t, e) {
401
400
  var r = e.decimalScale, n = e.fixedDecimalScale, a = e.prefix;
402
401
  a === void 0 && (a = "");
403
402
  var o = e.suffix;
@@ -405,8 +404,8 @@ function yt(t, e) {
405
404
  var l = e.allowNegative, d = e.thousandsGroupStyle;
406
405
  if (d === void 0 && (d = "thousand"), t === "" || t === "-")
407
406
  return t;
408
- var m = it(e), S = m.thousandSeparator, x = m.decimalSeparator, p = r !== 0 && t.indexOf(".") !== -1 || r && n, y = gt(t, l), h = y.beforeDecimal, s = y.afterDecimal, V = y.addNegation;
409
- return r !== void 0 && (s = Dt(s, r, !!n)), S && (h = zt(h, S, d)), a && (h = a + h), o && (s = s + o), V && (h = "-" + h), t = h + (p && x || "") + s, t;
407
+ var m = it(e), x = m.thousandSeparator, S = m.decimalSeparator, p = r !== 0 && t.indexOf(".") !== -1 || r && n, y = mt(t, l), h = y.beforeDecimal, c = y.afterDecimal, V = y.addNegation;
408
+ return r !== void 0 && (c = Tt(c, r, !!n)), x && (h = Zt(h, x, d)), a && (h = a + h), o && (c = c + o), V && (h = "-" + h), t = h + (p && S || "") + c, t;
410
409
  }
411
410
  function it(t) {
412
411
  var e = t.decimalSeparator;
@@ -418,52 +417,52 @@ function it(t) {
418
417
  allowedDecimalSeparators: n
419
418
  };
420
419
  }
421
- function le(t, e) {
420
+ function ie(t, e) {
422
421
  t === void 0 && (t = "");
423
422
  var r = new RegExp("(-)"), n = new RegExp("(-)(.)*(-)"), a = r.test(t), o = n.test(t);
424
423
  return t = t.replace(/-/g, ""), a && !o && e && (t = "-" + t), t;
425
424
  }
426
- function se(t, e) {
427
- return new RegExp("(^-)|[0-9]|" + Tt(t), "g");
425
+ function le(t, e) {
426
+ return new RegExp("(^-)|[0-9]|" + wt(t), "g");
428
427
  }
429
428
  function ce(t, e, r) {
430
429
  return t === "" ? !0 : !(e != null && e.match(/\d/)) && !(r != null && r.match(/\d/)) && typeof t == "string" && !isNaN(Number(t));
431
430
  }
432
- function fe(t, e, r) {
431
+ function se(t, e, r) {
433
432
  var n;
434
- e === void 0 && (e = ee(t));
433
+ e === void 0 && (e = te(t));
435
434
  var a = r.allowNegative, o = r.prefix;
436
435
  o === void 0 && (o = "");
437
436
  var l = r.suffix;
438
437
  l === void 0 && (l = "");
439
- var d = r.decimalScale, m = e.from, S = e.to, x = S.start, p = S.end, y = it(r), h = y.allowedDecimalSeparators, s = y.decimalSeparator, V = t[p] === s;
440
- if (ot(t) && (t === o || t === l) && e.lastValue === "")
438
+ var d = r.decimalScale, m = e.from, x = e.to, S = x.start, p = x.end, y = it(r), h = y.allowedDecimalSeparators, c = y.decimalSeparator, V = t[p] === c;
439
+ if (nt(t) && (t === o || t === l) && e.lastValue === "")
441
440
  return t;
442
- if (p - x === 1 && h.indexOf(t[x]) !== -1) {
443
- var C = d === 0 ? "" : s;
444
- t = t.substring(0, x) + C + t.substring(x + 1, t.length);
441
+ if (p - S === 1 && h.indexOf(t[S]) !== -1) {
442
+ var O = d === 0 ? "" : c;
443
+ t = t.substring(0, S) + O + t.substring(S + 1, t.length);
445
444
  }
446
- var g = function(c, w, A) {
447
- var I = !1, O = !1;
448
- o.startsWith("-") ? I = !1 : c.startsWith("--") ? (I = !1, O = !0) : l.startsWith("-") && c.length === l.length ? I = !1 : c[0] === "-" && (I = !0);
449
- var E = I ? 1 : 0;
450
- return O && (E = 2), E && (c = c.substring(E), w -= E, A -= E), { value: c, start: w, end: A, hasNegation: I };
451
- }, B = g(t, x, p), j = B.hasNegation;
452
- n = B, t = n.value, x = n.start, p = n.end;
453
- var k = g(e.lastValue, m.start, m.end), M = k.start, Z = k.end, W = k.value, N = t.substring(x, p);
454
- t.length && W.length && (M > W.length - l.length || Z < o.length) && !(N && l.startsWith(N)) && (t = W);
445
+ var g = function(s, w, A) {
446
+ var I = !1, C = !1;
447
+ o.startsWith("-") ? I = !1 : s.startsWith("--") ? (I = !1, C = !0) : l.startsWith("-") && s.length === l.length ? I = !1 : s[0] === "-" && (I = !0);
448
+ var B = I ? 1 : 0;
449
+ return C && (B = 2), B && (s = s.substring(B), w -= B, A -= B), { value: s, start: w, end: A, hasNegation: I };
450
+ }, E = g(t, S, p), j = E.hasNegation;
451
+ n = E, t = n.value, S = n.start, p = n.end;
452
+ var k = g(e.lastValue, m.start, m.end), M = k.start, G = k.end, W = k.value, N = t.substring(S, p);
453
+ t.length && W.length && (M > W.length - l.length || G < o.length) && !(N && l.startsWith(N)) && (t = W);
455
454
  var P = 0;
456
- t.startsWith(o) ? P += o.length : x < o.length && (P = x), t = t.substring(P), p -= P;
457
- var G = t.length, R = t.length - l.length;
458
- t.endsWith(l) ? G = R : (p > R || p > t.length - l.length) && (G = p), t = t.substring(0, G), t = le(j ? "-" + t : t, a), t = (t.match(se(s)) || []).join("");
459
- var _ = t.indexOf(s);
460
- t = t.replace(new RegExp(Tt(s), "g"), function(c, w) {
461
- return w === _ ? "." : "";
455
+ t.startsWith(o) ? P += o.length : S < o.length && (P = S), t = t.substring(P), p -= P;
456
+ var H = t.length, R = t.length - l.length;
457
+ t.endsWith(l) ? H = R : (p > R || p > t.length - l.length) && (H = p), t = t.substring(0, H), t = ie(j ? "-" + t : t, a), t = (t.match(le(c)) || []).join("");
458
+ var K = t.indexOf(c);
459
+ t = t.replace(new RegExp(wt(c), "g"), function(s, w) {
460
+ return w === K ? "." : "";
462
461
  });
463
- var K = gt(t, a), z = K.beforeDecimal, et = K.afterDecimal, v = K.addNegation;
464
- return S.end - S.start < m.end - m.start && z === "" && V && !parseFloat(et) && (t = v ? "-" : ""), t;
462
+ var L = mt(t, a), z = L.beforeDecimal, tt = L.afterDecimal, v = L.addNegation;
463
+ return x.end - x.start < m.end - m.start && z === "" && V && !parseFloat(tt) && (t = v ? "-" : ""), t;
465
464
  }
466
- function ve(t, e) {
465
+ function fe(t, e) {
467
466
  var r = e.prefix;
468
467
  r === void 0 && (r = "");
469
468
  var n = e.suffix;
@@ -475,7 +474,7 @@ function ve(t, e) {
475
474
  var l = t.length;
476
475
  return a.fill(!1, l - n.length + 1, l + 1), a;
477
476
  }
478
- function de(t) {
477
+ function ve(t) {
479
478
  var e = it(t), r = e.thousandSeparator, n = e.decimalSeparator, a = t.prefix;
480
479
  a === void 0 && (a = "");
481
480
  var o = t.allowNegative;
@@ -491,25 +490,25 @@ function de(t) {
491
490
  allowNegative: ` + o + `
492
491
  `), o = !1), Object.assign(Object.assign({}, t), { allowNegative: o });
493
492
  }
494
- function me(t) {
495
- t = de(t), t.decimalSeparator, t.allowedDecimalSeparators, t.thousandsGroupStyle;
493
+ function de(t) {
494
+ t = ve(t), t.decimalSeparator, t.allowedDecimalSeparators, t.thousandsGroupStyle;
496
495
  var e = t.suffix, r = t.allowNegative, n = t.allowLeadingZeros, a = t.onKeyDown;
497
496
  a === void 0 && (a = q);
498
497
  var o = t.onBlur;
499
498
  o === void 0 && (o = q);
500
- var l = t.thousandSeparator, d = t.decimalScale, m = t.fixedDecimalScale, S = t.prefix;
501
- S === void 0 && (S = "");
502
- var x = t.defaultValue, p = t.value, y = t.valueIsNumericString, h = t.onValueChange, s = Nt(t, ["decimalSeparator", "allowedDecimalSeparators", "thousandsGroupStyle", "suffix", "allowNegative", "allowLeadingZeros", "onKeyDown", "onBlur", "thousandSeparator", "decimalScale", "fixedDecimalScale", "prefix", "defaultValue", "value", "valueIsNumericString", "onValueChange"]), V = it(t), C = V.decimalSeparator, g = V.allowedDecimalSeparators, B = function(v) {
503
- return yt(v, t);
504
- }, j = function(v, c) {
505
- return fe(v, c, t);
506
- }, k = Q(p) ? x : p, M = y ?? ce(k, S, e);
507
- Q(p) ? Q(x) || (M = M || typeof x == "number") : M = M || typeof p == "number";
508
- var Z = function(v) {
509
- return wt(v) ? v : (typeof v == "number" && (v = Ct(v)), M && typeof d == "number" ? St(v, d, !!m) : v);
510
- }, W = At(Z(p), Z(x), !!M, B, j, h), N = W[0], P = N.numAsString, G = N.formattedValue, R = W[1], _ = function(v) {
511
- var c = v.target, w = v.key, A = c.selectionStart, I = c.selectionEnd, O = c.value;
512
- if (O === void 0 && (O = ""), (w === "Backspace" || w === "Delete") && I < S.length) {
499
+ var l = t.thousandSeparator, d = t.decimalScale, m = t.fixedDecimalScale, x = t.prefix;
500
+ x === void 0 && (x = "");
501
+ var S = t.defaultValue, p = t.value, y = t.valueIsNumericString, h = t.onValueChange, c = Vt(t, ["decimalSeparator", "allowedDecimalSeparators", "thousandsGroupStyle", "suffix", "allowNegative", "allowLeadingZeros", "onKeyDown", "onBlur", "thousandSeparator", "decimalScale", "fixedDecimalScale", "prefix", "defaultValue", "value", "valueIsNumericString", "onValueChange"]), V = it(t), O = V.decimalSeparator, g = V.allowedDecimalSeparators, E = function(v) {
502
+ return xt(v, t);
503
+ }, j = function(v, s) {
504
+ return se(v, s, t);
505
+ }, k = Q(p) ? S : p, M = y ?? ce(k, x, e);
506
+ Q(p) ? Q(S) || (M = M || typeof S == "number") : M = M || typeof p == "number";
507
+ var G = function(v) {
508
+ return Nt(v) ? v : (typeof v == "number" && (v = Dt(v)), M && typeof d == "number" ? ht(v, d, !!m) : v);
509
+ }, W = Ct(G(p), G(S), !!M, E, j, h), N = W[0], P = N.numAsString, H = N.formattedValue, R = W[1], K = function(v) {
510
+ var s = v.target, w = v.key, A = s.selectionStart, I = s.selectionEnd, C = s.value;
511
+ if (C === void 0 && (C = ""), (w === "Backspace" || w === "Delete") && I < x.length) {
513
512
  v.preventDefault();
514
513
  return;
515
514
  }
@@ -517,89 +516,78 @@ function me(t) {
517
516
  a(v);
518
517
  return;
519
518
  }
520
- w === "Backspace" && O[0] === "-" && A === S.length + 1 && r && H(c, 1), d && m && (w === "Backspace" && O[A - 1] === C ? (H(c, A - 1), v.preventDefault()) : w === "Delete" && O[A] === C && v.preventDefault()), g != null && g.includes(w) && O[A] === C && H(c, A + 1);
521
- var E = l === !0 ? "," : l;
522
- w === "Backspace" && O[A - 1] === E && H(c, A - 1), w === "Delete" && O[A] === E && H(c, A + 1), a(v);
523
- }, K = function(v) {
524
- var c = P;
525
- if (c.match(/\d/g) || (c = ""), n || (c = Xt(c)), m && d && (c = St(c, d, m)), c !== P) {
526
- var w = yt(c, t);
519
+ w === "Backspace" && C[0] === "-" && A === x.length + 1 && r && Z(s, 1), d && m && (w === "Backspace" && C[A - 1] === O ? (Z(s, A - 1), v.preventDefault()) : w === "Delete" && C[A] === O && v.preventDefault()), g != null && g.includes(w) && C[A] === O && Z(s, A + 1);
520
+ var B = l === !0 ? "," : l;
521
+ w === "Backspace" && C[A - 1] === B && Z(s, A - 1), w === "Delete" && C[A] === B && Z(s, A + 1), a(v);
522
+ }, L = function(v) {
523
+ var s = P;
524
+ if (s.match(/\d/g) || (s = ""), n || (s = Jt(s)), m && d && (s = ht(s, d, m)), s !== P) {
525
+ var w = xt(s, t);
527
526
  R({
528
527
  formattedValue: w,
529
- value: c,
530
- floatValue: parseFloat(c)
528
+ value: s,
529
+ floatValue: parseFloat(s)
531
530
  }, {
532
531
  event: v,
533
- source: nt.event
532
+ source: at.event
534
533
  });
535
534
  }
536
535
  o(v);
537
536
  }, z = function(v) {
538
- return v === C ? !0 : ot(v);
539
- }, et = function(v) {
540
- var c = v.currentValue, w = v.lastValue, A = v.formattedValue, I = v.currentValueIndex, O = v.formattedValueIndex, E = c[I], J = A[O], lt = Ot(w, c), rt = lt.to, ut = function(st) {
541
- return j(st).indexOf(".") + S.length;
537
+ return v === O ? !0 : nt(v);
538
+ }, tt = function(v) {
539
+ var s = v.currentValue, w = v.lastValue, A = v.formattedValue, I = v.currentValueIndex, C = v.formattedValueIndex, B = s[I], J = A[C], lt = Ot(w, s), et = lt.to, ot = function(ct) {
540
+ return j(ct).indexOf(".") + x.length;
542
541
  };
543
- return p === 0 && m && d && c[rt.start] === C && ut(c) < I && ut(A) > O ? !1 : I >= rt.start && I < rt.end && g && g.includes(E) && J === C ? !0 : E === J;
542
+ return p === 0 && m && d && s[et.start] === O && ot(s) < I && ot(A) > C ? !1 : I >= et.start && I < et.end && g && g.includes(B) && J === O ? !0 : B === J;
544
543
  };
545
- return Object.assign(Object.assign({}, s), {
546
- value: G,
544
+ return Object.assign(Object.assign({}, c), {
545
+ value: H,
547
546
  valueIsNumericString: !1,
548
547
  isValidInputCharacter: z,
549
- isCharacterSame: et,
548
+ isCharacterSame: tt,
550
549
  onValueChange: R,
551
- format: B,
550
+ format: E,
552
551
  removeFormatting: j,
553
552
  getCaretBoundary: function(v) {
554
- return ve(v, t);
553
+ return fe(v, t);
555
554
  },
556
- onKeyDown: _,
557
- onBlur: K
555
+ onKeyDown: K,
556
+ onBlur: L
558
557
  });
559
558
  }
560
- function ge(t) {
561
- var e = me(t);
562
- return X.createElement(ie, Object.assign({}, e));
559
+ function me(t) {
560
+ var e = de(t);
561
+ return X.createElement(ue, Object.assign({}, e));
563
562
  }
564
- function pe(t) {
565
- return tt(() => {
563
+ function ge(t) {
564
+ return ut(() => {
566
565
  var r;
567
566
  return ((r = Intl.NumberFormat(t).formatToParts(1234.45).find((n) => n.type === "decimal")) == null ? void 0 : r.value) || ".";
568
567
  }, [t]);
569
568
  }
570
- function he(t) {
571
- return tt(() => {
569
+ function pe(t) {
570
+ return ut(() => {
572
571
  var r;
573
572
  return ((r = Intl.NumberFormat(t).formatToParts(1234.45).find((n) => n.type === "group")) == null ? void 0 : r.value) || ",";
574
573
  }, [t]);
575
574
  }
576
- const Se = ({
577
- propertyName: t,
578
- requiredText: e,
579
- maxLength: r,
580
- helperText: n = null,
581
- hasCharacterCount: a = !1
582
- }) => {
583
- const {
584
- formState: { errors: o }
585
- } = mt(), l = Vt(o, t), d = tt(() => l ? l.message || "Invalid input" : n ?? e, [l, n, e]), m = tt(() => !!(l || a && r || e || n), [l, a, r, e, n]);
586
- return { helperText: d, helperTextPersistent: m };
587
- }, xe = "_invalid_1dsbr_1", ye = {
588
- invalid: xe
589
- }, be = ({ ...t }) => {
575
+ const he = "_invalid_1dsbr_1", Se = {
576
+ invalid: he
577
+ }, xe = ({ ...t }) => {
590
578
  const {
591
579
  getFieldState: e,
592
580
  formState: { errors: r },
593
581
  trigger: n,
594
582
  watch: a
595
- } = mt(), o = a(t.propertyName), l = tt(() => {
583
+ } = yt(), o = a(t.propertyName), l = ut(() => {
596
584
  if (!(!o || t.value === null))
597
585
  return t.value;
598
586
  }, [o, t.value]);
599
- return /* @__PURE__ */ at(
600
- Kt,
587
+ return /* @__PURE__ */ rt(
588
+ _t,
601
589
  {
602
- ...t,
590
+ ...Kt(t, ["propertyName", "formOnBlur", "additionalTrigger"]),
603
591
  value: l,
604
592
  "data-testid": `numeric-field-${t.propertyName}`,
605
593
  fullWidth: !0,
@@ -614,11 +602,11 @@ const Se = ({
614
602
  (m = t.onChange) == null || m.call(t, d), t.additionalTrigger === "onChange" && n(t.propertyName);
615
603
  },
616
604
  valid: !e(t.propertyName).invalid,
617
- helperTextPersistent: Vt(r, t.propertyName) !== void 0 || t.helperTextPersistent,
618
- className: e(t.propertyName).invalid ? ye.invalid : ""
605
+ helperTextPersistent: kt(r, t.propertyName) !== void 0 || t.helperTextPersistent,
606
+ className: e(t.propertyName).invalid ? Se.invalid : ""
619
607
  }
620
608
  );
621
- }, Ve = ({
609
+ }, ye = ({
622
610
  /**numeric format props */
623
611
  decimalScale: t = 2,
624
612
  /** TextField props */
@@ -628,34 +616,34 @@ const Se = ({
628
616
  additionalTrigger: n = "none",
629
617
  ...a
630
618
  }) => {
631
- const { control: o } = mt(), { helperText: l, helperTextPersistent: d } = Se({
619
+ const { control: o } = yt(), { helperText: l, helperTextPersistent: d } = Wt({
632
620
  propertyName: a.propertyName,
633
621
  helperText: a.helperText,
634
622
  hasCharacterCount: !1
635
- }), m = pe(r), S = he(r);
636
- return /* @__PURE__ */ at(
637
- Rt,
623
+ }), m = ge(r), x = pe(r);
624
+ return /* @__PURE__ */ rt(
625
+ Pt,
638
626
  {
639
627
  name: a.propertyName,
640
628
  control: o,
641
- render: ({ field: { value: x, onChange: p, onBlur: y } }) => /* @__PURE__ */ at(
642
- ge,
629
+ render: ({ field: { value: S, onChange: p, onBlur: y } }) => /* @__PURE__ */ rt(
630
+ me,
643
631
  {
644
632
  "data-testid": `form-number-${a.propertyName}`,
645
633
  ...a,
646
634
  valueIsNumericString: !0,
647
- value: x,
635
+ value: S,
648
636
  onValueChange: (h) => {
649
637
  h.value === "" ? p(null) : p(Number(h.value));
650
638
  },
651
639
  decimalSeparator: m,
652
- thousandSeparator: S,
640
+ thousandSeparator: x,
653
641
  decimalScale: t,
654
- customInput: be,
642
+ customInput: xe,
655
643
  isAllowed: (h) => {
656
644
  var V;
657
- const { floatValue: s } = h;
658
- return s ? a.maxValue && s > a.maxValue ? !1 : ((V = a.isAllowed) == null ? void 0 : V.call(a, h)) ?? !0 : !0;
645
+ const { floatValue: c } = h;
646
+ return c ? a.maxValue && c > a.maxValue ? !1 : ((V = a.isAllowed) == null ? void 0 : V.call(a, h)) ?? !0 : !0;
659
647
  },
660
648
  formOnBlur: y,
661
649
  additionalTrigger: n,
@@ -665,19 +653,19 @@ const Se = ({
665
653
  )
666
654
  }
667
655
  );
668
- }, Ie = ({
656
+ }, Ae = ({
669
657
  ...t
670
658
  }) => {
671
- const { t: e, i18n: r } = Lt();
672
- return /* @__PURE__ */ at(Ut, { children: /* @__PURE__ */ at(
673
- Ve,
659
+ const { t: e, i18n: r } = $t();
660
+ return /* @__PURE__ */ rt(Ut, { children: /* @__PURE__ */ rt(
661
+ ye,
674
662
  {
675
663
  ...t,
676
- languageCode: $t[r == null ? void 0 : r.language],
664
+ languageCode: Lt[r == null ? void 0 : r.language],
677
665
  helperText: e("formNumber.separator")
678
666
  }
679
667
  ) });
680
668
  };
681
669
  export {
682
- Ie as DefaultFormNumber
670
+ Ae as DefaultFormNumber
683
671
  };