1616import * as React from 'react' ;
1717import { processColor , StyleSheet , View } from 'react-native' ;
1818import RNCPickerNativeComponent from './RNCPickerNativeComponent' ;
19+ import type { RNCPickerIOSType } from './RNCPickerNativeComponent' ;
1920
2021import type { SyntheticEvent } from 'react-native/Libraries/Types/CoreEventTypes' ;
2122import type { ColorValue } from 'react-native/Libraries/StyleSheet/StyleSheet' ;
@@ -38,17 +39,6 @@ type RNCPickerIOSItemType = $ReadOnly<{|
3839 testID : ?string ,
3940| } > ;
4041
41- type RNCPickerIOSType = HostComponent <
42- $ReadOnly < { |
43- items : $ReadOnlyArray < RNCPickerIOSItemType > ,
44- onChange : ( event : PickerIOSChangeEvent ) => void ,
45- selectedIndex : number ,
46- style ?: ?TextStyleProp ,
47- testID ?: ?string ,
48- numberOfLines ?: ?number ,
49- | } > ,
50- > ;
51-
5242type Label = Stringish | number ;
5343
5444type Props = $ReadOnly < { |
@@ -59,6 +49,7 @@ type Props = $ReadOnly<{|
5949 onValueChange ?: ?( itemValue : string | number , itemIndex : number ) => mixed ,
6050 selectedValue : ?( number | string ) ,
6151 numberOfLines : ?number ,
52+ themeVariant : ?string ,
6253| } > ;
6354
6455type State = { |
@@ -115,6 +106,7 @@ class PickerIOS extends React.Component<Props, State> {
115106 ref = { ( picker ) => {
116107 this . _picker = picker ;
117108 } }
109+ themeVariant = { this . props . themeVariant }
118110 testID = { this . props . testID }
119111 style = { [ styles . pickerIOS , this . props . itemStyle ] }
120112 items = { this . state . items }
0 commit comments