intelicoreact 1.1.53 → 1.1.54
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.
|
@@ -72,6 +72,8 @@ function InputMask3() {
|
|
|
72
72
|
hiddenChar = _ref$hiddenChar === void 0 ? '*' : _ref$hiddenChar,
|
|
73
73
|
_ref$withHiddenMode = _ref.withHiddenMode,
|
|
74
74
|
withHiddenMode = _ref$withHiddenMode === void 0 ? false : _ref$withHiddenMode,
|
|
75
|
+
_ref$maxHiddenIndex = _ref.maxHiddenIndex,
|
|
76
|
+
maxHiddenIndex = _ref$maxHiddenIndex === void 0 ? -1 : _ref$maxHiddenIndex,
|
|
75
77
|
icon = _ref.icon,
|
|
76
78
|
showIcon = _ref.showIcon,
|
|
77
79
|
isIconLeft = _ref.isIconLeft,
|
|
@@ -439,7 +441,7 @@ function InputMask3() {
|
|
|
439
441
|
isSpecialSymbol = _ref10.isSpecialSymbol;
|
|
440
442
|
|
|
441
443
|
if (char !== '' && isValid && (!noLastTyppedCharIndexCheck ? i <= lastTyppedCharIndex : true)) {
|
|
442
|
-
if (isValueHidden && !isSpecialSymbol && !noHide) {
|
|
444
|
+
if (isValueHidden && !isSpecialSymbol && !noHide && (maxHiddenIndex === -1 || i <= maxHiddenIndex)) {
|
|
443
445
|
result += hiddenChar;
|
|
444
446
|
} else {
|
|
445
447
|
result += char;
|
|
@@ -550,7 +552,7 @@ function InputMask3() {
|
|
|
550
552
|
|
|
551
553
|
var numValue = value.replace(/\D/g, '');
|
|
552
554
|
var newSSN = '';
|
|
553
|
-
var staticLength =
|
|
555
|
+
var staticLength = maxHiddenIndex !== -1 ? maxHiddenIndex : (_maskPattern3 = maskPattern) === null || _maskPattern3 === void 0 ? void 0 : _maskPattern3.length;
|
|
554
556
|
|
|
555
557
|
if (SSN.length > staticLength) {
|
|
556
558
|
newSSN = SSN.slice(0, staticLength) + numValue;
|
|
@@ -710,7 +712,7 @@ function InputMask3() {
|
|
|
710
712
|
};
|
|
711
713
|
|
|
712
714
|
var renderValueChar = function renderValueChar(obj, i) {
|
|
713
|
-
return isValueHidden ? renderChar(_objectSpread(_objectSpread({}, obj), {}, {
|
|
715
|
+
return isValueHidden && (maxHiddenIndex === -1 || i <= maxHiddenIndex) ? renderChar(_objectSpread(_objectSpread({}, obj), {}, {
|
|
714
716
|
char: hiddenChar
|
|
715
717
|
}), i, 'input-mask_value_item_value-hidden-char') : renderChar(obj, i, 'input-mask_value_item_value-char');
|
|
716
718
|
};
|