I was wondering if anyone knows if 1. this is possible with react native and 2. how would I go about achieving this. It's nothing too crucial to the application but it's something nice to have. I want to display a users (ios) predetermined phone number contact information above the keyboard when focusing on the input.Here is a picture about what Im talking about shown in safari and other apps. This first image is from Instagram which shows the user email above This second one is from safari, which shows the phone numbers, which is want i want to achieve
This is the code I have for my phone number input
<TextInput
keyboardType="decimal-pad"
placeholder="Phone Number"
placeholderTextColor="#555555"
returnKeyType="next"
selectionColor="#FF5349"
textContentType="username"
/>
autoCompleteType
Specifies autocomplete hints for the system, so it can provide autofill. On Android, the system will always attempt to offer autofill by using heuristics to identify the type of content. To disable autocomplete, set
autoCompleteTypetooff.
<TextInput
autoCompleteType="tel" // <-- suggestion for telephone autocompletion
keyboardType="decimal-pad"
placeholder="Phone Number"
placeholderTextColor="#555555"
returnKeyType="next"
selectionColor="#FF5349"
textContentType="username"
/>
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With