Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -258,10 +258,18 @@ - (void)updateProps:(const Props::Shared &)props oldProps:(const Props::Shared &

if (newTextInputProps.traits.keyboardType != oldTextInputProps.traits.keyboardType) {
_backedTextInputView.keyboardType = RCTUIKeyboardTypeFromKeyboardType(newTextInputProps.traits.keyboardType);
// Without the call to reloadInputViews, the keyboard will not change until the textInput field (the first
// responder) loses and regains focus. Matches the legacy-architecture behavior in RCTBaseTextInputView.
if (_backedTextInputView.isFirstResponder) {
[_backedTextInputView reloadInputViews];
}
}

if (newTextInputProps.traits.returnKeyType != oldTextInputProps.traits.returnKeyType) {
_backedTextInputView.returnKeyType = RCTUIReturnKeyTypeFromReturnKeyType(newTextInputProps.traits.returnKeyType);
if (_backedTextInputView.isFirstResponder) {
[_backedTextInputView reloadInputViews];
}
}

if (newTextInputProps.traits.textContentType != oldTextInputProps.traits.textContentType) {
Expand Down