Add <ratio> support to CSSValueVariant and parseCSSValue()#42879
Closed
NickGerleman wants to merge 3 commits into
Closed
Add <ratio> support to CSSValueVariant and parseCSSValue()#42879NickGerleman wants to merge 3 commits into
NickGerleman wants to merge 3 commits into
Conversation
Contributor
|
This pull request was exported from Phabricator. Differential Revision: D53457930 |
Contributor
|
This pull request was exported from Phabricator. Differential Revision: D53457930 |
14c2c2b to
1799dbb
Compare
Contributor
|
This pull request was exported from Phabricator. Differential Revision: D53457930 |
1799dbb to
ce228dc
Compare
Contributor
|
This pull request was exported from Phabricator. Differential Revision: D53457930 |
ce228dc to
6e91f1e
Compare
Contributor
|
This pull request was exported from Phabricator. Differential Revision: D53457930 |
6e91f1e to
6a4943c
Compare
Contributor
|
This pull request was exported from Phabricator. Differential Revision: D53457930 |
6a4943c to
e596ab7
Compare
Differential Revision: D53377527, fbshipit-source-id: eb4945e9d9a6edee0b3c8b46ffb493fee0428fbb
Summary: This adds: 1. `CSSValue`: A union-y type, mapping to a collection of CSS data types. The aim here is to more closely model the data types after the CSS spec, to allow RN to store them correctly, while not taking up too much space. These types will form the foundation of Yoga prop storage (and probably some other props down the line), so compactness is a priority. 2. `parseCSSValue()`: This uses the previously added Tokenizer, along with parsing rules, to be able to parse a single component value, into a literal keyword, `<length>`, `<length-percentage>`, `<percent>`, or `<number>`. This will be wired to the props parsing infrastructure. Changelog: [Internal] Differential Revision: D53342595 fbshipit-source-id: d30e5fc36fe6c4ea9f121ab4c5788cd01fd3e4c1
…parseCSSValue() (facebook#42879) Summary: Pull Request resolved: facebook#42879 Adds support for parsing and storing a component value of the <ratio> CSS basic data type. This would allow removing from viewconfigs later, which we would need for correct substitution of functions/expressions resulting in the ratio numerator/denominator. This also fleshes out the parser a bit more, and does some renaming, and convention setting. Changelog: [Internal] Reviewed By: rozele Differential Revision: D53457930 fbshipit-source-id: d5dc240218ec5ab960f8347729e01dafb1790a9f
e596ab7 to
d2c2261
Compare
Contributor
|
This pull request was exported from Phabricator. Differential Revision: D53457930 |
Contributor
|
This pull request has been merged in a8f239d. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary:
Adds support for parsing and storing a component value of the CSS basic data type. This would allow removing
processAspectRatiofrom viewconfigs later, which we would need for correct substitution of functions/expressions resulting in the ratio numerator/denominator.Changelog: [Internal]
Differential Revision: D53457930