Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: b3d9486932cd5a30f2ee8c2d3fd6aa79efb65f36
https://github.com/WebKit/WebKit/commit/b3d9486932cd5a30f2ee8c2d3fd6aa79efb65f36
Author: Sam Weinig <[email protected]>
Date: 2026-06-06 (Sat, 06 Jun 2026)
Changed paths:
M
LayoutTests/imported/w3c/web-platform-tests/css/css-color/parsing/color-computed-color-mix-function-expected.txt
M
LayoutTests/imported/w3c/web-platform-tests/css/css-color/parsing/color-computed-color-mix-function.html
M Source/WebCore/css/values/color/CSSColorMixResolver.cpp
Log Message:
-----------
[Color] Update color-mix resolution for new 0% rules
https://bugs.webkit.org/show_bug.cgi?id=316483
Reviewed by Darin Adler.
Update color-mix() resolver for changes in the spec stemming from
the following issues:
https://github.com/w3c/csswg-drafts/issues/14013 - [css-color-5] color-mix()
algorithm requires division by zero
https://github.com/w3c/csswg-drafts/issues/14014 - [css-color-5] Remove special
casing of 100% leftover from the color-mix() calculation algorithm
Now, color-mix() with all 0% items mixes colors no longer always
returns transparent black, instead returning an equal mixture of
all the items with alpha set to 0%. If painted directly, the result
is the same, but if used as part of a larger expression, or serializing,
maintaining the components can be observed.
Additionally, mixing consecutive 0% items now no longer requires
division by zero, instead a 50% mixture is used.
*
LayoutTests/imported/w3c/web-platform-tests/css/css-color/parsing/color-computed-color-mix-function-expected.txt:
*
LayoutTests/imported/w3c/web-platform-tests/css/css-color/parsing/color-computed-color-mix-function.html:
* Source/WebCore/css/values/color/CSSColorMixResolver.cpp:
Canonical link: https://commits.webkit.org/314714@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications