Files
react-native/packages/react-native-codegen/e2e/__test_fixtures__/components/ArrayPropsNativeComponent.js
T
Zack Argyle 0a67133124 Make ColorValue public in StyleSheet.js
Summary:
This diff makes the ColorValue export "official" by exporting it from StyleSheet in order to encourage its use in product code.

Changelog: Moved ColorValue export from StyleSheetTypes to StyleSheet

Reviewed By: TheSavior

Differential Revision: D21076969

fbshipit-source-id: 972ef5a1b13bd9f6b7691a279a73168e7ce9d9ab
2020-04-17 13:03:47 -07:00

47 lines
1.5 KiB
JavaScript

/**
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*
* @format
* @flow strict-local
*/
'use strict';
import type {
PointValue,
EdgeInsetsValue,
} from '../../../../../Libraries/StyleSheet/StyleSheetTypes';
import type {ColorValue} from '../../../../../Libraries/StyleSheet/StyleSheet';
import type {ImageSource} from '../../../../../Libraries/Image/ImageSource';
import type {
Int32,
Float,
WithDefault,
} from '../../../../../Libraries/Types/CodegenTypes';
import type {ViewProps} from '../../../../../Libraries/Components/View/ViewPropTypes';
import codegenNativeComponent from '../../../../../Libraries/Utilities/codegenNativeComponent';
import type {HostComponent} from '../../../../../Libraries/Renderer/shims/ReactNativeTypes';
type NativeProps = $ReadOnly<{|
...ViewProps,
// Props
names?: $ReadOnlyArray<string>,
disableds?: $ReadOnlyArray<boolean>,
progress?: $ReadOnlyArray<Int32>,
radii?: $ReadOnlyArray<Float>,
colors?: $ReadOnlyArray<ColorValue>,
srcs?: $ReadOnlyArray<ImageSource>,
points?: $ReadOnlyArray<PointValue>,
edgeInsets?: $ReadOnlyArray<EdgeInsetsValue>,
sizes?: WithDefault<$ReadOnlyArray<'small' | 'large'>, 'small'>,
object?: $ReadOnlyArray<$ReadOnly<{|prop: string|}>>,
|}>;
export default (codegenNativeComponent<NativeProps>(
'ArrayPropsNativeComponentView',
): HostComponent<NativeProps>);