ps-toolkit-ui 1.7.40 → 1.7.43
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bundles/ps-toolkit-ui.umd.js +3 -3
- package/bundles/ps-toolkit-ui.umd.js.map +1 -1
- package/bundles/ps-toolkit-ui.umd.min.js +1 -1
- package/bundles/ps-toolkit-ui.umd.min.js.map +1 -1
- package/esm2015/lib/components/form/textbox/form.textbox.component.js +4 -4
- package/fesm2015/ps-toolkit-ui.js +3 -3
- package/fesm2015/ps-toolkit-ui.js.map +1 -1
- package/package.json +1 -1
|
@@ -5924,13 +5924,13 @@
|
|
|
5924
5924
|
}
|
|
5925
5925
|
if (_this.inp.type === exports.InputType.Number || _this.inp.type === exports.InputType.Price) {
|
|
5926
5926
|
var v = _this.inp.value.toString().replace(/,/g, '');
|
|
5927
|
-
if (
|
|
5927
|
+
if (!/^-?\d+([.,]\d+)?$/.test(v)) {
|
|
5928
5928
|
_this.inp.error = exports.InputError.Invalid;
|
|
5929
5929
|
return false;
|
|
5930
5930
|
}
|
|
5931
5931
|
}
|
|
5932
5932
|
if (_this.inp.type === exports.InputType.Number || _this.inp.type === exports.InputType.Price) {
|
|
5933
|
-
var v =
|
|
5933
|
+
var v = parseFloat(_this.inp.value.replace(/,/g, ''));
|
|
5934
5934
|
if (_this.inp.required && _this.inp.minLength !== -1 && v < _this.inp.minLength) {
|
|
5935
5935
|
_this.inp.error = exports.InputError.MinAmount;
|
|
5936
5936
|
return false;
|
|
@@ -5971,7 +5971,7 @@
|
|
|
5971
5971
|
return null;
|
|
5972
5972
|
}
|
|
5973
5973
|
if (v && _this.inp.type === exports.InputType.Number || _this.inp.type === exports.InputType.Price) {
|
|
5974
|
-
v =
|
|
5974
|
+
v = parseFloat(v.replace(/,/g, ''));
|
|
5975
5975
|
}
|
|
5976
5976
|
return v;
|
|
5977
5977
|
};
|