react-native-paper icon indicating copy to clipboard operation
react-native-paper copied to clipboard

TextInput (underlineColor) is not working in android devices

Open anveshreddy87 opened this issue 7 years ago • 6 comments

Environment

"react": "16.8.3", "react-native": "0.59.8", "react-native-paper": "2.16.0",

Description

In TextInput Component underlineColor is not working as expected. i tried different ways but underlineColor is not reflecting in android devices. i given hex value, rgba value, string color value. still same thing its not reflecting.

I don't want to show underline in android device while user starts entering the TextInput box. Please help to fix this issue...i attached the sample expo and code.

Reproducible Demo

https://snack.expo.io/@anveshreddy8787/paper-textinput-refs

Sample Code: <TextInput mode = "outlined" ref = {this.lastName} underlineColor='#ff0000' value = { this.state.lastName } style = { { marginVertical: 20, marginRight: 40, marginLeft: 20, } } label = "Last Name" theme = { { colors: { primary: 'purple', background: 'white' } } }

  keyboardType = 'default'
  returnKeyType = 'next'
  autoCapitalize = 'words'
  onChangeText = {(value) => this.setState({lastName: value})}
  onSubmitEditing = {(event) => {this.dateOfBirth.current.getElement().focus()}}
  /> 

anveshreddy87 avatar Jun 16 '19 19:06 anveshreddy87

Try without outlined mode.

netochaves avatar Jun 16 '19 22:06 netochaves

I need outlined mode...is their a way to change underlineColor for Android?

anveshreddy87 avatar Jun 17 '19 13:06 anveshreddy87

Change the primary color in the theme

iyadthayyil avatar Jun 17 '19 13:06 iyadthayyil

primary color is reflecting on the box....I don’t want to see any underline while user entering the characters in textinput box....In Android usually will see a underline while user starts typing in textinput box....

React-native: their is a property to hide the underline color specifically for Android (underlineColorAndroid).....

In that way is their any property to hide underline color?

Thanks

anveshreddy87 avatar Jun 17 '19 13:06 anveshreddy87

Hi @anveshreddy87 Thanks for posting issue. We have #688 and #775 which will be sorted out soon. It also should solve your issue. Please stay tuned :)

jbinda avatar Jun 18 '19 10:06 jbinda

Still got the issue, any idea?

Real device Xiaomi Redmi 1S Android 4.4 Kitkat

 "react": "16.13.1",
 "react-native": "0.63.2",
 "react-native-paper": "^4.2.0",

VEmpink avatar Oct 10 '20 02:10 VEmpink