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

multiline TextInput scrolling #1391

Closed
d-vine opened this issue May 24, 2015 · 5 comments
Closed

multiline TextInput scrolling #1391

d-vine opened this issue May 24, 2015 · 5 comments
Labels
Resolution: Locked This issue was locked by the bot.

Comments

@d-vine
Copy link

d-vine commented May 24, 2015

I'm building a multiline text input component the grows for the first n lines and after that just scrolls as usual.

The growing it self and the scrolling after it's reached it's maximum height are working fine. But when I grow the box after adding a line break the scroll position of the text in the box is completely off.

For this to work I probably would either need to be able to disable scrolling or to have access to a scrollTo() method. Since I'm completely new to iOS and Objective-C, I unfortunately haven't figured out any of the two yet. Suggestions would be greatly appreciated.

@brentvatne
Copy link
Collaborator

Hi @dvine-multimedia - check out this pull request: #1229

If that doesn't help, join us in irc (freenode #reactnative), these types of questions are better suited for discussion in that context 😄

@marcshilling
Copy link

@dvine-multimedia could you share your growing text input component? I have a similar need

@d-vine
Copy link
Author

d-vine commented Jun 20, 2015

@marcshilling Sorry, I abandoned my original approach because it was not working properly. I still haven't figured out, how to access the "onLayoutChange" event of the underlying scroll view for a multi-line input. In addition to that I would also need access to some scrolling functionality to keep the text in the correct position after re-sizing the input. I when with a fixed height input for now but surely will re-evaluate the issue in the not so distant future.

@chrise86
Copy link

@dvine-multimedia did you ever manage to manipulate the underlying scroll view for a multine input? I have a similar situation where I need to scroll the text input to the bottom after bulk text is inserted.

@duhecx
Copy link

duhecx commented Oct 18, 2017

Same here. Access to the textInput's content scroll would be great.

@facebook facebook locked as resolved and limited conversation to collaborators May 29, 2018
@react-native-bot react-native-bot added the Resolution: Locked This issue was locked by the bot. label Jul 22, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Resolution: Locked This issue was locked by the bot.
Projects
None yet
Development

No branches or pull requests

6 participants