@typeolymp/ui-components 1.19.4 → 1.19.5
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/build/index.es.js +6 -2
- package/build/index.es.js.map +1 -1
- package/build/index.js +6 -2
- package/build/index.js.map +1 -1
- package/package.json +1 -1
package/build/index.js
CHANGED
|
@@ -8056,11 +8056,15 @@ var Number$1 = function (props) {
|
|
|
8056
8056
|
};
|
|
8057
8057
|
var onChange = function () {
|
|
8058
8058
|
var value = parseInt(inputRef.current.value);
|
|
8059
|
-
var newValue = setValue(value);
|
|
8060
8059
|
if (!props.disabled && !!props.onChange)
|
|
8061
|
-
props.onChange(
|
|
8060
|
+
props.onChange(value);
|
|
8062
8061
|
};
|
|
8063
8062
|
var onBlur = function () {
|
|
8063
|
+
var value = parseInt(inputRef.current.value);
|
|
8064
|
+
var newValue = setValue(value);
|
|
8065
|
+
// If the value has changed, call the onChange callback
|
|
8066
|
+
if (value !== newValue && !!props.onChange)
|
|
8067
|
+
props.onChange(newValue);
|
|
8064
8068
|
if (!!props.onBlur)
|
|
8065
8069
|
props.onBlur();
|
|
8066
8070
|
};
|