Skip to content

Commit 80c26b5

Browse files
j-piaseckifacebook-github-bot
authored andcommitted
Export TransformsStyle from StyleSheet (facebook#50126)
Summary: Pull Request resolved: facebook#50126 Changelog: [Internal] Reviewed By: huntie Differential Revision: D71467141 fbshipit-source-id: 20077e4748abfd623cf0cb0b4852ba7c6f3973f8
1 parent 84499bf commit 80c26b5

File tree

4 files changed

+18
-1
lines changed

4 files changed

+18
-1
lines changed

packages/react-native/Libraries/StyleSheet/StyleSheet.js

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ import type {
1919
____ImageStyleProp_Internal,
2020
____TextStyle_Internal,
2121
____TextStyleProp_Internal,
22+
____TransformStyle_Internal,
2223
____ViewStyle_Internal,
2324
____ViewStyleProp_Internal,
2425
} from './StyleSheetTypes';
@@ -37,6 +38,11 @@ export type {NativeColorValue} from './StyleSheetTypes';
3738
*/
3839
export type ColorValue = ____ColorValue_Internal;
3940

41+
/**
42+
* This type is an object of the properties related to transforms.
43+
*/
44+
export type TransformStyle = ____TransformStyle_Internal;
45+
4046
/**
4147
* This type should be used as the type for a prop that is passed through
4248
* to a <View>'s `style` prop. This ensures call sites of the component

packages/react-native/Libraries/StyleSheet/StyleSheet.js.flow

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ import type {
1818
____ImageStyleProp_Internal,
1919
____TextStyle_Internal,
2020
____TextStyleProp_Internal,
21+
____TransformStyle_Internal,
2122
____ViewStyle_Internal,
2223
____ViewStyleProp_Internal,
2324
} from './StyleSheetTypes';
@@ -40,6 +41,11 @@ export type {NativeColorValue} from './StyleSheetTypes';
4041
*/
4142
export type ColorValue = ____ColorValue_Internal;
4243

44+
/**
45+
* This type is an object of the properties related to transforms.
46+
*/
47+
export type TransformStyle = ____TransformStyle_Internal;
48+
4349
/**
4450
* This type should be used as the type for a prop that is passed through
4551
* to a <View>'s `style` prop. This ensures call sites of the component

packages/react-native/Libraries/StyleSheet/StyleSheetTypes.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,8 @@ import type {
2121
} from './private/_StyleSheetTypesOverrides';
2222
import type {____TransformStyle_Internal} from './private/_TransformStyle';
2323

24+
export type {____TransformStyle_Internal};
25+
2426
declare export opaque type NativeColorValue;
2527
export type ____ColorValue_Internal = null | string | number | NativeColorValue;
2628
export type ColorArrayValue = null | $ReadOnlyArray<____ColorValue_Internal>;

packages/react-native/Libraries/__tests__/__snapshots__/public-api-test.js.snap

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7371,6 +7371,7 @@ exports[`public API should not change unintentionally Libraries/StyleSheet/Style
73717371
"declare const StyleSheet: StyleSheetExports;
73727372
export type { NativeColorValue } from \\"./StyleSheetTypes\\";
73737373
export type ColorValue = ____ColorValue_Internal;
7374+
export type TransformStyle = ____TransformStyle_Internal;
73747375
export type ViewStyleProp = ____ViewStyleProp_Internal;
73757376
export type TextStyleProp = ____TextStyleProp_Internal;
73767377
export type ImageStyleProp = ____ImageStyleProp_Internal;
@@ -7396,6 +7397,7 @@ export type StyleSheetProperties = {
73967397
};
73977398
export type { NativeColorValue } from \\"./StyleSheetTypes\\";
73987399
export type ColorValue = ____ColorValue_Internal;
7400+
export type TransformStyle = ____TransformStyle_Internal;
73997401
export type ViewStyleProp = ____ViewStyleProp_Internal;
74007402
export type TextStyleProp = ____TextStyleProp_Internal;
74017403
export type ImageStyleProp = ____ImageStyleProp_Internal;
@@ -7456,7 +7458,8 @@ declare export const create: <+S: ____Styles_Internal>(obj: S) => $ReadOnly<S>;
74567458
`;
74577459

74587460
exports[`public API should not change unintentionally Libraries/StyleSheet/StyleSheetTypes.js 1`] = `
7459-
"declare export opaque type NativeColorValue;
7461+
"export type { ____TransformStyle_Internal };
7462+
declare export opaque type NativeColorValue;
74607463
export type ____ColorValue_Internal = null | string | number | NativeColorValue;
74617464
export type ColorArrayValue = null | $ReadOnlyArray<____ColorValue_Internal>;
74627465
export type PointValue = {

0 commit comments

Comments
 (0)