-
Notifications
You must be signed in to change notification settings - Fork 642
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[color-4] Clarification of missing color components and parsing #8362
Comments
Pretty sure the fact that these parse in WebKit / Blink is a bug. It's super-odd and not particularly useful either. Also, the syntax is rather clear :) In fact I filed this as https://bugs.webkit.org/show_bug.cgi?id=251152 / https://bugs.chromium.org/p/chromium/issues/detail?id=1410200. But it's probably worth clarifying, @svgeesus / @LeaVerou? |
Like @emilio I thought the spec was clear but taking another look just now, I see:
This is left over from when we used to auto fill-in omitted values and trim excess values. Which we decided not to do anymore, once The grammar itself is clear: So I need to clean up that old text to make it once more agree with the grammar. |
Spec now says
to agree with the grammar. |
Also, I now see from this issue that the phrase 'missing color component' can be mis-interpreted to mean an author-omitted value, not a powerless component. |
@emilio wrote:
This is leftover (previously correct) behavior from when |
According to the specification, missing components in the color function should result in an invalid color. This patch removes those tests from valid checks and adds them to the invalid checks. https://w3c.github.io/csswg-drafts/css-color-4/#missing Clarification from the csswg github repo: w3c/csswg-drafts#8362 Differential Revision: https://phabricator.services.mozilla.com/D167946 bugzilla-url: https://bugzilla.mozilla.org/show_bug.cgi?id=1812548 gecko-commit: 279c04f1ec0406ef91adbc3ef59a7eb0127e5be4 gecko-reviewers: emilio
According to the specification, missing components in the color function should result in an invalid color. This patch removes those tests from valid checks and adds them to the invalid checks. https://w3c.github.io/csswg-drafts/css-color-4/#missing Clarification from the csswg github repo: w3c/csswg-drafts#8362 Differential Revision: https://phabricator.services.mozilla.com/D167946
According to the specification, missing components in the color function should result in an invalid color. This patch removes those tests from valid checks and adds them to the invalid checks. https://w3c.github.io/csswg-drafts/css-color-4/#missing Clarification from the csswg github repo: w3c/csswg-drafts#8362 Differential Revision: https://phabricator.services.mozilla.com/D167946 bugzilla-url: https://bugzilla.mozilla.org/show_bug.cgi?id=1812548 gecko-commit: 279c04f1ec0406ef91adbc3ef59a7eb0127e5be4 gecko-reviewers: emilio
According to the specification, missing components in the color function should result in an invalid color. This patch removes those tests from valid checks and adds them to the invalid checks. https://w3c.github.io/csswg-drafts/css-color-4/#missing Clarification from the csswg github repo: w3c/csswg-drafts#8362 Differential Revision: https://phabricator.services.mozilla.com/D167946
According to the specification, missing components in the color function should result in an invalid color. This patch removes those tests from valid checks and adds them to the invalid checks. https://w3c.github.io/csswg-drafts/css-color-4/#missing Clarification from the csswg github repo: w3c/csswg-drafts#8362 Differential Revision: https://phabricator.services.mozilla.com/D167946 bugzilla-url: https://bugzilla.mozilla.org/show_bug.cgi?id=1812548 gecko-commit: 279c04f1ec0406ef91adbc3ef59a7eb0127e5be4 gecko-reviewers: emilio
According to the specification, missing components in the color function should result in an invalid color. This patch removes those tests from valid checks and adds them to the invalid checks. https://w3c.github.io/csswg-drafts/css-color-4/#missing Clarification from the csswg github repo: w3c/csswg-drafts#8362 Differential Revision: https://phabricator.services.mozilla.com/D167946
In reference to this section in the [color-4] specification:
csswg-drafts/css-color-4/Overview.bs
Line 983 in 69398af
According to what is mentioned here, I am uncertain whether missing color components should parse to a valid or invalid color. Currently the following are all valid colors:
There is also a definition of the color syntax here (https://w3c.github.io/csswg-drafts/css-color-4/#color-function):
which does not allow any missing components, but does indeed accept the 'none' keyword.
Does this rule make the previously mentioned valid color invalid if they do not have the 'none' keyword in place of the missing components?
The text was updated successfully, but these errors were encountered: