-
Notifications
You must be signed in to change notification settings - Fork 24.2k
-
Notifications
You must be signed in to change notification settings - Fork 24.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Can´t focus a custom textInput #20668
Labels
Component: TextInput
Related to the TextInput component.
Resolution: Locked
This issue was locked by the bot.
Comments
react-native-bot
added
Component: TextInput
Related to the TextInput component.
⏪Old Version
labels
Aug 14, 2018
Can you reproduce the issue on the latest release, v0.56? |
Add a method to your custom component that will return a reference to the TextInput.
|
It worked..... wohoooo |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Labels
Component: TextInput
Related to the TextInput component.
Resolution: Locked
This issue was locked by the bot.
Environment
Environment:
OS: Windows 10
Node: 8.9.1
Yarn: Not Found
npm: 5.6.0
Watchman: Not Found
Xcode: N/A
Android Studio: Version 3.0.0.0 AI-171.4443003
Packages: (wanted => installed)
react: ^16.3.1 => 16.3.1
react-native: ^0.55.4 => 0.55.4
Description
Hello.
I have a question.
I have two textInput, and need to make pass from the first textinput to the second.
I created a customtextInput with the code below:
render() {
return (
<View style={[styles.outside, this.props.style]} >
<TextInput
placeholderTextColor="#dadada"
underlineColorAndroid="transparent"
{...this.props}
style={styles.txtInput}
/>
);
const styles = StyleSheet.create({
txtInput: {
color: 'white',
fontFamily: 'Poppins-Regular',
flex: 1,
fontSize: 15,
},
outside: {
paddingHorizontal: 18,
paddingTop: 4,
paddingBottom: Platform.select({ android: 1, ios: 4 }),
borderRadius: 30,
backgroundColor: '#4f4f4fa3',
flexDirection: 'row',
},
icon: {
marginTop: Platform.select({ android: 3, ios: 0 }),
},
});
this is the customtextinput code
my problem is that it returns error when trying to make the setfocus
Thank you
Reproducible Demo
react-native run-android
The text was updated successfully, but these errors were encountered: