-
Notifications
You must be signed in to change notification settings - Fork 47k
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
Add gridArea to unitless CSS properties #13550
Merged
Merged
Conversation
This file contains 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
Details of bundled changes.Comparing: 877f8bc...c4f1d23 schedule
Generated by 🚫 dangerJS |
Do you mind filing a separate issue with your proposal? |
Merged
This was referenced Sep 7, 2018
This was referenced Nov 1, 2018
jetoneza
pushed a commit
to jetoneza/react
that referenced
this pull request
Jan 23, 2019
This was referenced Sep 5, 2024
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.
Ref #9185
Based on jquery/jquery@f997241
grid-area
accepts a numeric value which then translates togrid-row-start
, settinggrid-row-end
,grid-column-start
&grid-column-end
toauto
.I thought about adding a test but I don't understand how the ones in
CSSPropertyOperations-test.js
are supposed to work. For example, settinggrid-row
to10
will result in a normalizedgridRow
style property with a value"10 / auto"
. It seems they work just because they usems
-prefixed properties in format not actually used in IE as IE's grid properties were named differently?Another remark - in jQuery we have been auto-appending
px
to most numerical values as well but we decided it was a bad decision. It doesn't scale as it requires us to add more & more properties to the list. We've actually exposed the list at jQuery.cssNumber so that people don't always have to wait for us to add support for a property and do a release. What's more confusing, some of them would work both with & without thepx
suffix and that changes the meaning.That's why we decided that in jQuery 4 we'll drop the auto-prefixing blacklist and turn to a whitelist that lists only a few most common properties to which we want to auto-append
px
(mostly because they're extremely common and we don't want to break the world too much); we plan to not expand that list. You can see the current plan in my PR: jquery/jquery#4055. In particular, see the proposed whitelist in a (visualized) regexp in:https://github.com/jquery/jquery/blob/03e9dba3882868e1ee79f1fb0504326da925644f/src/css/isAutoPx.js.
Something to consider for a future React version.