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

TextInput in Android strange behavior #18182

Closed
gekamikh opened this issue Mar 4, 2018 · 1 comment
Closed

TextInput in Android strange behavior #18182

gekamikh opened this issue Mar 4, 2018 · 1 comment
Labels
Resolution: For Stack Overflow A question for Stack Overflow. Applying this label will cause issue to be closed. Resolution: Locked This issue was locked by the bot.

Comments

@gekamikh
Copy link

gekamikh commented Mar 4, 2018

I have some troubles with text input on Android. I have TextInput with the long default value. This Input placed inside View component with some width. Here the problem: On ios cutting text inside TextInput looks like:
2018-03-03 08 00 56

  • It shows the beginning of the value and cut the end of the value.

But on Android it strange:
2018-03-03 07 59 26

  • it cuts the beginning of the value and shows only end.

How can I make Android behavior same as IOS? Or it's specific Android behavior?

Thank You!

Environment

Environment:
OS: macOS High Sierra 10.13.3
Node: 8.4.0
Yarn: Not Found
npm: 4.6.1
Watchman: 4.7.0
Xcode: Xcode 9.2 Build version 9C40b
Android Studio: 3.0 AI-171.4443003

Packages: (wanted => installed)
react: 16.2.0 => 16.2.0
react-native: 0.52.0 => 0.52.0

Component code

`
import React from 'react';
import { StyleSheet, Text, View, TextInput } from 'react-native';

export default class App extends React.Component {
render() {
return (


<TextInput
style={styles.textInput}
value={'Lorem ipsum dolor sit amet, consectetuer adipiscing elit.'}
underlineColorAndroid={'transparent'}
/>


);
}
}

const styles = StyleSheet.create({
container: {
flex: 1,
backgroundColor: '#fff',
alignItems: 'center',
justifyContent: 'center',
},
textInputContainer: {
width: 200
},
textInput: {
width: 200,
borderWidth: 1,
padding: 5
}
});
`

@hramos
Copy link
Contributor

hramos commented Mar 5, 2018

This issue looks like a question that would be best asked on StackOverflow.

StackOverflow is amazing for Q&A: it has a reputation system, voting, the ability to mark a question as answered. Because of the reputation system it is likely the community will see and answer your question there. This also helps us use the GitHub bug tracker for bugs only.

Will close this as this is really a question that should be asked on StackOverflow.

@hramos hramos closed this as completed Mar 5, 2018
@hramos hramos added the Resolution: For Stack Overflow A question for Stack Overflow. Applying this label will cause issue to be closed. label Mar 5, 2018
@facebook facebook locked as resolved and limited conversation to collaborators Mar 5, 2019
@react-native-bot react-native-bot added the Resolution: Locked This issue was locked by the bot. label Mar 5, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Resolution: For Stack Overflow A question for Stack Overflow. Applying this label will cause issue to be closed. Resolution: Locked This issue was locked by the bot.
Projects
None yet
Development

No branches or pull requests

3 participants