-
Notifications
You must be signed in to change notification settings - Fork 3.1k
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
[css-color-4] Conversion of hsl(none none none) to srgb clarification. #42677
Comments
From “Missing” Color Components and the none Keyword (my emphasis)
So yes, when the |
Perfect, will update the test. Thank! 👍 |
This fixes a test where serializing `none` values should be treated as `0` for hsl and hwb. See: #42677 Differential Revision: https://phabricator.services.mozilla.com/D191691 bugzilla-url: https://bugzilla.mozilla.org/show_bug.cgi?id=1860661 gecko-commit: 5ff1ceab2635be491fdda5ca61c10560f732ba39 gecko-reviewers: jwatt
…jwatt This fixes a test where serializing `none` values should be treated as `0` for hsl and hwb. See: web-platform-tests/wpt#42677 Differential Revision: https://phabricator.services.mozilla.com/D191691
This fixes a test where serializing `none` values should be treated as `0` for hsl and hwb. See: #42677 Differential Revision: https://phabricator.services.mozilla.com/D191691 bugzilla-url: https://bugzilla.mozilla.org/show_bug.cgi?id=1860661 gecko-commit: 5ff1ceab2635be491fdda5ca61c10560f732ba39 gecko-reviewers: jwatt
…jwatt This fixes a test where serializing `none` values should be treated as `0` for hsl and hwb. See: web-platform-tests/wpt#42677 Differential Revision: https://phabricator.services.mozilla.com/D191691
…jwatt This fixes a test where serializing `none` values should be treated as `0` for hsl and hwb. See: web-platform-tests/wpt#42677 Differential Revision: https://phabricator.services.mozilla.com/D191691 UltraBlame original commit: 5ff1ceab2635be491fdda5ca61c10560f732ba39
…jwatt This fixes a test where serializing `none` values should be treated as `0` for hsl and hwb. See: web-platform-tests/wpt#42677 Differential Revision: https://phabricator.services.mozilla.com/D191691 UltraBlame original commit: 5ff1ceab2635be491fdda5ca61c10560f732ba39
…jwatt This fixes a test where serializing `none` values should be treated as `0` for hsl and hwb. See: web-platform-tests/wpt#42677 Differential Revision: https://phabricator.services.mozilla.com/D191691 UltraBlame original commit: 5ff1ceab2635be491fdda5ca61c10560f732ba39
So, the key verbiage here from the spec is "converting it to another color space"? When the resulting hsl color is converted to srgb for serialization, the nones will get replaced with zeroes? |
Since RCS with hsl/hwb/legacy rgb involve color space conversion, would explicit "nones" become zeros here too? i.e.:
Does this look a little weird with legacy rgb? And then, does this also apply to alpha? while: |
In the tests here:
https://github.com/web-platform-tests/wpt/blob/master/css/css-color/parsing/color-computed-color-mix-function.html#L80
There is a test with
color-mix(in hsl, hsl(none none none), hsl(none none none))
which should result inhsl(none none none)
(and it does), but then of course will be converted tosrgb
for serialization. That result iscolor(srgb none none none)
, which I'm not sure how it is calculated.Chrome passes the test, but that seems to be a bug. They never clear the none flags after conversion to
srgb
, socolor-mix(in hsl, hsl(30deg 40% none), hsl(30deg 40% none))
would result incolor(srgb 0 0 none)
, just because lightness wasnone
.I think we should change the test to
color(srgb 0 0 0)
?The text was updated successfully, but these errors were encountered: