File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -29,11 +29,11 @@ storiesOf('Default', module)
2929 onChangeText = { text => onChangeText ( text ) }
3030 labelTextColor = "#3B82F6"
3131 // value={value}
32- icon = { < Text > +91</ Text > }
32+ // icon={<Text>+91</Text>}
3333 borderColor = "#3B82F6"
3434 // color="#3B82F6"
3535 // iconPosition="left"
36- // focusColor ="#22D3EE"
36+ // focusBorderColor ="#22D3EE"
3737 />
3838 ) )
3939 . add ( 'Default Required Field' , ( ) => (
Original file line number Diff line number Diff line change @@ -34,10 +34,8 @@ const Input = ({
3434 const getBorderColor = ( ) => {
3535 if ( error ) {
3636 return props . borderColor || '#DC2626' ;
37- }
38-
39- if ( focused ) {
40- return props . focusColor || props . borderColor || '#52525B' ;
37+ } else if ( focused ) {
38+ return props . focusBorderColor || props . borderColor ;
4139 }
4240 return props . borderColor ;
4341 } ;
@@ -57,21 +55,19 @@ const Input = ({
5755 borderRadius : props . borderRadius || 4 ,
5856 paddingHorizontal : props . paddingHorizontal || 5 ,
5957 marginTop : props . marginTop || 5 ,
60- alignItems : 'icon' ? ' center' : 'baseline ',
58+ alignItems : 'center' ,
6159 borderColor : getBorderColor ( ) ,
6260 flexDirection : getFlexDirection ( ) || 'row' ,
6361 } ) ,
6462 } } >
6563 < View
6664 style = { {
67- flex : 1 ,
6865 alignItems : 'center' ,
6966 } } >
7067 { icon && icon }
7168 </ View >
7269 < View
7370 style = { {
74- flex : 8 ,
7571 height : props . height || 42 ,
7672 } } >
7773 < TextInput
You can’t perform that action at this time.
0 commit comments