From 69d9940f9f4dbf239431b90285b5965d2135bee3 Mon Sep 17 00:00:00 2001 From: chetanbnagmoti <119286565+chetanbnagmoti@users.noreply.github.com> Date: Tue, 3 Dec 2024 15:57:44 +0530 Subject: [PATCH] Update index.js Check This Because Off This Input inserting restriction for user when country code with input number more than 15 --- src/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/index.js b/src/index.js index e4eb729..ff7dca8 100644 --- a/src/index.js +++ b/src/index.js @@ -252,7 +252,7 @@ class ReactPhoneInput extends React.Component { freezeSelection = this.state.freezeSelection; //Does not exceed 16 digit phone number limit - if(event.target.value.replace(/\D/g, '').length > 16) { + if(event.target.value.replace(/\D/g, '').length > this.props.maxLength ? this.props.maxLength : 16) { return; }