[csswg-drafts] [css-color-5] incorrect WPT tests for omitted alpha in relative color syntax (#8708)

romainmenke has just created a new issue for https://github.com/w3c/csswg-drafts:

== [css-color-5] incorrect WPT tests for omitted alpha in relative color syntax ==
https://drafts.csswg.org/css-color-5/#origin-color

> [Relative color](https://drafts.csswg.org/css-color-5/#relative-color) syntax doesn’t change whether an argument is required or optional. If the alpha value is omitted, however, it defaults to taking from the [origin color](https://drafts.csswg.org/css-color-5/#origin-color) (rather than defaulting to 100%, as it does in the absolute syntax).

https://github.com/web-platform-tests/wpt/blob/master/css/css-color/parsing/color-computed-relative-color.html#L104

```
test_computed_value(`color`, `rgb(from rgb(20%, 40%, 60%, 80%) 0% 10 10)`, `rgb(0, 10, 10)`);
```

```css
rgb(from rgb(20%, 40%, 60%, 80%) 0% 10 10)
```

The alpha channel is omitted, so alpha should be taken from the origin color.
The result should be : `rgb(0, 10, 10, 0.8)`

Maybe this is a fairly recent change to the specification?

-----

I've updated the WPT tests to match the specification : https://github.com/web-platform-tests/wpt/pull/39508

Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/8708 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Wednesday, 12 April 2023 21:35:39 UTC