diff --git a/css-color-4/Overview.bs b/css-color-4/Overview.bs index d20e1399a4b7..e172eec54060 100644 --- a/css-color-4/Overview.bs +++ b/css-color-4/Overview.bs @@ -1115,6 +1115,36 @@ any achromatic color will have a [=powerless=] hue component. still treat the hue component as [=powerless=]. It is intentionally unspecified exactly what "sufficiently close" means for this purpose. +

+Parsing a <> Value

+ +
+ To parse a CSS <> value, + given a [=string=] |input|, + and an optional context [=/element=] |element|: + + 1. [=CSS/Parse=] |input| as a <>. + If the result is failure, + return failure; + otherwise, let |color| be the result. + + 2. If |element| was passed, + let |currentcolor| be the [=used value=] of the 'color' property + on |element|, + and |color-scheme| be the [=used value=] of the 'color-scheme' property + on |element|. + + Otherwise, + let |currentcolor| and |color-scheme| + be the [=initial values=] of 'color' and 'color-scheme', respectively. + + 3. Let |used color| be the result of [[#resolving-color-values|resolving]] |color| + to a [=used color=], + using the |currentcolor| and |color-scheme| values if necessary. + + 4. Return |used color|. +
+