Summary: Decouple processStyle from the main reconciliation. It is now a process
extension to the style attribute `transform`. This effectively decouples a
large portion of special cases and helper dependencies from the reconciler.
The transform attribute becomes translated into the transformMatrix attribute on
the native side so this becomes a little weird in that I have to special case
it. I don't think it is worth while having a general solution for this so I
intend to rename the native attribute to `transform` and just have it accept the
resolved transform. Then I can remove the special cases.
The next step is generalizing the flattenStyle function and optimizing it.
@public
Reviewed By: @vjeux
Differential Revision: D2460465
fb-gh-sync-id: 243e7fd77d282b401bc2c028aec8d57f24522a8e
Summary: The StyleSheet merging algorithm was modeled after `Object.assign` and the native spread operator. This diff converts `flattenStyle` to actually use `Object.assign`.
Closes https://github.com/facebook/react-native/pull/3048
Reviewed By: @svcscm
Differential Revision: D2506387
Pulled By: @vjeux
Summary: I can't find anywhere these are being used by the bridge / native
views anymore. I don't think they work anymore. ART has a similar
API but uses a different code path.
We might as well clean this up. Makes it easier to reason about.
@public
Reviewed By: @vjeux
Differential Revision: D2445353
Summary:
For some reason we're now spamming the logs everytime we render an Image because overflow is not defined in the whitelist. overflow: 'hidden' is needed for network images with cover mode.
The way we currently define those is not optimal where we try to factor as many things as possible into distinct propTypes. However for Text we're not even using this but we are getting all the ones from View (which many do not apply) and remove some that aren't needed.
It may be useful to cleanup this in the future but in the short term, it's better to remove this warning that doesn't have much value anyway.
Summary:
Sorting the StyleProps alphabetically makes it easier to scan through the list of available props e.g. in case of typos.
Filled out the FB CLA form just now.
Related to #1605
Closes https://github.com/facebook/react-native/pull/1607
Github Author: Jan Monschke <jan.monschke@gmail.com>
Test Plan: Imported from GitHub, without a `Test Plan:` line.