<TextInput
ref={inputRef}
value={text}
style={styles.textInput}
returnKeyType="next"
placeholder={"placeholder"}
scrollEnabled={false}
blurOnSubmit={false}
onFocus={onFocusInput}
textAlignVertical="center"
onContentSizeChange={onChangeContentSizeChange}
onChangeText={onInputChangeValue}
onBlur={onInputBlur}
onKeyPress={onInputKeyPress}
onSubmitEditing={() => NextScript(id)}
multiline={false}
numberOfLines={5}
/>
The logic is I want onSubmitEditing to take me to next TextInput field and I need the text to wrap one much text is entered. If I enable multiline once enter key is pressed it goes to next line before going to the next input and that's what I am trying to avoid.
Is it possible to replace enter key totally with onSubmitEditing? Anytime I hit enter it attempts to enter newline before moving to next TextInput, so it creates a bad UI where the text is moving up slightly before repositioning then going to next line.
If I set blurOnSubmit to true, it stops but keyboard closes on submit.
If I set multiline to false it stops but doesn't wrap text.
I have created an example,
onKeyPresswill allow you to focus the next textfield when enter key were hit.