Support gradient interpolation methods for CSS Gradients
Created attachment 448016 [details] Patch
No rendering tests yet, as those are proving tricky. Only parsing and serialization tests so far.
This patch modifies the imported WPT tests. Please ensure that any changes on the tests (not coming from a WPT import) are exported to WPT. Please see https://trac.webkit.org/wiki/WPTExportProcess
Created attachment 448050 [details] Screenshot of gradient variations
Created attachment 448051 [details] Gradient Playground
Attached playground to test out gradients with all the different interpolation methods at once. (It requires the patch and setting enabled to work). Also added a screenshot of it working in MiniBrowser.
Comment on attachment 448016 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=448016&action=review > LayoutTests/imported/w3c/web-platform-tests/css/css-images/parsing/gradient-interpolation-method-valid-expected.txt:2 > +FAIL e.style['background-image'] = "linear-gradient(in srgb, red, blue)" should set the property value assert_equals: serialization should be canonical expected "linear-gradient(in srgb, red, blue)" but got "linear-gradient(red, blue)" Why are these all fails?
(In reply to Simon Fraser (smfr) from comment #7) > Comment on attachment 448016 [details] > Patch > > View in context: > https://bugs.webkit.org/attachment.cgi?id=448016&action=review > > > LayoutTests/imported/w3c/web-platform-tests/css/css-images/parsing/gradient-interpolation-method-valid-expected.txt:2 > > +FAIL e.style['background-image'] = "linear-gradient(in srgb, red, blue)" should set the property value assert_equals: serialization should be canonical expected "linear-gradient(in srgb, red, blue)" but got "linear-gradient(red, blue)" > > Why are these all fails? Oh, cause I tried to simplify the test at the last moment and didn't double check things. I have the fix for this. Thanks for the review.
Created attachment 448054 [details] Patch
Committed r287474 (245609@main): <https://commits.webkit.org/245609@main> All reviewed patches have been landed. Closing bug and clearing flags on attachment 448054 [details].
<rdar://problem/86963408>