react-native/Libraries/StyleSheet
Janic Duplessis 0ed31eb3d6 BREAKING - Improve JS transform validation, add tests
Summary:
This improves JS validations of the transform object and makes it a bit stricter (hence the breaking change). When moving transform objects parsing to native (#10658) the validations got out of sync a bit, this makes sure JS validations are the same or stricter than the native ones to make sure we get consistent errors across platforms.

See #12110 for an example of an error that now gets caught by JS validations.

Also added snapshot tests for the errors to make sure `processTransform` throws when passing invalid values. It only tests the validation since the object parsing is now done natively for iOS and Android.

**Test plan**
Test that there are no errors in UIExplorer
Run new unit tests
Closes https://github.com/facebook/react-native/pull/12115

Differential Revision: D4488933

Pulled By: mkonicek

fbshipit-source-id: a714e6175b2892284a44c870506165099efec1ed
2017-02-02 06:28:31 -08:00
..
__tests__ BREAKING - Improve JS transform validation, add tests 2017-02-02 06:28:31 -08:00
ColorPropType.js Remove `node_modules/react` from the list of discoverable haste modules 2016-07-05 06:44:33 -07:00
EdgeInsetsPropType.js RN: Stop Deep Linking `ReactPropTypes` 2016-10-14 18:59:10 -07:00
LayoutPropTypes.js Add percentage support to react native 2017-01-11 03:58:37 -08:00
PointPropType.js RN: Stop Deep Linking `ReactPropTypes` 2016-10-14 18:59:10 -07:00
StyleSheet.js Add StyleSheet.setStyleAttributePreprocessor 2016-11-29 15:28:32 -08:00
StyleSheetPropType.js Flowify Libraries/StyleSheet and Libraries/Text 2015-03-24 16:22:59 -08:00
StyleSheetTypes.js Unrevert D3518381 2016-07-06 12:58:41 -07:00
StyleSheetValidation.js Upgrade to React v15.3.0-rc.2 2016-07-21 09:13:29 -07:00
TransformPropTypes.js RN: Stop Deep Linking `ReactPropTypes` 2016-10-14 18:59:10 -07:00
flattenStyle.js RN: Update React (2/2) 2016-11-04 05:43:44 -07:00
normalizeColor.js Add support for number as colors 2016-02-08 04:04:38 -08:00
processColor.js Change internal format from 0xaarrggbb to 0xrrggbbaa 2016-02-07 10:14:29 -08:00
processTransform.js BREAKING - Improve JS transform validation, add tests 2017-02-02 06:28:31 -08:00
setNormalizedColorAlpha.js Replace usages of hexToRgb with setNormalizedColorAlpha 2016-02-09 14:58:34 -08:00