Re: [csswg-drafts] [css-color-5] color-contrast needs another comma (#5087)

So... in the gradient functions, the initial arguments are definitely not the same syntax as the items in the list that follows, so it's clear that they're the initial args. But here, it just looks like a list of colors. It's not clear from the syntax that the first argument is the one that's special, and the rest are a list of peers.

Note: comma (rather than space) should be used for separating alternates, so using comma in the selection list is correct.

I'm not sure what a good syntax would be, but it would be nice if the specialness of that first color was more obvious.

Maybe using a slash? It has more visual impact than the space (and also spaces are usually subordinate to commas, whereas the order of precedence wrt slashes is less obvious)...
```
color-contrast(wheat / tan, sienna, var(--myAccent), #d2691e)
```


-- 
GitHub Notification of comment by fantasai
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/5087#issuecomment-631029452 using your GitHub account

Received on Tuesday, 19 May 2020 19:19:20 UTC