Stylization of the React Native Picker

Good Morning,

I'm using Styled Components in the stylization of my components in a React Native app, and I'm trying to put a colored, rounded border in my Picker, but the same is rendered without the stylization. The code I am using is as follows:

const InputSexo = styled.Picker`
margin-top: 10px;
margin-bottom: 10px;
font-size: 15px;
border: 1px solid #7b70e6;
width: 50%;
height: 50px;
border-radius: 25px;
padding: 15px;
color: #7b70e6;

`;

I am developing this app using Expo to test on my Android phone.

Author: Cristiano Nunes, 2020-03-18

1 answers

Just create a view with the stylization you want and use it by wrapping the picker component. This for an android project, on iOS the picker has a different behavior.

 0
Author: Maurício Soares, 2020-03-21 20:14:28