-
Notifications
You must be signed in to change notification settings - Fork 3k
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
background-blend-mode test probably needs to be extended and fixed #42496
Comments
Also opened a bug on Firefox. |
see https://drafts.fxtf.org/compositing-1/#background-blend-mode and https://drafts.csswg.org/css-backgrounds-3/#layering > The lists are matched up from the first value: excess values at the end are not used. > If a property doesn't have enough comma-separated values > to match the number of layers, the UA must calculate its used value > by repeating the list of values until there are enough.
The current test for the computed values of backgroundBlendMode were partially incorrect. The spec says: 1. To drop the excess values depending on the number of images 2. To add the initial defined values if not enough. This fixes the current test and add another test for multiple images. Fixes #42496.
"are not used" doesn't imply "are not part of the computed value". @karlcow can you revert your patch? Would've been nice to at least wait for comments from other engines before modifying the tests? There's existing discussion in the CSS working group about this and my recollection is that gecko was right. |
w3c/csswg-drafts#7164 has the latest discussion on these things. I forget the exact resolutions and today is a bank holiday for me, but I'm pretty sure dropping specified stuff from the computed value is not it. |
Ah! This sentence in
So yup. I probably need to change again this patch. I think we should still add more tests to cover the different cases. |
And the update by @fantasai It says:
|
It's been reverted: #42503. |
This was discussed in w3c/csswg-drafts#7164 (comment) > Don't specifically say the computed value is same as specified value, > it's implied. can be louder in the spec so it's obvious The specification for CSS values 4 makes it more explicit https://drafts.csswg.org/css-values-4/#linked-properties > The computed values of the coordinating list properties are > not affected by such truncation or repetition. So this patch add comments in the code to make sure this is understood and add a test to cover the case of multiple images.
This was discussed in w3c/csswg-drafts#7164 (comment) > Don't specifically say the computed value is same as specified value, > it's implied. can be louder in the spec so it's obvious The specification for CSS values 4 makes it more explicit https://drafts.csswg.org/css-values-4/#linked-properties > The computed values of the coordinating list properties are > not affected by such truncation or repetition. So this patch add comments in the code to make sure this is understood and add a test to cover the case of multiple images.
This was discussed in w3c/csswg-drafts#7164 (comment) > Don't specifically say the computed value is same as specified value, > it's implied. can be louder in the spec so it's obvious The specification for CSS values 4 makes it more explicit https://drafts.csswg.org/css-values-4/#linked-properties > The computed values of the coordinating list properties are > not affected by such truncation or repetition. So this patch add comments in the code to make sure this is understood and add a test to cover the case of multiple images.
This was discussed in w3c/csswg-drafts#7164 (comment) > Don't specifically say the computed value is same as specified value, > it's implied. can be louder in the spec so it's obvious The specification for CSS values 4 makes it more explicit https://drafts.csswg.org/css-values-4/#linked-properties > The computed values of the coordinating list properties are > not affected by such truncation or repetition. So this patch add comments in the code to make sure this is understood and add a test to cover the case of multiple images.
This was discussed in w3c/csswg-drafts#7164 (comment). > Don't specifically say the computed value is same as specified value, > it's implied. can be louder in the spec so it's obvious The specification for CSS values 4 makes it more explicit https://drafts.csswg.org/css-values-4/#linked-properties > The computed values of the coordinating list properties are > not affected by such truncation or repetition. So this patch add comments in the code to make sure this is understood and add a test to cover the case of multiple images. Fixes #42496.
wpt/css/compositing/parsing/background-blend-mode-computed.html
Lines 32 to 34 in 1e1d405
Followup of discussions in https://bugs.webkit.org/show_bug.cgi?id=261552#c10
In https://drafts.fxtf.org/compositing-1/#background-blend-mode
and
The layering seems to be defined in
https://drafts.csswg.org/css-backgrounds-3/#layering
It says:
Then (my emphasis)
Then
The example in this section
has exactly the same effect as this set with the extra position dropped and the missing values for background-origin and background-repeat filled in (emphasized for clarity):
And we can see that for background-position where there is 4 values list with an extra
bottom right
, it drops it to make it a 3 values list.So from this I would say the test as currently defined on WPT is wrong and probably the implementation of Gecko too. ( @emilio )
the background-blend-mode-computed.htm
could be fixed for multiple images for the last 3 tests
Or maybe better add a new series of tests for specific case of multiple images and their relations to properties. dropping and repeating the values.
The text was updated successfully, but these errors were encountered: