-
Notifications
You must be signed in to change notification settings - Fork 24k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
String setters for CSSDeclaredStyle #44435
Conversation
This pull request was exported from Phabricator. Differential Revision: D57039255 |
Summary: Every CSS prop at this sparse stage is represented as an enum, and each enum can be specialized to different types, according to the global CSS property table. With this change, we add a string name to each property table entry that we use to generate a function to be able to set CSS value strings, against property name strings. Like `declaredStyle.set("aspectRatio", "4 / 3")`. I was considering specializing this a bit, to allow DeclaredStyles which only support a subset of CSS props. E.g. so `ParagraphShadowNode` has a more derived declared style than `LayoutableShadowNode` does. But, I am not sure the best way yet to make that compose nicely. Changelog: [internal] Differential Revision: D57039255
20bd22b
to
f8f3df7
Compare
This pull request was exported from Phabricator. Differential Revision: D57039255 |
Base commit: deee037 |
Summary: Every CSS prop at this sparse stage is represented as an enum, and each enum can be specialized to different types, according to the global CSS property table. With this change, we add a string name to each property table entry that we use to generate a function to be able to set CSS value strings, against property name strings. Like `declaredStyle.set("aspectRatio", "4 / 3")`. I was considering specializing this a bit, to allow DeclaredStyles which only support a subset of CSS props. E.g. so `ParagraphShadowNode` has a more derived declared style than `LayoutableShadowNode` does. But, I am not sure the best way yet to make that compose nicely. Changelog: [internal] Differential Revision: D57039255
f8f3df7
to
429448d
Compare
This pull request was exported from Phabricator. Differential Revision: D57039255 |
Summary: Every CSS prop at this sparse stage is represented as an enum, and each enum can be specialized to different types, according to the global CSS property table. With this change, we add a string name to each property table entry that we use to generate a function to be able to set CSS value strings, against property name strings. Like `declaredStyle.set("aspectRatio", "4 / 3")`. I was considering specializing this a bit, to allow DeclaredStyles which only support a subset of CSS props. E.g. so `ParagraphShadowNode` has a more derived declared style than `LayoutableShadowNode` does. But, I am not sure the best way yet to make that compose nicely. Changelog: [internal] Differential Revision: D57039255
Summary: Every CSS prop at this sparse stage is represented as an enum, and each enum can be specialized to different types, according to the global CSS property table. With this change, we add a string name to each property table entry that we use to generate a function to be able to set CSS value strings, against property name strings. Like `declaredStyle.set("aspectRatio", "4 / 3")`. I was considering specializing this a bit, to allow DeclaredStyles which only support a subset of CSS props. E.g. so `ParagraphShadowNode` has a more derived declared style than `LayoutableShadowNode` does. But, I am not sure the best way yet to make that compose nicely. Changelog: [internal] Reviewed By: rshest Differential Revision: D57039255
Summary: Every CSS prop at this sparse stage is represented as an enum, and each enum can be specialized to different types, according to the global CSS property table. With this change, we add a string name to each property table entry that we use to generate a function to be able to set CSS value strings, against property name strings. Like `declaredStyle.set("aspectRatio", "4 / 3")`. I was considering specializing this a bit, to allow DeclaredStyles which only support a subset of CSS props. E.g. so `ParagraphShadowNode` has a more derived declared style than `LayoutableShadowNode` does. But, I am not sure the best way yet to make that compose nicely. Changelog: [internal] Reviewed By: rshest Differential Revision: D57039255
Summary: Every CSS prop at this sparse stage is represented as an enum, and each enum can be specialized to different types, according to the global CSS property table. With this change, we add a string name to each property table entry that we use to generate a function to be able to set CSS value strings, against property name strings. Like `declaredStyle.set("aspectRatio", "4 / 3")`. I was considering specializing this a bit, to allow DeclaredStyles which only support a subset of CSS props. E.g. so `ParagraphShadowNode` has a more derived declared style than `LayoutableShadowNode` does. But, I am not sure the best way yet to make that compose nicely. Changelog: [internal] Reviewed By: rshest Differential Revision: D57039255
This pull request has been merged in c300310. |
This pull request was successfully merged by @NickGerleman in c300310. When will my fix make it into a release? | How to file a pick request? |
Summary:
Every CSS prop at this sparse stage is represented as an enum, and each enum can be specialized to different types, according to the global CSS property table.
With this change, we add a string name to each property table entry that we use to generate a function to be able to set CSS value strings, against property name strings. Like
declaredStyle.set("aspectRatio", "4 / 3")
.I was considering specializing this a bit, to allow DeclaredStyles which only support a subset of CSS props. E.g. so
ParagraphShadowNode
has a more derived declared style thanLayoutableShadowNode
does. But, I am not sure the best way yet to make that compose nicely.Changelog: [internal]
Differential Revision: D57039255