intelicoreact 1.0.12 → 1.0.14
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.
|
@@ -499,6 +499,7 @@ function InputMask2() {
|
|
|
499
499
|
|
|
500
500
|
|
|
501
501
|
(0, _react.useEffect)(function () {
|
|
502
|
+
setIsInitValue(false);
|
|
502
503
|
setInnerValue([]);
|
|
503
504
|
setMaskRendered(false);
|
|
504
505
|
if (!maskPattern) maskPattern = '';
|
|
@@ -518,7 +519,7 @@ function InputMask2() {
|
|
|
518
519
|
setMaskRendered(true);
|
|
519
520
|
}, [maskPattern]);
|
|
520
521
|
(0, _react.useEffect)(function () {
|
|
521
|
-
if (isMaskRendered && !isInitValue || value
|
|
522
|
+
if (isMaskRendered && !isInitValue || value !== getInputValue() && value !== '') {
|
|
522
523
|
setValue(value);
|
|
523
524
|
setIsInitValue(true);
|
|
524
525
|
}
|
|
@@ -531,7 +532,7 @@ function InputMask2() {
|
|
|
531
532
|
}, [isFocusedDefault, isMaskRendered]); // OnChange Observer
|
|
532
533
|
|
|
533
534
|
(0, _react.useEffect)(function () {
|
|
534
|
-
if (
|
|
535
|
+
if (isMaskRendered && isInitValue && value) {
|
|
535
536
|
var _prevValueRef$current, _prevValueRef$current2;
|
|
536
537
|
|
|
537
538
|
setError(false);
|
|
@@ -543,7 +544,7 @@ function InputMask2() {
|
|
|
543
544
|
onChangeProp.apply(void 0, values);
|
|
544
545
|
}
|
|
545
546
|
}
|
|
546
|
-
}, [innerValue, isMaskRendered, isInitValue]); // Blink Error
|
|
547
|
+
}, [innerValue, isMaskRendered, isInitValue, value]); // Blink Error
|
|
547
548
|
|
|
548
549
|
(0, _react.useEffect)(function () {
|
|
549
550
|
if (blinkError) {
|