intelicoreact 0.1.68 → 0.1.69

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.
@@ -1092,18 +1092,22 @@ function InputMask() {
1092
1092
  setMaskRendered(true);
1093
1093
  }, [maskPattern]);
1094
1094
  (0, _react.useEffect)(function () {
1095
- if (!isMaskRendered || isInitValue) return false;
1095
+ if (!isMaskRendered || isInitValue || maskPattern.replace(/D/g, '') === (value === null || value === void 0 ? void 0 : value.toString())) return false;
1096
1096
 
1097
1097
  if (value && value !== '' && value !== getClearInnerValueAsString()) {
1098
1098
  var valueCharIndex = 0;
1099
1099
  innerValue.map(function (_ref25, i) {
1100
+ var _maskPattern;
1101
+
1100
1102
  var isSpecialSymbol = _ref25.isSpecialSymbol;
1101
1103
  if (isSpecialSymbol) return false;
1102
1104
  var char = value[valueCharIndex];
1105
+ var whileLimit = ((_maskPattern = maskPattern) === null || _maskPattern === void 0 ? void 0 : _maskPattern.length) || 0;
1103
1106
 
1104
- while (isSpecialSymbolChar({
1107
+ while (whileLimit && isSpecialSymbolChar({
1105
1108
  char: value[valueCharIndex]
1106
1109
  })) {
1110
+ whileLimit--;
1107
1111
  char = value[++valueCharIndex];
1108
1112
  } //If Valid
1109
1113
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "intelicoreact",
3
- "version": "0.1.68",
3
+ "version": "0.1.69",
4
4
  "description": "fix input mask cycling",
5
5
  "main": "dist/index.js",
6
6
  "files": [