Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: a7f14bf80bc907a6b436de4c81853fc0359acabd
      
https://github.com/WebKit/WebKit/commit/a7f14bf80bc907a6b436de4c81853fc0359acabd
  Author: Darin Adler <da...@apple.com>
  Date:   2022-12-17 (Sat, 17 Dec 2022)

  Changed paths:
    M 
LayoutTests/imported/w3c/web-platform-tests/css/cssom/cssom-getPropertyValue-common-checks-expected.txt
    M Source/WebCore/css/StyleProperties.cpp
    M Source/WebCore/css/StyleProperties.h

  Log Message:
  -----------
  Do not serialize shorthands when any longhands are missing
https://bugs.webkit.org/show_bug.cgi?id=249440
rdar://problem/103423965

Reviewed by Tim Nguyen.

* 
LayoutTests/imported/w3c/web-platform-tests/css/cssom/cssom-getPropertyValue-common-checks-expected.txt:
Expect one more test to pass.

* Source/WebCore/css/StyleProperties.cpp:
(WebCore::StyleProperties::commonShorthandChecks const): Return empty string 
when a longhand is
missing. Also redid the logic for values that are set by the shorthand, since 
it no longer needs
to compute a count.
(WebCore::StyleProperties::getPropertyValue const): Removed unneeded checks 
since
commonShorthandChecks handles missing longhands, and parsing makes sure things 
have correct types.
(WebCore::StyleProperties::offsetValue const): Ditto.
(WebCore::StyleProperties::fontVariantValue const): Ditto.
(WebCore::StyleProperties::get2Values const): Ditto.
(WebCore::StyleProperties::get4Values const): Ditto.
(WebCore::StyleProperties::getLayeredShorthandValue const): Ditto.
(WebCore::StyleProperties::getGridTemplateValue const): Ditto.
(WebCore::StyleProperties::getGridValue const): Ditto.
(WebCore::StyleProperties::getGridRowColumnShorthandValue const): Ditto.
(WebCore::StyleProperties::getGridAreaShorthandValue const): Ditto.
(WebCore::StyleProperties::getShorthandValue const): Ditto.
(WebCore::StyleProperties::getCommonValue const): Ditto.
(WebCore::StyleProperties::borderImagePropertyValue const): Ditto.
(WebCore::StyleProperties::borderRadiusShorthandValue const): Ditto.
(WebCore::StyleProperties::borderPropertyValue const): Ditto.

* Source/WebCore/css/StyleProperties.h: Removed the unneeded argument from 
fontVariantValue.

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


_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to