mirror of
https://github.com/status-im/react-native.git
synced 2025-02-05 06:04:15 +00:00
Arthur Lee
2d42c9eb4a
[ReactNative] Added support for 3 digit hex colors | Arthur Lee
Summary: This addition adds a check for whether a hex color is 3 or 6 digits. If it is 3 digits, it will expand the short form into 6 digits, just like in CSS. The additional benefit of having the length check is that hex colors of invalid lengths (like 4 digits) will be considered invalid. In CSS, invalid length hex colors returns white, but here I have logged an error through `RCTLogError`. Closes https://github.com/facebook/react-native/pull/455 Github Author: Arthur Lee <arthur@arthurlee.me> Test Plan: Tried a couple of colors in the sample app, like `#FACEB0`, `#F00`, etc.
Description
A framework for building native apps with React.
http://facebook.github.io/react-native/
Languages
JavaScript
47.5%
Java
26.5%
Objective-C
13.7%
C++
7.2%
C
1.5%
Other
3.5%