Skip to content

Commit

Permalink
use ColorValue for color props (#53)
Browse files Browse the repository at this point in the history
  • Loading branch information
vonovak committed Mar 12, 2020
1 parent fbff454 commit 1ff3fb3
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions js/RNCSegmentedControlNativeComponent.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ import {requireNativeComponent} from 'react-native';
import type {ViewProps} from 'react-native/Libraries/Components/View/ViewPropTypes';
import type {SyntheticEvent} from 'react-native/Libraries/Types/CoreEventTypes';
import type {NativeComponent} from 'react-native/Libraries/Renderer/shims/ReactNative';
import type {ColorValue} from 'react-native/Libraries/StyleSheet/StyleSheetTypes';

type Event = SyntheticEvent<
$ReadOnly<{|
Expand Down Expand Up @@ -50,22 +51,22 @@ export type SegmentedControlIOSProps = $ReadOnly<{|
/**
* Accent color of the control.
*/
tintColor?: ?string,
tintColor?: ?ColorValue,
/**
* Text color of the control.
* NOTE: this prop will only work for iOS >= 13
*/
textColor?: ?string,
textColor?: ?ColorValue,
/**
* Text color of the control when selected.
* NOTE: this prop will only work for iOS >= 13
*/
activeTextColor?: ?string,
activeTextColor?: ?ColorValue,
/**
* Background color of the control.
* NOTE: this prop will only work for iOS >= 13
*/
backgroundColor?: ?string,
backgroundColor?: ?ColorValue,
/**
* If true, then selecting a segment won't persist visually.
* The `onValueChange` callback will still work as expected.
Expand Down

0 comments on commit 1ff3fb3

Please sign in to comment.