Skip to content
This repository has been archived by the owner on Nov 27, 2022. It is now read-only.

TextInput Keyboard does not work with tabs #1299

Open
2 of 5 tasks
SupriyaPKalghatgi opened this issue Dec 7, 2021 · 8 comments
Open
2 of 5 tasks

TextInput Keyboard does not work with tabs #1299

SupriyaPKalghatgi opened this issue Dec 7, 2021 · 8 comments

Comments

@SupriyaPKalghatgi
Copy link

Current behavior

iOS: TextInput hides behind Keyboard
image

Android: Need to click twice on textInput

Expected behavior

iOS: TextInput should be scrolled when Keyboard is open
Android: TextInput should remain open on 1st click

Reproduction

https://snack.expo.dev/qhAuLMpOh

Platform

  • Android
  • iOS
  • Web
  • Windows
  • MacOS

Environment

package version
react-native-tab-view ^3.1.1
react-native-pager-view 5.4.6
react-native 0.64.3
expo ^43.0.0
node 16.13.0
npm or yarn 8.1.0, 1.22.17
@github-actions
Copy link

github-actions bot commented Dec 7, 2021

The versions mentioned in the issue for the following packages differ from the latest versions on npm:

  • react-native-pager-view (found: 5.4.6, latest: 5.4.9)
  • react-native (found: 0.64.3, latest: 0.66.3)
  • expo (found: 43.0.0, latest: 43.0.3)

Can you verify that the issue still exists after upgrading to the latest versions of these packages?

@SupriyaPKalghatgi
Copy link
Author

The issue is with latest versions too

@SupriyaPKalghatgi SupriyaPKalghatgi changed the title TextInput does not work with tabs TextInput Keyboard does not work with tabs Dec 8, 2021
@github-actions
Copy link

github-actions bot commented Dec 8, 2021

The versions mentioned in the issue for the following packages differ from the latest versions on npm:

  • react-native-pager-view (found: 5.4.6, latest: 5.4.9)
  • react-native (found: 0.64.3, latest: 0.66.3)
  • expo (found: 43.0.0, latest: 43.0.4)

Can you verify that the issue still exists after upgrading to the latest versions of these packages?

@SupriyaPKalghatgi
Copy link
Author

@satya164 Can you please confirm on this?

@okwasniewski
Copy link
Collaborator

Hey @SupriyaPKalghatgi please check this snack I think it might help you. Let me know if it fixed the issue for you.

@SupriyaPKalghatgi
Copy link
Author

@okwasniewski Hey! Thanks for taking a look over this
I checked your snack, Textbox doesn't take input

@okwasniewski
Copy link
Collaborator

Textbox doesn't take input

@SupriyaPKalghatgi I've updated the snack, my point was that it now avoids the keyboard both on iOS and Android.

@yoann84
Copy link

yoann84 commented Oct 3, 2022

It finally works for me by offsetting the size of the view with keyboardVerticalOffset

<KeyboardAvoidingView style={{ flex: 1 }} keyboardVerticalOffset={bottomTabHeight + 100} // where 100 is the size of the view behavior={Platform.OS === "ios" ? "padding" : "height"}> <KlubFeedMessage /> </KeyboardAvoidingView>

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants