diff --git a/source b/source index 761b0280ac9..f27cfb126c9 100644 --- a/source +++ b/source @@ -3697,8 +3697,10 @@ a.setAttribute('href', 'https://example.com/'); // change the content attribute
  • transparent black
  • 'srgb' color space
  • 'display-p3' color space
  • -
  • 'relative-colorimetric' rendering intent
  • +
  • 'relative-colorimetric' rendering intent
  • parse a CSS <color> value
  • +
  • serialize a CSS <color> value including HTML-compatible serialization is requested
  • +
  • Converting Colors
  • The following terms are defined in CSS Images: CSSIMAGES

    @@ -65172,9 +65174,8 @@ context.fillRect(100,0,50,50); // only this square remains data-x="dom-PredefinedColorSpace-display-p3">display-p3" value indicates the 'display-p3' color space.

    -

    Algorithms for converting between color spaces are found in the Predefined color spaces section of - CSS Color. CSSCOLOR

    +

    The algorithm for converting between color spaces can be found in the + Converting Colors section of CSS Color. CSSCOLOR


    @@ -67870,8 +67871,9 @@ try {
    1. If this's fill - style is a CSS color, then return the serialization of that color.

    2. + style is a CSS color, then return the serialization of that color with HTML-compatible serialization requested.

    3. Return this's fill style.

    4. @@ -67914,8 +67916,9 @@ try {
      1. If this's stroke - style is a CSS color, then return the serialization of that color.

      2. + style is a CSS color, then return the serialization of that color with HTML-compatible serialization requested.

      3. Return this's stroke style.

      4. @@ -67954,26 +67957,6 @@ try { style to the given value.

      -

      The serialization of a color for a color - value is a string, computed as follows: if it has alpha equal to 1.0, then the string is a - lowercase six-digit hex value, prefixed with a "#" character (U+0023 NUMBER SIGN), with the first - two digits representing the red component, the next two digits representing the green component, - and the last two digits representing the blue component, the digits being ASCII lower hex digits. Otherwise, the color value has alpha less than - 1.0, and the string is the color value in the CSS rgba() - functional-notation format: "rgba" (U+0072 U+0067 U+0062 - U+0061) followed by a U+0028 LEFT PARENTHESIS, a base-ten integer in the range 0-255 representing - the red component (using ASCII digits in the shortest form possible), a literal - U+002C COMMA and U+0020 SPACE, an integer for the green component, a comma and a space, an integer - for the blue component, another comma and space, a U+0030 DIGIT ZERO, if the alpha value is - greater than zero then a U+002E FULL STOP (representing the decimal point), if the alpha value is - greater than zero then one or more ASCII digits representing the fractional part of - the alpha, and finally a U+0029 - RIGHT PARENTHESIS. User agents must express the fractional part of the alpha value, if any, with - the level of precision necessary for the alpha value, when reparsed, to be interpreted as the same - alpha value.

      - -
      @@ -69827,8 +69810,10 @@ console.log(pixels.data[2]);

      The shadowColor getter steps are to return the serialization of this's shadow color.

      + data-x="serialize a CSS <color> value">serialization of this's shadow color with HTML-compatible serialization + requested.

      The shadowColor setter steps are:

      @@ -71064,17 +71049,18 @@ interface OffscreenCanvasRenderingContext2D { backing store. The default backing store color space for all canvas APIs is 'srgb'.

      -

      Color space conversion must be applied to the canvas's backing store when rendering the canvas - to the output device. This color space conversion must be identical to the color space conversion - that would be applied to an img element with a color profile that specifies the same - color space as the canvas's backing store.

      +

      Color space conversion must be applied to the canvas's + backing store when rendering the canvas to the output device. This color space conversion must be + identical to the color space conversion that would be applied to an img element with + a color profile that specifies the same color + space as the canvas's backing store.

      -

      When drawing content to a 2D context, all inputs must be converted to the context's color space before drawing. Interpolation of - gradient color stops must be performed on color values after conversion to the context's color space. Alpha blending must be performed - on values after conversion to the context's color - space.

      +

      When drawing content to a 2D context, all inputs must be converted to the context's color + space before drawing. Interpolation of gradient color stops must be performed on color + values after conversion to the context's color + space. Alpha blending must be performed on values after conversion to the context's color space.

      There do not exist any inputs to a 2D context for which the color space is undefined. The color space for CSS colors is defined in CSS Color. The color space @@ -71123,8 +71109,8 @@ interface OffscreenCanvasRenderingContext2D {

      For image types that support color profiles, the serialized image must include a color profile indicating the color space of the underlying bitmap. For image types that do not support color - profiles, the serialized image must be converted to the 'srgb' color space using - 'relative-colorimetric' rendering intent.

      + profiles, the serialized image must be converted to the + 'srgb' color space using 'relative-colorimetric' rendering intent.

      Thus, in the 2D context, calling the drawImage() method to render the output of the