I need to disable emojis for my chat app. When my keyboard appear, the emoji icon is visible and i need to make it unavailable to insert emojis in discussions.
Any suggestions ?
this is not directly related to this package. check some of the answers for native iOS solutions
https://stackoverflow.com/questions/25861468/how-to-disable-ios-8-emoji-keyboard
Thanks but these solutions aren't applicable on a react native configuration.
I need to change the keyboard type inside react-native-gifted-chat
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
For anyone looking for possible solutions, you can pass textInputProps to the Composer component. You can use that to change the keyboardType to something that doesn't allow emojis. For instance textInputProps={{keyboardType: Platform.OS === 'android' ? 'visible-password' : 'ascii-capable'}}. You can see a visual representation of the keyboard types here: https://lefkowitz.me/visual-guide-to-react-native-textinput-keyboardtype-options/. I did this in the renderComposer method.
Most helpful comment
For anyone looking for possible solutions, you can pass
textInputPropsto theComposercomponent. You can use that to change thekeyboardTypeto something that doesn't allow emojis. For instancetextInputProps={{keyboardType: Platform.OS === 'android' ? 'visible-password' : 'ascii-capable'}}. You can see a visual representation of the keyboard types here: https://lefkowitz.me/visual-guide-to-react-native-textinput-keyboardtype-options/. I did this in therenderComposermethod.