[csswg-drafts] [css-fonts] should supported tech() be validated during parsing or loading? (#8793)

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

== [css-fonts] should supported tech() be validated during parsing or loading? ==
The way I interpreted `@font-face src tech()` from WPT tests, we should parse all valid keywords for `tech()` and then, at loading, check if the parsed tech is supported or not. That’s what WPT expects, for example, [here](https://github.com/web-platform-tests/wpt/blob/5e9760d203/css/css-fonts/parsing/font-face-src-format.html), otherwise a browser not supporting `color-colrv1`, for example, would fail some subtests.

However, [spec](https://www.w3.org/TR/css-fonts-4/#font-face-src-parsing) says:

> If a component value is parsed correctly and is of a font format or font tech that the UA supports, add it to the list of supported sources. If parsing a component value results in a parsing error or its format or tech are unsupported, do not add it to the list of supported sources.
> If there are no supported entries at the end of this process, the value for the src descriptor is a parse error.

For _unsupported_ tech to be a parsing error, we would need to validate for supported tech already during parsing, but then a browser not supporting, for example, color-colrv1 would fail the mentioned WPT subtest.

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


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

Received on Thursday, 4 May 2023 15:11:25 UTC