Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: ec9f0db07e3e874124a4f065eea8472c8ddf2c22
      
https://github.com/WebKit/WebKit/commit/ec9f0db07e3e874124a4f065eea8472c8ddf2c22
  Author: Tim Nguyen <[email protected]>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M 
LayoutTests/imported/w3c/web-platform-tests/css/css-color/parsing/color-valid-color-function-expected.txt
    M 
LayoutTests/imported/w3c/web-platform-tests/css/css-color/parsing/color-valid-lab-expected.txt
    M Source/WebCore/platform/graphics/ColorSerialization.cpp

  Log Message:
  -----------
  [css-color] Fix serialization of infinity & -infinity in colors
https://bugs.webkit.org/show_bug.cgi?id=261018
rdar://114808320

Reviewed by Timothy Hatcher.

We serialize to values like `lch(50 Infinity 0)` which are invalid at 
parse-time.

Serialize infinity to `calc(infinity)` instead, which is valid in CSS.

* 
LayoutTests/imported/w3c/web-platform-tests/css/css-color/parsing/color-valid-color-function-expected.txt:
* 
LayoutTests/imported/w3c/web-platform-tests/css/css-color/parsing/color-valid-lab-expected.txt:
* Source/WebCore/platform/graphics/ColorSerialization.cpp:
(WebCore::numericComponent):
(WTF::StringTypeAdapter<WebCore::NumericComponent>::StringTypeAdapter): Deleted.
(WTF::StringTypeAdapter<WebCore::NumericComponent>::length const): Deleted.
(WTF::StringTypeAdapter<WebCore::NumericComponent>::is8Bit const): Deleted.
(WTF::StringTypeAdapter<WebCore::NumericComponent>::writeTo const): Deleted.
(WTF::StringTypeAdapter<WebCore::NumericComponent>::buffer const): Deleted.

Canonical link: https://commits.webkit.org/267544@main


_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to