Skip to content
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

How to add more than a input on component #7

Open
kungfu321 opened this issue Apr 20, 2021 · 0 comments
Open

How to add more than a input on component #7

kungfu321 opened this issue Apr 20, 2021 · 0 comments

Comments

@kungfu321
Copy link

I'm trying this code, but it's not work

<TextInput
        ref={inputTextRef}
        nativeID={'component_text_input'}
        placeholder={'TextInput'}
        placeholderTextColor={'gray'}
        clearButtonMode={'always'}
        autoCorrect={false}
        autoFocus={false}
        style={styles.textInput}
      />
      {Platform.OS === 'android' && (
        <FocusableHighlight
          onPress={() => {}}
          onFocus={() => {
            if (inputTextRef.current) {
              inputTextRef.current.focus();
            }
          }}
          style={styles.dummyButton}>
          <Text />
        </FocusableHighlight>
      )}
      <TextInput
        ref={inputTextRef2}
        nativeID={'component_text_input2'}
        placeholder={'TextInput'}
        placeholderTextColor={'gray'}
        clearButtonMode={'always'}
        autoCorrect={false}
        autoFocus={false}
        style={styles.textInput}
      />
      {Platform.OS === 'android' && (
        <FocusableHighlight
          onPress={() => {}}
          onFocus={() => {
            if (inputTextRef2.current) {
              inputTextRef2.current.focus();
            }
          }}
          style={styles.dummyButton}>
          <Text />
        </FocusableHighlight>
      )}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant