Bug 245970
Summary: | Relative color syntax doesn't work with currentColor or system colors | ||
---|---|---|---|
Product: | WebKit | Reporter: | Matthieu Dubet <m_dubet> |
Component: | CSS | Assignee: | Diego Pino <dpino> |
Status: | RESOLVED FIXED | ||
Severity: | Normal | CC: | ahmad.saleem792, ariarzer, dev, dpino, ntim, sam, webkit-bug-importer, woodlxf00 |
Priority: | P2 | Keywords: | InRadar |
Version: | WebKit Nightly Build | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Bug Depends on: | 234691 | ||
Bug Blocks: | 277239 |
Matthieu Dubet
The CSS 5 color mutation functions (color-mix(), color-contrast(), relative color syntax) don't work with currentcolor or system-colors as one of their origin colors.
This is due to the parser not being the right time to resolve those values, so some intermediate type is going to be needed to late resolve these things (perhaps time for a CSSColor object that can be resolved into a Color when appropriate).
Depends on : https://bugs.webkit.org/show_bug.cgi?id=234691
Attachments | ||
---|---|---|
Add attachment proposed patch, testcase, etc. |
Radar WebKit Bug Importer
<rdar://problem/100981965>
Tim Nguyen (:ntim)
Bug 250459 fixes `color-mix()`.
`color-contrast()` needs a brand new implementation given the new spec (`contrast-color()`) which is very different.
Ahmad Saleem
Should I link this bug to all InterOp 2024 tests for Relative Color Syntax (except Parsing):
https://wpt.fyi/results/css/css-color?label=master&label=experimental&aligned=&view=interop&q=label%3Ainterop-2024-relative-color
I am trying to get upstart in InterOp 2024 and trying to link bugs for easier tracking.
Matthieu Dubet
Yes indeed we should link this to Interop 2024.
(I'm currently implementing this feature though - let's not duplicate work)
Sam Weinig
Matt, you still working on this? If not, I would be happy to take this on.
Sam Weinig
Pull request: https://github.com/WebKit/WebKit/pull/28445
EWS
Committed 278696@main (c05a19a495bd): <https://commits.webkit.org/278696@main>
Reviewed commits have been landed. Closing PR #28445 and removing active labels.
Roman Czerkies
Hello Sam,
is your work will include a fix for this issue 273996 ?
(https://bugs.webkit.org/show_bug.cgi?id=273996)
Diego Pino
Build bot 'GTK-Linux-64-bit-Release-Debian-11-Build' is failing after this patch with the following build error:
https://build.webkit.org/#/builders/992/builds/2243
```
../../../Source/WebCore/css/parser/CSSPropertyParserConsumer+Color.cpp:439:65: error: expected ‘(’ before ‘{’ token
439 | return consumeColorSpace(args, [&]<typename Descriptor> {
| ^
| (
../../../Source/WebCore/css/parser/CSSPropertyParserConsumer+Color.cpp:444:61: error: expected ‘(’ before ‘{’ token
```
Diego Pino
Re-opening for pull request https://github.com/webkit/webkit/pull/28541
EWS
Committed 278766@main (005715370cbf): <https://commits.webkit.org/278766@main>
Reviewed commits have been landed. Closing PR #28541 and removing active labels.