@progress/kendo-react-inputs 14.4.0 → 14.4.1-develop.10

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.
@@ -137,6 +137,10 @@ export declare const signatureMaximize = "signature.maximize";
137
137
  * @hidden
138
138
  */
139
139
  export declare const signatureMinimize = "signature.minimize";
140
+ /**
141
+ * @hidden
142
+ */
143
+ export declare const switchAriaLabel = "switch.ariaLabel";
140
144
  /**
141
145
  * @hidden
142
146
  */
@@ -174,4 +178,5 @@ export declare const messages: {
174
178
  "signature.clear": string;
175
179
  "signature.maximize": string;
176
180
  "signature.minimize": string;
181
+ "switch.ariaLabel": string;
177
182
  };
package/messages/index.js CHANGED
@@ -5,4 +5,4 @@
5
5
  * Licensed under commercial license. See LICENSE.md in the package root for more information
6
6
  *-------------------------------------------------------------------------------------------
7
7
  */
8
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e="numerictextbox.increment",o="numerictextbox.decrement",r="slider.increment",t="slider.decrement",a="slider.dragTitle",l="colorGradient.r",i="colorGradient.g",n="colorGradient.b",c="colorGradient.a",s="colorGradient.hex",d="colorGradient.contrastRatio",u="colorGradient.colorGradientAALevel",G="colorGradient.colorGradientAAALevel",A="colorGradient.colorGradientPass",C="colorGradient.colorGradientFail",P="colorGradient.hueSliderLabel",g="colorGradient.alphaSliderLabel",p="colorGradient.toggleInputsButton",k="flatColorPicker.cancelBtn",B="flatColorPicker.applyBtn",b="flatColorPicker.colorGradientBtn",m="flatColorPicker.colorPaletteBtn",x="flatColorPicker.clearBtn",f="colorPicker.adaptiveTitle",h="checkbox.validation",v="checkbox.optionalText",L="radioButton.validation",V="switch.validation",T="colorPicker.dropdownButtonAriaLabel",w="rating.ariaLabel",D="signature.clear",y="signature.maximize",I="signature.minimize",S={[e]:"Increase value",[o]:"Decrease value",[r]:"Increase",[t]:"Decrease",[a]:"Drag",[l]:"r",[i]:"g",[n]:"b",[c]:"a",[s]:"hex",[d]:"Contrast ratio",[u]:"AA",[G]:"AAA",[A]:"Pass",[C]:"Fail",[P]:"Hue slider",[g]:"Alpha slider",[p]:"Toggle colorgradient inputs",[k]:"Cancel",[B]:"Apply",[b]:"Color Gradient view",[m]:"Color Palette view",[x]:"Clear color value",[f]:"Choose color",[h]:"Please check this box if you want to proceed!",[v]:"(Optional)",[L]:"Please select option if you want to proceed!",[V]:"Please turn on if you want to proceed!",[T]:"Select",[w]:"Rating",[D]:"Clear",[y]:"Maximize",[I]:"Minimize"};exports.checkboxOptionalText=v;exports.checkboxValidation=h;exports.colorGradientA=c;exports.colorGradientAAALevel=G;exports.colorGradientAALevel=u;exports.colorGradientAlphaSliderLabel=g;exports.colorGradientB=n;exports.colorGradientContrastRatio=d;exports.colorGradientFail=C;exports.colorGradientG=i;exports.colorGradientHex=s;exports.colorGradientHueSliderLabel=P;exports.colorGradientPass=A;exports.colorGradientR=l;exports.colorGradientToggleInputsButton=p;exports.colorPickerAdaptiveTitle=f;exports.colorPickerDropdownButtonAriaLabel=T;exports.flatColorPickerApplyBtn=B;exports.flatColorPickerCancelBtn=k;exports.flatColorPickerClearBtn=x;exports.flatColorPickerColorGradientBtn=b;exports.flatColorPickerColorPaletteBtn=m;exports.messages=S;exports.numericDecreaseValue=o;exports.numericIncreaseValue=e;exports.radioButtonValidation=L;exports.ratingAriaLabel=w;exports.signatureClear=D;exports.signatureMaximize=y;exports.signatureMinimize=I;exports.sliderDecreaseValue=t;exports.sliderDragTitle=a;exports.sliderIncreaseValue=r;exports.switchValidation=V;
8
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e="numerictextbox.increment",o="numerictextbox.decrement",r="slider.increment",t="slider.decrement",a="slider.dragTitle",l="colorGradient.r",i="colorGradient.g",n="colorGradient.b",c="colorGradient.a",s="colorGradient.hex",d="colorGradient.contrastRatio",u="colorGradient.colorGradientAALevel",G="colorGradient.colorGradientAAALevel",A="colorGradient.colorGradientPass",g="colorGradient.colorGradientFail",C="colorGradient.hueSliderLabel",P="colorGradient.alphaSliderLabel",p="colorGradient.toggleInputsButton",b="flatColorPicker.cancelBtn",k="flatColorPicker.applyBtn",B="flatColorPicker.colorGradientBtn",h="flatColorPicker.colorPaletteBtn",m="flatColorPicker.clearBtn",x="colorPicker.adaptiveTitle",L="checkbox.validation",f="checkbox.optionalText",v="radioButton.validation",w="switch.validation",T="colorPicker.dropdownButtonAriaLabel",V="rating.ariaLabel",D="signature.clear",y="signature.maximize",I="signature.minimize",S="switch.ariaLabel",z={[e]:"Increase value",[o]:"Decrease value",[r]:"Increase",[t]:"Decrease",[a]:"Drag",[l]:"r",[i]:"g",[n]:"b",[c]:"a",[s]:"hex",[d]:"Contrast ratio",[u]:"AA",[G]:"AAA",[A]:"Pass",[g]:"Fail",[C]:"Hue slider",[P]:"Alpha slider",[p]:"Toggle colorgradient inputs",[b]:"Cancel",[k]:"Apply",[B]:"Color Gradient view",[h]:"Color Palette view",[m]:"Clear color value",[x]:"Choose color",[L]:"Please check this box if you want to proceed!",[f]:"(Optional)",[v]:"Please select option if you want to proceed!",[w]:"Please turn on if you want to proceed!",[T]:"Select",[V]:"Rating",[D]:"Clear",[y]:"Maximize",[I]:"Minimize",[S]:"Toggle switch value"};exports.checkboxOptionalText=f;exports.checkboxValidation=L;exports.colorGradientA=c;exports.colorGradientAAALevel=G;exports.colorGradientAALevel=u;exports.colorGradientAlphaSliderLabel=P;exports.colorGradientB=n;exports.colorGradientContrastRatio=d;exports.colorGradientFail=g;exports.colorGradientG=i;exports.colorGradientHex=s;exports.colorGradientHueSliderLabel=C;exports.colorGradientPass=A;exports.colorGradientR=l;exports.colorGradientToggleInputsButton=p;exports.colorPickerAdaptiveTitle=x;exports.colorPickerDropdownButtonAriaLabel=T;exports.flatColorPickerApplyBtn=k;exports.flatColorPickerCancelBtn=b;exports.flatColorPickerClearBtn=m;exports.flatColorPickerColorGradientBtn=B;exports.flatColorPickerColorPaletteBtn=h;exports.messages=z;exports.numericDecreaseValue=o;exports.numericIncreaseValue=e;exports.radioButtonValidation=v;exports.ratingAriaLabel=V;exports.signatureClear=D;exports.signatureMaximize=y;exports.signatureMinimize=I;exports.sliderDecreaseValue=t;exports.sliderDragTitle=a;exports.sliderIncreaseValue=r;exports.switchAriaLabel=S;exports.switchValidation=w;
@@ -5,68 +5,69 @@
5
5
  * Licensed under commercial license. See LICENSE.md in the package root for more information
6
6
  *-------------------------------------------------------------------------------------------
7
7
  */
8
- const o = "numerictextbox.increment", e = "numerictextbox.decrement", t = "slider.increment", r = "slider.decrement", a = "slider.dragTitle", l = "colorGradient.r", n = "colorGradient.g", i = "colorGradient.b", c = "colorGradient.a", s = "colorGradient.hex", d = "colorGradient.contrastRatio", G = "colorGradient.colorGradientAALevel", u = "colorGradient.colorGradientAAALevel", p = "colorGradient.colorGradientPass", A = "colorGradient.colorGradientFail", C = "colorGradient.hueSliderLabel", P = "colorGradient.alphaSliderLabel", g = "colorGradient.toggleInputsButton", k = "flatColorPicker.cancelBtn", x = "flatColorPicker.applyBtn", b = "flatColorPicker.colorGradientBtn", m = "flatColorPicker.colorPaletteBtn", B = "flatColorPicker.clearBtn", h = "colorPicker.adaptiveTitle", v = "checkbox.validation", f = "checkbox.optionalText", L = "radioButton.validation", w = "switch.validation", T = "colorPicker.dropdownButtonAriaLabel", D = "rating.ariaLabel", V = "signature.clear", y = "signature.maximize", z = "signature.minimize", I = {
8
+ const o = "numerictextbox.increment", e = "numerictextbox.decrement", t = "slider.increment", r = "slider.decrement", a = "slider.dragTitle", l = "colorGradient.r", i = "colorGradient.g", n = "colorGradient.b", c = "colorGradient.a", s = "colorGradient.hex", d = "colorGradient.contrastRatio", u = "colorGradient.colorGradientAALevel", G = "colorGradient.colorGradientAAALevel", A = "colorGradient.colorGradientPass", g = "colorGradient.colorGradientFail", p = "colorGradient.hueSliderLabel", C = "colorGradient.alphaSliderLabel", P = "colorGradient.toggleInputsButton", b = "flatColorPicker.cancelBtn", k = "flatColorPicker.applyBtn", h = "flatColorPicker.colorGradientBtn", x = "flatColorPicker.colorPaletteBtn", m = "flatColorPicker.clearBtn", B = "colorPicker.adaptiveTitle", v = "checkbox.validation", L = "checkbox.optionalText", f = "radioButton.validation", w = "switch.validation", T = "colorPicker.dropdownButtonAriaLabel", D = "rating.ariaLabel", V = "signature.clear", y = "signature.maximize", z = "signature.minimize", I = "switch.ariaLabel", S = {
9
9
  [o]: "Increase value",
10
10
  [e]: "Decrease value",
11
11
  [t]: "Increase",
12
12
  [r]: "Decrease",
13
13
  [a]: "Drag",
14
14
  [l]: "r",
15
- [n]: "g",
16
- [i]: "b",
15
+ [i]: "g",
16
+ [n]: "b",
17
17
  [c]: "a",
18
18
  [s]: "hex",
19
19
  [d]: "Contrast ratio",
20
- [G]: "AA",
21
- [u]: "AAA",
22
- [p]: "Pass",
23
- [A]: "Fail",
24
- [C]: "Hue slider",
25
- [P]: "Alpha slider",
26
- [g]: "Toggle colorgradient inputs",
27
- [k]: "Cancel",
28
- [x]: "Apply",
29
- [b]: "Color Gradient view",
30
- [m]: "Color Palette view",
31
- [B]: "Clear color value",
32
- [h]: "Choose color",
20
+ [u]: "AA",
21
+ [G]: "AAA",
22
+ [A]: "Pass",
23
+ [g]: "Fail",
24
+ [p]: "Hue slider",
25
+ [C]: "Alpha slider",
26
+ [P]: "Toggle colorgradient inputs",
27
+ [b]: "Cancel",
28
+ [k]: "Apply",
29
+ [h]: "Color Gradient view",
30
+ [x]: "Color Palette view",
31
+ [m]: "Clear color value",
32
+ [B]: "Choose color",
33
33
  [v]: "Please check this box if you want to proceed!",
34
- [f]: "(Optional)",
35
- [L]: "Please select option if you want to proceed!",
34
+ [L]: "(Optional)",
35
+ [f]: "Please select option if you want to proceed!",
36
36
  [w]: "Please turn on if you want to proceed!",
37
37
  [T]: "Select",
38
38
  [D]: "Rating",
39
39
  [V]: "Clear",
40
40
  [y]: "Maximize",
41
- [z]: "Minimize"
41
+ [z]: "Minimize",
42
+ [I]: "Toggle switch value"
42
43
  };
43
44
  export {
44
- f as checkboxOptionalText,
45
+ L as checkboxOptionalText,
45
46
  v as checkboxValidation,
46
47
  c as colorGradientA,
47
- u as colorGradientAAALevel,
48
- G as colorGradientAALevel,
49
- P as colorGradientAlphaSliderLabel,
50
- i as colorGradientB,
48
+ G as colorGradientAAALevel,
49
+ u as colorGradientAALevel,
50
+ C as colorGradientAlphaSliderLabel,
51
+ n as colorGradientB,
51
52
  d as colorGradientContrastRatio,
52
- A as colorGradientFail,
53
- n as colorGradientG,
53
+ g as colorGradientFail,
54
+ i as colorGradientG,
54
55
  s as colorGradientHex,
55
- C as colorGradientHueSliderLabel,
56
- p as colorGradientPass,
56
+ p as colorGradientHueSliderLabel,
57
+ A as colorGradientPass,
57
58
  l as colorGradientR,
58
- g as colorGradientToggleInputsButton,
59
- h as colorPickerAdaptiveTitle,
59
+ P as colorGradientToggleInputsButton,
60
+ B as colorPickerAdaptiveTitle,
60
61
  T as colorPickerDropdownButtonAriaLabel,
61
- x as flatColorPickerApplyBtn,
62
- k as flatColorPickerCancelBtn,
63
- B as flatColorPickerClearBtn,
64
- b as flatColorPickerColorGradientBtn,
65
- m as flatColorPickerColorPaletteBtn,
66
- I as messages,
62
+ k as flatColorPickerApplyBtn,
63
+ b as flatColorPickerCancelBtn,
64
+ m as flatColorPickerClearBtn,
65
+ h as flatColorPickerColorGradientBtn,
66
+ x as flatColorPickerColorPaletteBtn,
67
+ S as messages,
67
68
  e as numericDecreaseValue,
68
69
  o as numericIncreaseValue,
69
- L as radioButtonValidation,
70
+ f as radioButtonValidation,
70
71
  D as ratingAriaLabel,
71
72
  V as signatureClear,
72
73
  y as signatureMaximize,
@@ -74,5 +75,6 @@ export {
74
75
  r as sliderDecreaseValue,
75
76
  a as sliderDragTitle,
76
77
  t as sliderIncreaseValue,
78
+ I as switchAriaLabel,
77
79
  w as switchValidation
78
80
  };
@@ -5,4 +5,4 @@
5
5
  * Licensed under commercial license. See LICENSE.md in the package root for more information
6
6
  *-------------------------------------------------------------------------------------------
7
7
  */
8
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const S=11111111111111e-7,Le=.31111111111111117,he=1,ee=1,ne=0,V=/\d/,te=15,Ie=()=>({eventValue:null,prevLooseValue:"",currentLooseValue:"",focused:!1,selectionStart:void 0,selectionEnd:void 0,decimalSelect:!1,valueIsCorrected:!1,valueIsOutOfRange:!1}),Ne=(t,n)=>t!==void 0?t:n,m=(t,n,r)=>t===null&&t===void 0?"":typeof t=="string"?t:r.formatNumber(t,n),$=t=>(String(t).split(".")[1]||"").length,re=(t,n)=>Math.max($(t),$(n)),oe=t=>Math.min(t,te),U=(t,n)=>{const r=oe(n);return parseFloat(t.toFixed(r))},Ce=(t,n,r,e,u,o,a)=>{const s=re(t||0,r||0),l=X(U((t||0)+(r||0),s),e,u);n.eventValue=l,n.currentLooseValue=m(l,o,a),n.selectionStart=n.selectionEnd=N(n.currentLooseValue,V)},Pe=(t,n,r,e,u,o,a)=>{const s=re(t||0,r||0),l=X(U((t||0)-(r||0),s),e,u);n.eventValue=l,n.currentLooseValue=m(l,o,a),n.selectionStart=n.selectionEnd=N(n.currentLooseValue,V)},X=(t,n,r)=>t==null?t:!(t>1||t<1||t===1)||r!==void 0&&n!==void 0&&r<n?null:(r!==void 0&&t>r&&(t=r),n!==void 0&&t<n&&(t=n),t),se=(t,n)=>{const r=n.findIndex(([u,o])=>!!o&&t.indexOf(o)===t.length-o.length);if(r===-1)return-1;const e=n[r][1];return t.length-e.length},ue=(t,n)=>{const r=n.findIndex(([u,o])=>!!u&&t.indexOf(u)===0);return r===-1?-1:n[r][0].length},ie=(t,n,r)=>{const e=se(t,n);if(e!==-1&&r.selectionStart>e){r.selectionStart=r.selectionEnd=e;return}r.selectionStart>t.length&&(r.selectionStart=r.selectionEnd=t.length);const u=ue(t,n);u!==-1&&r.selectionStart<u&&(r.selectionStart=r.selectionEnd=u),r.selectionStart===-1&&(r.selectionStart=r.selectionEnd=0)},x=(t,n,r,e)=>{t.selectionStart=t.selectionEnd=n,ie(r,e,t)},M=(t,n,r,e)=>{t.eventValue=e.parseNumber(t.prevLooseValue,n),t.currentLooseValue=t.prevLooseValue,t.valueIsCorrected=!0,x(t,t.selectionStart,t.currentLooseValue,r)},T=(t,n,r)=>n.split(t).length!==r.split(t).length&&n.length===r.length+t.length,le=(t,n)=>{const r=String(t.currentLooseValue),e=String(t.prevLooseValue);return T(n.minusSign,r,e)||T("-",r,e)||T("−",r,e)},ce=(t,n)=>{const r=String(t.currentLooseValue),e=String(t.prevLooseValue);return r.indexOf(n.minusSign)===-1&&e.indexOf(n.minusSign)!==-1},ae=(t,n)=>String(t.currentLooseValue).split(n.decimal).length>2,de=(t,n)=>{const r=n.formatNumber(S,t),e=n.formatNumber(-S,t),u=n.formatNumber(ne,t),o=n.formatNumber(ee,t),a=O(r),s=O(e),l=O(u),c=O(o),C=D(r),P=D(e),b=D(u),L=D(o);return{positiveInfo:[a,C],negativeInfo:[s,P],zeroInfo:[l,b],oneInfo:[c,L]}},ge=(t,n)=>{const r=n.formatNumber(S,t),e=n.formatNumber(-S,t),u=n.formatNumber(ne,t),o=n.formatNumber(ee,t),a=n.numberSymbols(),s=new RegExp(`[\\d\\${a.decimal}${a.group}]`,"g");return[r,e,u,o].map(c=>c.replace(s,"")).join("").split("").filter((c,C,P)=>P.indexOf(c)===C).join("")},y=(t,n)=>{const r=t.indexOf(n.decimal);return r>-1?r:N(t,V)},F=t=>t.split("").reverse().join(""),N=(t,n)=>t.length-F(t).search(n),O=t=>t.split(t[t.search(V)])[0],D=t=>{const n=F(t);return F(n.split(n[n.search(V)])[0])},v=(t,n)=>t.search(n),j=(t,n)=>{const r=t.indexOf(n);return r>-1?t.length-r-1:0},G=(t,n,r,e,u)=>{const o=t.replace(u,"")[0]==="0",a=n.replace(u,"")[0]==="0";if(o&&!a)return r-1;if(a&&e)return r+1;let s=0;for(let c=0;c<r;c++)V.test(t.charAt(c))&&s++;let l=0;for(;s>0&&n.length>l;)V.test(n.charAt(l))&&s--,l++;return l},Ee=(t,n,r)=>{const e={...t},{prevLooseValue:u}=e,o=r.numberSymbols(),a=ge(n,r),s=String(e.currentLooseValue),l=String(u),c=new RegExp(`[^\\d\\${o.decimal}]`,"g"),C=new RegExp(`[^\\d\\${o.decimal}\\${o.group}]`,"g"),P=new RegExp(`[\\d\\${o.decimal}\\${o.group}]`),b=s.replace(c,""),L=v(s,V),E=L===-1?-1:N(s,V),fe=s.indexOf(o.decimal),Z=(s.substring(0,L)+s.substring(L,E).replace(C,"")+s.substring(E,s.length)).split("").filter(p=>a.indexOf(p)!==-1||p.search(P)!==-1).join(""),W=r.formatNumber(Le,n).replace(c,""),k=W.indexOf(o.decimal),I=k>-1?W.length-k-1:0,q=r.formatNumber(he,n).replace(c,""),H=q.indexOf(o.decimal),R=H>-1?q.length-H-1:0,{positiveInfo:me,negativeInfo:Ve,zeroInfo:pe,oneInfo:xe}=de(n,r),g=[me,Ve,pe,xe],be=g.findIndex(p=>p.findIndex(h=>!!h)!==-1)!==1,z=s.length>0&&s.length<l.length,J=typeof n=="string"&&n[0]==="p"&&s&&s.indexOf(o.percentSign)===-1;if(!e.isPaste){if(s==="")return e.eventValue=null,e.currentLooseValue="",e;if(e.currentLooseValue===o.minusSign&&r.formatNumber(-0,n)!==l)return e.eventValue=-0,e.currentLooseValue=m(e.eventValue,n,r),x(e,y(e.currentLooseValue,o),e.currentLooseValue,g),e;if(e.currentLooseValue===o.decimal){e.eventValue=0;const f=m(e.eventValue,n,r);if(R===0&&I>0){const i=N(f,V);e.currentLooseValue=f.substring(0,i)+o.decimal+f.substring(i)}else e.currentLooseValue=f;return x(e,y(e.currentLooseValue,o)+1,e.currentLooseValue,g),e}if(le(e,o)){const f=r.parseNumber(u,n);e.eventValue=-(f!==null?f:0),e.currentLooseValue=m(e.eventValue,n,r);const i=v(e.currentLooseValue,V),d=v(l,V);return x(e,e.selectionEnd-1+(i-d),e.currentLooseValue,g),e}if(ce(e,o))return e.eventValue=r.parseNumber(e.currentLooseValue,n),x(e,e.selectionStart,e.currentLooseValue,g),e;if(ae(e,o))return M(e,n,g,r),e;if(J)return e.eventValue=r.parseNumber(s,n)/100,e.currentLooseValue=m(e.eventValue,n,r),e;if(String(e.currentLooseValue).replace(/[^\d]/g,"").length>te||b!==s&&s&&be&&g.findIndex(([i,d])=>{const _=s.indexOf(i),B=s.indexOf(d),K=_===0,Q=B===s.length-d.length,Y=_+i.length!==L&&L!==-1&&s[_+i.length]!==o.decimal,w=B!==E&&E!==-1&&s[B-1]!==o.decimal;return i&&d?Y||w?!1:K&&Q:i?Y?!1:K:d?w?!1:Q:!1})===-1)return M(e,n,g,r),e;if(b[b.length-1]===o.decimal&&I>0)return e.eventValue=r.parseNumber(s,n),e.currentLooseValue=Z,e;if(e.currentLooseValue&&u&&(a+o.decimal+o.group).split("").findIndex(i=>s.split("").filter(d=>d===i).length<l.split("").filter(d=>d===i).length&&s.length+1===l.length?!(i===o.decimal&&j(l.replace(c,""),o.decimal)===0):!1)>-1)return e.eventValue=r.parseNumber(t.prevLooseValue,n),e.currentLooseValue=t.prevLooseValue,e;const h=j(b,o.decimal),A=b[b.length-1]==="0";if(z&&A&&h<R)return e.eventValue=r.parseNumber(e.currentLooseValue,n),e.currentLooseValue=m(e.eventValue,n,r),e;if(h>0){const f=s.substring(0,fe);if(A&&(!f||l.indexOf(f)!==0)){e.eventValue=r.parseNumber(e.currentLooseValue,n);const i=m(e.eventValue,n,r);return x(e,G(s,i,e.selectionEnd,z,c),i,g),e.currentLooseValue=i,e}if(h>I){const i=s.indexOf(o.decimal),d=s.substring(0,i)+s.substring(i,i+1+I)+s.substring(E,String(e.currentLooseValue).length);return e.eventValue=r.parseNumber(d,n),e.currentLooseValue=d,x(e,e.selectionStart,d,g),e}if(R!==I&&h<=I&&A)return e.eventValue=r.parseNumber(e.currentLooseValue,n),e.currentLooseValue=Z,e;if(h<R)return e.eventValue=r.parseNumber(e.currentLooseValue,n),e.currentLooseValue=m(e.eventValue,n,r),e}}if(e.eventValue=r.parseNumber(e.currentLooseValue,n),J&&(e.eventValue=e.eventValue/100),typeof e.eventValue=="number"){const p=m(e.eventValue,n,r);s.length===1?x(e,y(p,o),p,g):x(e,G(s,p,e.selectionEnd,z,c),p,g),e.currentLooseValue=p}else e.currentLooseValue=m(r.parseNumber(b),n,r);return e};exports.changeBasedSelection=G;exports.decreaseValue=Pe;exports.formatValue=m;exports.fractionLength=$;exports.getDecimalCount=j;exports.getFirstNumberIndex=v;exports.getFormatPrefixSufix=de;exports.getFormatSymbols=ge;exports.getInitialPosition=y;exports.getInitialState=Ie;exports.getLastNumberIndex=N;exports.getMaxCursorPosition=se;exports.getMinCursorPosition=ue;exports.getPrefix=O;exports.getStateOrPropsValue=Ne;exports.getSuffix=D;exports.increaseValue=Ce;exports.isDecimalDuplicated=ae;exports.isMinusSymbolAdded=le;exports.isMinusSymbolRemoved=ce;exports.limitPrecision=oe;exports.rangeSelection=ie;exports.rangeValue=X;exports.reverseString=F;exports.sanitizeNumber=Ee;exports.setInvalid=M;exports.setSelection=x;exports.toFixedPrecision=U;
8
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const v=11111111111111e-7,Le=.31111111111111117,he=1,ee=1,ne=0,m=/\d/,te=15,Ie=()=>({eventValue:null,prevLooseValue:"",currentLooseValue:"",focused:!1,selectionStart:void 0,selectionEnd:void 0,decimalSelect:!1,valueIsCorrected:!1,valueIsOutOfRange:!1}),Ne=(n,t)=>n!==void 0?n:t,x=(n,t,r)=>n===null&&n===void 0?"":typeof n=="string"?n:r.formatNumber(n,t),T=n=>(String(n).split(".")[1]||"").length,re=(n,t)=>Math.max(T(n),T(t)),oe=n=>Math.min(n,te),U=(n,t)=>{const r=oe(t);return parseFloat(n.toFixed(r))},Ce=(n,t,r,e,u,o,a)=>{const s=re(n||0,r||0),l=X(U((n||0)+(r||0),s),e,u);t.eventValue=l,t.currentLooseValue=x(l,o,a),t.selectionStart=t.selectionEnd=N(t.currentLooseValue,m)},Pe=(n,t,r,e,u,o,a)=>{const s=re(n||0,r||0),l=X(U((n||0)-(r||0),s),e,u);t.eventValue=l,t.currentLooseValue=x(l,o,a),t.selectionStart=t.selectionEnd=N(t.currentLooseValue,m)},X=(n,t,r)=>n==null?n:!(n>1||n<1||n===1)||r!==void 0&&t!==void 0&&r<t?null:(r!==void 0&&n>r&&(n=r),t!==void 0&&n<t&&(n=t),n),se=(n,t)=>{const r=t.findIndex(([u,o])=>!!o&&n.indexOf(o)===n.length-o.length);if(r===-1)return-1;const e=t[r][1];return n.length-e.length},ue=(n,t)=>{const r=t.findIndex(([u,o])=>!!u&&n.indexOf(u)===0);return r===-1?-1:t[r][0].length},ie=(n,t,r)=>{const e=se(n,t);if(e!==-1&&r.selectionStart>e){r.selectionStart=r.selectionEnd=e;return}r.selectionStart>n.length&&(r.selectionStart=r.selectionEnd=n.length);const u=ue(n,t);u!==-1&&r.selectionStart<u&&(r.selectionStart=r.selectionEnd=u),r.selectionStart===-1&&(r.selectionStart=r.selectionEnd=0)},p=(n,t,r,e)=>{n.selectionStart=n.selectionEnd=t,ie(r,e,n)},S=(n,t,r,e)=>{n.eventValue=e.parseNumber(n.prevLooseValue,t),n.currentLooseValue=n.prevLooseValue,n.valueIsCorrected=!0,p(n,n.selectionStart,n.currentLooseValue,r)},B=(n,t,r)=>t.split(n).length!==r.split(n).length&&t.length===r.length+n.length,le=(n,t)=>{const r=String(n.currentLooseValue),e=String(n.prevLooseValue);return B(t.minusSign,r,e)||B("-",r,e)||B("−",r,e)},ce=(n,t)=>{const r=String(n.currentLooseValue),e=String(n.prevLooseValue);return r.indexOf(t.minusSign)===-1&&e.indexOf(t.minusSign)!==-1},ae=(n,t)=>String(n.currentLooseValue).split(t.decimal).length>2,de=(n,t)=>{const r=t.formatNumber(v,n),e=t.formatNumber(-v,n),u=t.formatNumber(ne,n),o=t.formatNumber(ee,n),a=O(r),s=O(e),l=O(u),c=O(o),C=D(r),P=D(e),b=D(u),L=D(o);return{positiveInfo:[a,C],negativeInfo:[s,P],zeroInfo:[l,b],oneInfo:[c,L]}},ge=(n,t)=>{const r=t.formatNumber(v,n),e=t.formatNumber(-v,n),u=t.formatNumber(ne,n),o=t.formatNumber(ee,n),a=t.numberSymbols(),s=new RegExp(`[\\d\\${a.decimal}${a.group}]`,"g");return[r,e,u,o].map(c=>c.replace(s,"")).join("").split("").filter((c,C,P)=>P.indexOf(c)===C).join("")},$=(n,t)=>{const r=n.indexOf(t.decimal);return r>-1?r:N(n,m)},y=n=>n.split("").reverse().join(""),N=(n,t)=>n.length-y(n).search(t),O=n=>n.split(n[n.search(m)])[0],D=n=>{const t=y(n);return y(t.split(t[t.search(m)])[0])},M=(n,t)=>n.search(t),j=(n,t)=>{const r=n.indexOf(t);return r>-1?n.length-r-1:0},G=(n,t,r,e,u)=>{const o=n.replace(u,"")[0]==="0",a=t.replace(u,"")[0]==="0";if(o&&!a)return r-1;if(a&&e)return r+1;let s=0;for(let c=0;c<r;c++)m.test(n.charAt(c))&&s++;let l=0;for(;s>0&&t.length>l;)m.test(t.charAt(l))&&s--,l++;return l},Ee=(n,t,r)=>{const e={...n},{prevLooseValue:u}=e,o=r.numberSymbols(),a=ge(t,r),s=String(e.currentLooseValue),l=String(u),c=new RegExp(`[^\\d\\${o.decimal}]`,"g"),C=new RegExp(`[^\\d\\${o.decimal}\\${o.group}]`,"g"),P=new RegExp(`[\\d\\${o.decimal}\\${o.group}]`),b=s.replace(c,""),L=M(s,m),E=L===-1?-1:N(s,m),fe=s.indexOf(o.decimal),Z=(s.substring(0,L)+s.substring(L,E).replace(C,"")+s.substring(E,s.length)).split("").filter(V=>a.indexOf(V)!==-1||V.search(P)!==-1).join(""),W=r.formatNumber(Le,t).replace(c,""),k=W.indexOf(o.decimal),I=k>-1?W.length-k-1:0,q=r.formatNumber(he,t).replace(c,""),H=q.indexOf(o.decimal),R=H>-1?q.length-H-1:0,{positiveInfo:me,negativeInfo:Ve,zeroInfo:pe,oneInfo:xe}=de(t,r),d=[me,Ve,pe,xe],be=d.findIndex(V=>V.findIndex(h=>!!h)!==-1)!==1,F=s.length>0&&s.length<l.length,J=typeof t=="string"&&t[0]==="p"&&s&&s.indexOf(o.percentSign)===-1;if(!e.isPaste){if(s==="")return e.eventValue=null,e.currentLooseValue="",e;if(e.currentLooseValue===o.minusSign&&r.formatNumber(-0,t)!==l)return e.eventValue=null,e.currentLooseValue=o.minusSign,p(e,e.selectionStart,e.currentLooseValue,d),e;if(e.currentLooseValue===o.decimal){e.eventValue=0;const f=x(e.eventValue,t,r);if(R===0&&I>0){const i=N(f,m);e.currentLooseValue=f.substring(0,i)+o.decimal+f.substring(i)}else e.currentLooseValue=f;return p(e,$(e.currentLooseValue,o)+1,e.currentLooseValue,d),e}if(le(e,o)){const f=r.parseNumber(u,t);if(f===null)return e.eventValue=null,e.currentLooseValue=o.minusSign,p(e,e.selectionStart,e.currentLooseValue,d),e;e.eventValue=-f,e.currentLooseValue=x(e.eventValue,t,r);const i=M(e.currentLooseValue,m),g=M(l,m);return p(e,e.selectionEnd-1+(i-g),e.currentLooseValue,d),e}if(ce(e,o))return e.eventValue=r.parseNumber(e.currentLooseValue,t),p(e,e.selectionStart,e.currentLooseValue,d),e;if(ae(e,o))return S(e,t,d,r),e;if(J)return e.eventValue=r.parseNumber(s,t)/100,e.currentLooseValue=x(e.eventValue,t,r),e;if(String(e.currentLooseValue).replace(/[^\d]/g,"").length>te||b!==s&&s&&be&&d.findIndex(([i,g])=>{const A=s.indexOf(i),_=s.indexOf(g),K=A===0,Q=_===s.length-g.length,Y=A+i.length!==L&&L!==-1&&s[A+i.length]!==o.decimal,w=_!==E&&E!==-1&&s[_-1]!==o.decimal;return i&&g?Y||w?!1:K&&Q:i?Y?!1:K:g?w?!1:Q:!1})===-1)return S(e,t,d,r),e;if(b[b.length-1]===o.decimal&&I>0)return e.eventValue=r.parseNumber(s,t),e.currentLooseValue=Z,e;if(e.currentLooseValue&&u&&(a+o.decimal+o.group).split("").findIndex(i=>s.split("").filter(g=>g===i).length<l.split("").filter(g=>g===i).length&&s.length+1===l.length?!(i===o.decimal&&j(l.replace(c,""),o.decimal)===0):!1)>-1)return e.eventValue=r.parseNumber(n.prevLooseValue,t),e.currentLooseValue=n.prevLooseValue,e;const h=j(b,o.decimal),z=b[b.length-1]==="0";if(F&&z&&h<R)return e.eventValue=r.parseNumber(e.currentLooseValue,t),e.currentLooseValue=x(e.eventValue,t,r),e;if(h>0){const f=s.substring(0,fe);if(z&&(!f||l.indexOf(f)!==0)){e.eventValue=r.parseNumber(e.currentLooseValue,t);const i=x(e.eventValue,t,r);return p(e,G(s,i,e.selectionEnd,F,c),i,d),e.currentLooseValue=i,e}if(h>I){const i=s.indexOf(o.decimal),g=s.substring(0,i)+s.substring(i,i+1+I)+s.substring(E,String(e.currentLooseValue).length);return e.eventValue=r.parseNumber(g,t),e.currentLooseValue=g,p(e,e.selectionStart,g,d),e}if(R!==I&&h<=I&&z)return e.eventValue=r.parseNumber(e.currentLooseValue,t),e.currentLooseValue=Z,e;if(h<R)return e.eventValue=r.parseNumber(e.currentLooseValue,t),e.currentLooseValue=x(e.eventValue,t,r),e}}if(e.eventValue=r.parseNumber(e.currentLooseValue,t),J&&(e.eventValue=e.eventValue/100),typeof e.eventValue=="number"){const V=x(e.eventValue,t,r);s.length===1?p(e,$(V,o),V,d):p(e,G(s,V,e.selectionEnd,F,c),V,d),e.currentLooseValue=V}else e.currentLooseValue=x(r.parseNumber(b),t,r);return e};exports.changeBasedSelection=G;exports.decreaseValue=Pe;exports.formatValue=x;exports.fractionLength=T;exports.getDecimalCount=j;exports.getFirstNumberIndex=M;exports.getFormatPrefixSufix=de;exports.getFormatSymbols=ge;exports.getInitialPosition=$;exports.getInitialState=Ie;exports.getLastNumberIndex=N;exports.getMaxCursorPosition=se;exports.getMinCursorPosition=ue;exports.getPrefix=O;exports.getStateOrPropsValue=Ne;exports.getSuffix=D;exports.increaseValue=Ce;exports.isDecimalDuplicated=ae;exports.isMinusSymbolAdded=le;exports.isMinusSymbolRemoved=ce;exports.limitPrecision=oe;exports.rangeSelection=ie;exports.rangeValue=X;exports.reverseString=y;exports.sanitizeNumber=Ee;exports.setInvalid=S;exports.setSelection=p;exports.toFixedPrecision=U;
@@ -15,188 +15,185 @@ const M = 11111111111111e-7, ae = 0.31111111111111117, de = 1, Y = 1, w = 0, m =
15
15
  decimalSelect: !1,
16
16
  valueIsCorrected: !1,
17
17
  valueIsOutOfRange: !1
18
- }), Ne = (t, n) => t !== void 0 ? t : n, p = (t, n, r) => t === null && t === void 0 ? "" : typeof t == "string" ? t : r.formatNumber(t, n), J = (t) => (String(t).split(".")[1] || "").length, ne = (t, n) => Math.max(J(t), J(n)), ge = (t) => Math.min(t, ee), te = (t, n) => {
19
- const r = ge(n);
20
- return parseFloat(t.toFixed(r));
21
- }, Ce = (t, n, r, e, u, o, a) => {
22
- const s = ne(t || 0, r || 0), l = re(te((t || 0) + (r || 0), s), e, u);
23
- n.eventValue = l, n.currentLooseValue = p(l, o, a), n.selectionStart = n.selectionEnd = O(n.currentLooseValue, m);
24
- }, Ee = (t, n, r, e, u, o, a) => {
25
- const s = ne(t || 0, r || 0), l = re(te((t || 0) - (r || 0), s), e, u);
26
- n.eventValue = l, n.currentLooseValue = p(l, o, a), n.selectionStart = n.selectionEnd = O(n.currentLooseValue, m);
27
- }, re = (t, n, r) => t == null ? t : !(t > 1 || t < 1 || t === 1) || r !== void 0 && n !== void 0 && r < n ? null : (r !== void 0 && t > r && (t = r), n !== void 0 && t < n && (t = n), t), fe = (t, n) => {
28
- const r = n.findIndex(([u, o]) => !!o && t.indexOf(o) === t.length - o.length);
18
+ }), Ne = (n, t) => n !== void 0 ? n : t, x = (n, t, r) => n === null && n === void 0 ? "" : typeof n == "string" ? n : r.formatNumber(n, t), H = (n) => (String(n).split(".")[1] || "").length, ne = (n, t) => Math.max(H(n), H(t)), ge = (n) => Math.min(n, ee), te = (n, t) => {
19
+ const r = ge(t);
20
+ return parseFloat(n.toFixed(r));
21
+ }, Ce = (n, t, r, e, u, o, a) => {
22
+ const s = ne(n || 0, r || 0), i = re(te((n || 0) + (r || 0), s), e, u);
23
+ t.eventValue = i, t.currentLooseValue = x(i, o, a), t.selectionStart = t.selectionEnd = O(t.currentLooseValue, m);
24
+ }, Ee = (n, t, r, e, u, o, a) => {
25
+ const s = ne(n || 0, r || 0), i = re(te((n || 0) - (r || 0), s), e, u);
26
+ t.eventValue = i, t.currentLooseValue = x(i, o, a), t.selectionStart = t.selectionEnd = O(t.currentLooseValue, m);
27
+ }, re = (n, t, r) => n == null ? n : !(n > 1 || n < 1 || n === 1) || r !== void 0 && t !== void 0 && r < t ? null : (r !== void 0 && n > r && (n = r), t !== void 0 && n < t && (n = t), n), fe = (n, t) => {
28
+ const r = t.findIndex(([u, o]) => !!o && n.indexOf(o) === n.length - o.length);
29
29
  if (r === -1)
30
30
  return -1;
31
- const e = n[r][1];
32
- return t.length - e.length;
33
- }, me = (t, n) => {
34
- const r = n.findIndex(([u, o]) => !!u && t.indexOf(u) === 0);
35
- return r === -1 ? -1 : n[r][0].length;
36
- }, Ve = (t, n, r) => {
37
- const e = fe(t, n);
31
+ const e = t[r][1];
32
+ return n.length - e.length;
33
+ }, me = (n, t) => {
34
+ const r = t.findIndex(([u, o]) => !!u && n.indexOf(u) === 0);
35
+ return r === -1 ? -1 : t[r][0].length;
36
+ }, Ve = (n, t, r) => {
37
+ const e = fe(n, t);
38
38
  if (e !== -1 && r.selectionStart > e) {
39
39
  r.selectionStart = r.selectionEnd = e;
40
40
  return;
41
41
  }
42
- r.selectionStart > t.length && (r.selectionStart = r.selectionEnd = t.length);
43
- const u = me(t, n);
42
+ r.selectionStart > n.length && (r.selectionStart = r.selectionEnd = n.length);
43
+ const u = me(n, t);
44
44
  u !== -1 && r.selectionStart < u && (r.selectionStart = r.selectionEnd = u), r.selectionStart === -1 && (r.selectionStart = r.selectionEnd = 0);
45
- }, L = (t, n, r, e) => {
46
- t.selectionStart = t.selectionEnd = n, Ve(r, e, t);
47
- }, A = (t, n, r, e) => {
48
- t.eventValue = e.parseNumber(t.prevLooseValue, n), t.currentLooseValue = t.prevLooseValue, t.valueIsCorrected = !0, L(t, t.selectionStart, t.currentLooseValue, r);
49
- }, _ = (t, n, r) => n.split(t).length !== r.split(t).length && n.length === r.length + t.length, pe = (t, n) => {
50
- const r = String(t.currentLooseValue), e = String(t.prevLooseValue);
51
- return _(n.minusSign, r, e) || _("-", r, e) || _("−", r, e);
52
- }, xe = (t, n) => {
53
- const r = String(t.currentLooseValue), e = String(t.prevLooseValue);
54
- return r.indexOf(n.minusSign) === -1 && e.indexOf(n.minusSign) !== -1;
55
- }, Le = (t, n) => String(t.currentLooseValue).split(n.decimal).length > 2, be = (t, n) => {
56
- const r = n.formatNumber(M, t), e = n.formatNumber(-M, t), u = n.formatNumber(w, t), o = n.formatNumber(Y, t), a = D(r), s = D(e), l = D(u), i = D(o), N = P(r), C = P(e), x = P(u), b = P(o);
45
+ }, p = (n, t, r, e) => {
46
+ n.selectionStart = n.selectionEnd = t, Ve(r, e, n);
47
+ }, A = (n, t, r, e) => {
48
+ n.eventValue = e.parseNumber(n.prevLooseValue, t), n.currentLooseValue = n.prevLooseValue, n.valueIsCorrected = !0, p(n, n.selectionStart, n.currentLooseValue, r);
49
+ }, S = (n, t, r) => t.split(n).length !== r.split(n).length && t.length === r.length + n.length, pe = (n, t) => {
50
+ const r = String(n.currentLooseValue), e = String(n.prevLooseValue);
51
+ return S(t.minusSign, r, e) || S("-", r, e) || S("−", r, e);
52
+ }, xe = (n, t) => {
53
+ const r = String(n.currentLooseValue), e = String(n.prevLooseValue);
54
+ return r.indexOf(t.minusSign) === -1 && e.indexOf(t.minusSign) !== -1;
55
+ }, Le = (n, t) => String(n.currentLooseValue).split(t.decimal).length > 2, be = (n, t) => {
56
+ const r = t.formatNumber(M, n), e = t.formatNumber(-M, n), u = t.formatNumber(w, n), o = t.formatNumber(Y, n), a = D(r), s = D(e), i = D(u), c = D(o), N = P(r), C = P(e), L = P(u), b = P(o);
57
57
  return {
58
58
  positiveInfo: [a, N],
59
59
  negativeInfo: [s, C],
60
- zeroInfo: [l, x],
61
- oneInfo: [i, b]
60
+ zeroInfo: [i, L],
61
+ oneInfo: [c, b]
62
62
  };
63
- }, he = (t, n) => {
64
- const r = n.formatNumber(M, t), e = n.formatNumber(-M, t), u = n.formatNumber(w, t), o = n.formatNumber(Y, t), a = n.numberSymbols(), s = new RegExp(`[\\d\\${a.decimal}${a.group}]`, "g");
65
- return [r, e, u, o].map((i) => i.replace(s, "")).join("").split("").filter((i, N, C) => C.indexOf(i) === N).join("");
66
- }, B = (t, n) => {
67
- const r = t.indexOf(n.decimal);
68
- return r > -1 ? r : O(t, m);
69
- }, T = (t) => t.split("").reverse().join(""), O = (t, n) => t.length - T(t).search(n), D = (t) => t.split(t[t.search(m)])[0], P = (t) => {
70
- const n = T(t);
71
- return T(n.split(n[n.search(m)])[0]);
72
- }, $ = (t, n) => t.search(n), K = (t, n) => {
73
- const r = t.indexOf(n);
74
- return r > -1 ? t.length - r - 1 : 0;
75
- }, Q = (t, n, r, e, u) => {
76
- const o = t.replace(u, "")[0] === "0", a = n.replace(u, "")[0] === "0";
63
+ }, he = (n, t) => {
64
+ const r = t.formatNumber(M, n), e = t.formatNumber(-M, n), u = t.formatNumber(w, n), o = t.formatNumber(Y, n), a = t.numberSymbols(), s = new RegExp(`[\\d\\${a.decimal}${a.group}]`, "g");
65
+ return [r, e, u, o].map((c) => c.replace(s, "")).join("").split("").filter((c, N, C) => C.indexOf(c) === N).join("");
66
+ }, J = (n, t) => {
67
+ const r = n.indexOf(t.decimal);
68
+ return r > -1 ? r : O(n, m);
69
+ }, B = (n) => n.split("").reverse().join(""), O = (n, t) => n.length - B(n).search(t), D = (n) => n.split(n[n.search(m)])[0], P = (n) => {
70
+ const t = B(n);
71
+ return B(t.split(t[t.search(m)])[0]);
72
+ }, _ = (n, t) => n.search(t), K = (n, t) => {
73
+ const r = n.indexOf(t);
74
+ return r > -1 ? n.length - r - 1 : 0;
75
+ }, Q = (n, t, r, e, u) => {
76
+ const o = n.replace(u, "")[0] === "0", a = t.replace(u, "")[0] === "0";
77
77
  if (o && !a)
78
78
  return r - 1;
79
79
  if (a && e)
80
80
  return r + 1;
81
81
  let s = 0;
82
- for (let i = 0; i < r; i++)
83
- m.test(t.charAt(i)) && s++;
84
- let l = 0;
85
- for (; s > 0 && n.length > l; )
86
- m.test(n.charAt(l)) && s--, l++;
87
- return l;
88
- }, Oe = (t, n, r) => {
89
- const e = { ...t }, { prevLooseValue: u } = e, o = r.numberSymbols(), a = he(n, r), s = String(e.currentLooseValue), l = String(u), i = new RegExp(`[^\\d\\${o.decimal}]`, "g"), N = new RegExp(`[^\\d\\${o.decimal}\\${o.group}]`, "g"), C = new RegExp(`[\\d\\${o.decimal}\\${o.group}]`), x = s.replace(i, ""), b = $(s, m), E = b === -1 ? -1 : O(s, m), oe = s.indexOf(o.decimal), G = (s.substring(0, b) + s.substring(b, E).replace(N, "") + s.substring(E, s.length)).split("").filter((V) => a.indexOf(V) !== -1 || V.search(C) !== -1).join(""), S = r.formatNumber(ae, n).replace(i, ""), U = S.indexOf(o.decimal), I = U > -1 ? S.length - U - 1 : 0, j = r.formatNumber(de, n).replace(i, ""), X = j.indexOf(o.decimal), R = X > -1 ? j.length - X - 1 : 0, { positiveInfo: se, negativeInfo: ue, zeroInfo: ce, oneInfo: le } = be(n, r), g = [se, ue, ce, le], ie = g.findIndex((V) => V.findIndex((h) => !!h) !== -1) !== 1, v = s.length > 0 && s.length < l.length, Z = typeof n == "string" && n[0] === "p" && s && s.indexOf(o.percentSign) === -1;
82
+ for (let c = 0; c < r; c++)
83
+ m.test(n.charAt(c)) && s++;
84
+ let i = 0;
85
+ for (; s > 0 && t.length > i; )
86
+ m.test(t.charAt(i)) && s--, i++;
87
+ return i;
88
+ }, Oe = (n, t, r) => {
89
+ const e = { ...n }, { prevLooseValue: u } = e, o = r.numberSymbols(), a = he(t, r), s = String(e.currentLooseValue), i = String(u), c = new RegExp(`[^\\d\\${o.decimal}]`, "g"), N = new RegExp(`[^\\d\\${o.decimal}\\${o.group}]`, "g"), C = new RegExp(`[\\d\\${o.decimal}\\${o.group}]`), L = s.replace(c, ""), b = _(s, m), E = b === -1 ? -1 : O(s, m), oe = s.indexOf(o.decimal), $ = (s.substring(0, b) + s.substring(b, E).replace(N, "") + s.substring(E, s.length)).split("").filter((V) => a.indexOf(V) !== -1 || V.search(C) !== -1).join(""), T = r.formatNumber(ae, t).replace(c, ""), G = T.indexOf(o.decimal), I = G > -1 ? T.length - G - 1 : 0, U = r.formatNumber(de, t).replace(c, ""), j = U.indexOf(o.decimal), R = j > -1 ? U.length - j - 1 : 0, { positiveInfo: se, negativeInfo: ue, zeroInfo: le, oneInfo: ie } = be(t, r), d = [se, ue, le, ie], ce = d.findIndex((V) => V.findIndex((h) => !!h) !== -1) !== 1, v = s.length > 0 && s.length < i.length, X = typeof t == "string" && t[0] === "p" && s && s.indexOf(o.percentSign) === -1;
90
90
  if (!e.isPaste) {
91
91
  if (s === "")
92
92
  return e.eventValue = null, e.currentLooseValue = "", e;
93
- if (e.currentLooseValue === o.minusSign && r.formatNumber(-0, n) !== l)
94
- return e.eventValue = -0, e.currentLooseValue = p(e.eventValue, n, r), L(
95
- e,
96
- B(e.currentLooseValue, o),
97
- e.currentLooseValue,
98
- g
99
- ), e;
93
+ if (e.currentLooseValue === o.minusSign && r.formatNumber(-0, t) !== i)
94
+ return e.eventValue = null, e.currentLooseValue = o.minusSign, p(e, e.selectionStart, e.currentLooseValue, d), e;
100
95
  if (e.currentLooseValue === o.decimal) {
101
96
  e.eventValue = 0;
102
- const f = p(e.eventValue, n, r);
97
+ const f = x(e.eventValue, t, r);
103
98
  if (R === 0 && I > 0) {
104
- const c = O(f, m);
105
- e.currentLooseValue = f.substring(0, c) + o.decimal + f.substring(c);
99
+ const l = O(f, m);
100
+ e.currentLooseValue = f.substring(0, l) + o.decimal + f.substring(l);
106
101
  } else
107
102
  e.currentLooseValue = f;
108
- return L(
103
+ return p(
109
104
  e,
110
- B(e.currentLooseValue, o) + 1,
105
+ J(e.currentLooseValue, o) + 1,
111
106
  e.currentLooseValue,
112
- g
107
+ d
113
108
  ), e;
114
109
  }
115
110
  if (pe(e, o)) {
116
- const f = r.parseNumber(u, n);
117
- e.eventValue = -(f !== null ? f : 0), e.currentLooseValue = p(e.eventValue, n, r);
118
- const c = $(e.currentLooseValue, m), d = $(l, m);
119
- return L(
111
+ const f = r.parseNumber(u, t);
112
+ if (f === null)
113
+ return e.eventValue = null, e.currentLooseValue = o.minusSign, p(e, e.selectionStart, e.currentLooseValue, d), e;
114
+ e.eventValue = -f, e.currentLooseValue = x(e.eventValue, t, r);
115
+ const l = _(e.currentLooseValue, m), g = _(i, m);
116
+ return p(
120
117
  e,
121
- e.selectionEnd - 1 + (c - d),
118
+ e.selectionEnd - 1 + (l - g),
122
119
  e.currentLooseValue,
123
- g
120
+ d
124
121
  ), e;
125
122
  }
126
123
  if (xe(e, o))
127
- return e.eventValue = r.parseNumber(e.currentLooseValue, n), L(e, e.selectionStart, e.currentLooseValue, g), e;
124
+ return e.eventValue = r.parseNumber(e.currentLooseValue, t), p(e, e.selectionStart, e.currentLooseValue, d), e;
128
125
  if (Le(e, o))
129
- return A(e, n, g, r), e;
130
- if (Z)
131
- return e.eventValue = r.parseNumber(s, n) / 100, e.currentLooseValue = p(e.eventValue, n, r), e;
132
- if (String(e.currentLooseValue).replace(/[^\d]/g, "").length > ee || x !== s && s && ie && g.findIndex(([c, d]) => {
133
- const F = s.indexOf(c), z = s.indexOf(d), W = F === 0, k = z === s.length - d.length, q = F + c.length !== b && b !== -1 && s[F + c.length] !== o.decimal, H = z !== E && E !== -1 && s[z - 1] !== o.decimal;
134
- return c && d ? q || H ? !1 : W && k : c ? q ? !1 : W : d ? H ? !1 : k : !1;
126
+ return A(e, t, d, r), e;
127
+ if (X)
128
+ return e.eventValue = r.parseNumber(s, t) / 100, e.currentLooseValue = x(e.eventValue, t, r), e;
129
+ if (String(e.currentLooseValue).replace(/[^\d]/g, "").length > ee || L !== s && s && ce && d.findIndex(([l, g]) => {
130
+ const F = s.indexOf(l), z = s.indexOf(g), Z = F === 0, W = z === s.length - g.length, k = F + l.length !== b && b !== -1 && s[F + l.length] !== o.decimal, q = z !== E && E !== -1 && s[z - 1] !== o.decimal;
131
+ return l && g ? k || q ? !1 : Z && W : l ? k ? !1 : Z : g ? q ? !1 : W : !1;
135
132
  }) === -1)
136
- return A(e, n, g, r), e;
137
- if (x[x.length - 1] === o.decimal && I > 0)
138
- return e.eventValue = r.parseNumber(s, n), e.currentLooseValue = G, e;
139
- if (e.currentLooseValue && u && (a + o.decimal + o.group).split("").findIndex((c) => s.split("").filter((d) => d === c).length < l.split("").filter((d) => d === c).length && s.length + 1 === l.length ? !(c === o.decimal && K(l.replace(i, ""), o.decimal) === 0) : !1) > -1)
140
- return e.eventValue = r.parseNumber(t.prevLooseValue, n), e.currentLooseValue = t.prevLooseValue, e;
141
- const h = K(x, o.decimal), y = x[x.length - 1] === "0";
133
+ return A(e, t, d, r), e;
134
+ if (L[L.length - 1] === o.decimal && I > 0)
135
+ return e.eventValue = r.parseNumber(s, t), e.currentLooseValue = $, e;
136
+ if (e.currentLooseValue && u && (a + o.decimal + o.group).split("").findIndex((l) => s.split("").filter((g) => g === l).length < i.split("").filter((g) => g === l).length && s.length + 1 === i.length ? !(l === o.decimal && K(i.replace(c, ""), o.decimal) === 0) : !1) > -1)
137
+ return e.eventValue = r.parseNumber(n.prevLooseValue, t), e.currentLooseValue = n.prevLooseValue, e;
138
+ const h = K(L, o.decimal), y = L[L.length - 1] === "0";
142
139
  if (v && y && h < R)
143
- return e.eventValue = r.parseNumber(e.currentLooseValue, n), e.currentLooseValue = p(e.eventValue, n, r), e;
140
+ return e.eventValue = r.parseNumber(e.currentLooseValue, t), e.currentLooseValue = x(e.eventValue, t, r), e;
144
141
  if (h > 0) {
145
142
  const f = s.substring(0, oe);
146
- if (y && (!f || l.indexOf(f) !== 0)) {
147
- e.eventValue = r.parseNumber(e.currentLooseValue, n);
148
- const c = p(e.eventValue, n, r);
149
- return L(
143
+ if (y && (!f || i.indexOf(f) !== 0)) {
144
+ e.eventValue = r.parseNumber(e.currentLooseValue, t);
145
+ const l = x(e.eventValue, t, r);
146
+ return p(
150
147
  e,
151
148
  Q(
152
149
  s,
153
- c,
150
+ l,
154
151
  e.selectionEnd,
155
152
  v,
156
- i
153
+ c
157
154
  ),
158
- c,
159
- g
160
- ), e.currentLooseValue = c, e;
155
+ l,
156
+ d
157
+ ), e.currentLooseValue = l, e;
161
158
  }
162
159
  if (h > I) {
163
- const c = s.indexOf(o.decimal), d = s.substring(0, c) + s.substring(c, c + 1 + I) + s.substring(E, String(e.currentLooseValue).length);
164
- return e.eventValue = r.parseNumber(d, n), e.currentLooseValue = d, L(e, e.selectionStart, d, g), e;
160
+ const l = s.indexOf(o.decimal), g = s.substring(0, l) + s.substring(l, l + 1 + I) + s.substring(E, String(e.currentLooseValue).length);
161
+ return e.eventValue = r.parseNumber(g, t), e.currentLooseValue = g, p(e, e.selectionStart, g, d), e;
165
162
  }
166
163
  if (R !== I && h <= I && y)
167
- return e.eventValue = r.parseNumber(e.currentLooseValue, n), e.currentLooseValue = G, e;
164
+ return e.eventValue = r.parseNumber(e.currentLooseValue, t), e.currentLooseValue = $, e;
168
165
  if (h < R)
169
- return e.eventValue = r.parseNumber(e.currentLooseValue, n), e.currentLooseValue = p(e.eventValue, n, r), e;
166
+ return e.eventValue = r.parseNumber(e.currentLooseValue, t), e.currentLooseValue = x(e.eventValue, t, r), e;
170
167
  }
171
168
  }
172
- if (e.eventValue = r.parseNumber(e.currentLooseValue, n), Z && (e.eventValue = e.eventValue / 100), typeof e.eventValue == "number") {
173
- const V = p(e.eventValue, n, r);
174
- s.length === 1 ? L(e, B(V, o), V, g) : L(
169
+ if (e.eventValue = r.parseNumber(e.currentLooseValue, t), X && (e.eventValue = e.eventValue / 100), typeof e.eventValue == "number") {
170
+ const V = x(e.eventValue, t, r);
171
+ s.length === 1 ? p(e, J(V, o), V, d) : p(
175
172
  e,
176
173
  Q(
177
174
  s,
178
175
  V,
179
176
  e.selectionEnd,
180
177
  v,
181
- i
178
+ c
182
179
  ),
183
180
  V,
184
- g
181
+ d
185
182
  ), e.currentLooseValue = V;
186
183
  } else
187
- e.currentLooseValue = p(r.parseNumber(x), n, r);
184
+ e.currentLooseValue = x(r.parseNumber(L), t, r);
188
185
  return e;
189
186
  };
190
187
  export {
191
188
  Q as changeBasedSelection,
192
189
  Ee as decreaseValue,
193
- p as formatValue,
194
- J as fractionLength,
190
+ x as formatValue,
191
+ H as fractionLength,
195
192
  K as getDecimalCount,
196
- $ as getFirstNumberIndex,
193
+ _ as getFirstNumberIndex,
197
194
  be as getFormatPrefixSufix,
198
195
  he as getFormatSymbols,
199
- B as getInitialPosition,
196
+ J as getInitialPosition,
200
197
  Ie as getInitialState,
201
198
  O as getLastNumberIndex,
202
199
  fe as getMaxCursorPosition,
@@ -211,9 +208,9 @@ export {
211
208
  ge as limitPrecision,
212
209
  Ve as rangeSelection,
213
210
  re as rangeValue,
214
- T as reverseString,
211
+ B as reverseString,
215
212
  Oe as sanitizeNumber,
216
213
  A as setInvalid,
217
- L as setSelection,
214
+ p as setSelection,
218
215
  te as toFixedPrecision
219
216
  };
@@ -5,4 +5,4 @@
5
5
  * Licensed under commercial license. See LICENSE.md in the package root for more information
6
6
  *-------------------------------------------------------------------------------------------
7
7
  */
8
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=Object.freeze({name:"@progress/kendo-react-inputs",productName:"KendoReact",productCode:"KENDOUIREACT",productCodes:["KENDOUIREACT"],publishDate: 1776412826,version:"14.4.0",licensingDocsUrl:"https://www.telerik.com/kendo-react-ui/components/my-license/"});exports.packageMetadata=e;
8
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=Object.freeze({name:"@progress/kendo-react-inputs",productName:"KendoReact",productCode:"KENDOUIREACT",productCodes:["KENDOUIREACT"],publishDate: 1776956242,version:"14.4.1-develop.10",licensingDocsUrl:"https://www.telerik.com/kendo-react-ui/components/my-license/"});exports.packageMetadata=e;
@@ -7,7 +7,7 @@ export const packageMetadata = Object.freeze({
7
7
  productName: 'KendoReact',
8
8
  productCode: 'KENDOUIREACT',
9
9
  productCodes: ['KENDOUIREACT'],
10
- publishDate: 1776412826,
11
- version: '14.4.0',
10
+ publishDate: 1776956242,
11
+ version: '14.4.1-develop.10',
12
12
  licensingDocsUrl: 'https://www.telerik.com/kendo-react-ui/components/my-license/'
13
13
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@progress/kendo-react-inputs",
3
- "version": "14.4.0",
3
+ "version": "14.4.1-develop.10",
4
4
  "description": "React Inputs offer a customizable interface for users to enter and pick different information. KendoReact Input package",
5
5
  "author": "Progress",
6
6
  "license": "SEE LICENSE IN LICENSE.md",
@@ -28,14 +28,14 @@
28
28
  "@progress/kendo-drawing": "^1.21.2",
29
29
  "@progress/kendo-inputs-common": "^3.1.0",
30
30
  "@progress/kendo-licensing": "^1.7.2",
31
- "@progress/kendo-react-animation": "14.4.0",
32
- "@progress/kendo-react-buttons": "14.4.0",
33
- "@progress/kendo-react-common": "14.4.0",
34
- "@progress/kendo-react-dialogs": "14.4.0",
35
- "@progress/kendo-react-layout": "14.4.0",
36
- "@progress/kendo-react-intl": "14.4.0",
37
- "@progress/kendo-react-labels": "14.4.0",
38
- "@progress/kendo-react-popup": "14.4.0",
31
+ "@progress/kendo-react-animation": "14.4.1-develop.10",
32
+ "@progress/kendo-react-buttons": "14.4.1-develop.10",
33
+ "@progress/kendo-react-common": "14.4.1-develop.10",
34
+ "@progress/kendo-react-dialogs": "14.4.1-develop.10",
35
+ "@progress/kendo-react-layout": "14.4.1-develop.10",
36
+ "@progress/kendo-react-intl": "14.4.1-develop.10",
37
+ "@progress/kendo-react-labels": "14.4.1-develop.10",
38
+ "@progress/kendo-react-popup": "14.4.1-develop.10",
39
39
  "@progress/kendo-svg-icons": "^4.0.0",
40
40
  "react": "^18.0.0 || ^19.0.0",
41
41
  "react-dom": "^18.0.0 || ^19.0.0"
@@ -82,7 +82,7 @@
82
82
  "package": {
83
83
  "productName": "KendoReact",
84
84
  "productCode": "KENDOUIREACT",
85
- "publishDate": 1776412826,
85
+ "publishDate": 1776956242,
86
86
  "licensingDocsUrl": "https://www.telerik.com/kendo-react-ui/components/my-license/"
87
87
  }
88
88
  },