When using countryCallingCodeEditable={false} to prevent editing of the country calling code, attempting to clear the leading "+" sign still results in the code being added back to the input.
Steps to Reproduce:
Set countryCallingCodeEditable={false} on the react-phone-number-input component.
Focus on the input field and move the cursor till + sign
Try to clear the + sign using backspace
Expected Behavior:
The country calling code should not get added to the input
Actual Behavior:
The country calling code is unexpectedly inserted back into the input field.
Code
<PhoneInput
international
countryCallingCodeEditable={false}
defaultCountry="RU"
value={value}
onChange={setValue}/>
Description:
When using
countryCallingCodeEditable={false}
to prevent editing of the country calling code, attempting to clear the leading "+" sign still results in the code being added back to the input.Steps to Reproduce:
countryCallingCodeEditable={false}
on the react-phone-number-input component.Expected Behavior:
Actual Behavior:
Code
Additional Information The issue can be reproduced on https://catamphetamine.gitlab.io/react-phone-number-input/ Force international format section's 2nd example
https://github.com/catamphetamine/react-phone-number-input/assets/25284953/eef46796-f85a-4708-b040-5def6dc349db