@bigbinary/neetoui 5.2.40 → 5.2.41

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/index.js CHANGED
@@ -21113,11 +21113,15 @@ var Input$3 = /*#__PURE__*/forwardRef$1(function (_ref, ref) {
21113
21113
  onChange(e);
21114
21114
  };
21115
21115
  var handleChange = rejectCharsRegex ? handleRegexChange : onChange;
21116
+ var handleTrimmedChangeOnBlur = function handleTrimmedChangeOnBlur(e) {
21117
+ if (disableTrimOnBlur || typeof value !== "string") return;
21118
+ var trimmedValue = value.trim();
21119
+ if (value === trimmedValue) return;
21120
+ e.target.value = trimmedValue;
21121
+ handleChange(e);
21122
+ };
21116
21123
  var handleOnBlur = function handleOnBlur(e) {
21117
- if (!disableTrimOnBlur && typeof value === "string") {
21118
- e.target.value = value.trim();
21119
- handleChange(e);
21120
- }
21124
+ handleTrimmedChangeOnBlur(e);
21121
21125
  onBlur === null || onBlur === void 0 || onBlur(e);
21122
21126
  };
21123
21127
  return /*#__PURE__*/React__default.createElement("div", {