react-native-phone-input icon indicating copy to clipboard operation
react-native-phone-input copied to clipboard

How can I style TextComponent Wrapper?

Open wzup opened this issue 7 years ago • 1 comments

How can I add styles to this component? https://github.com/thegamenicorus/react-native-phone-input/blob/master/lib/index.js#L181

I need to have the following styles:

{
    // default
    flex:1;
    marginLeft:10;

    // my custom styles
    minHeight:36;
    alignItems:flex-start;
    justifyContent:center; 
}

wzup avatar Jun 18 '18 17:06 wzup

Use textComponnent prop or pass props to TextComponent via textProps.

<PhoneInput textComponent={CustomTextComponent} />

or

<PhoneInput textProps={{ ...styles.text }} />

goodok21 avatar Aug 25 '19 09:08 goodok21