Title: [293602] trunk
Revision
293602
Author
obru...@igalia.com
Date
2022-04-28 18:46:53 -0700 (Thu, 28 Apr 2022)

Log Message

[css-cascade] Mark properties sharing a computed value as related
https://bugs.webkit.org/show_bug.cgi?id=239579

Reviewed by Tim Nguyen.

LayoutTests/imported/w3c:

Some failures are now passing.

* web-platform-tests/css/css-cascade/all-prop-revert-layer-expected.txt:

Source/WebCore:

Some longhand properties share a computed value with another property,
like a legacy -webkit- prefixed one.

In that case, when both properties are specified, the last one should
win. That is typically done by marking the properties as related, using
the "related-property" field. This defers the properties and makes
them cascade properly.

However, some properties weren't marked as related despite sharing a
computed value. So this patch marks these pairs:
 - mask-clip and -webkit-mask-clip
 - mask-composite and -webkit-mask-composite
 - mask-mode and -webkit-mask-source-type
 - text-combine-upright and -webkit-text-combine

Test: imported/w3c/web-platform-tests/css/css-cascade/all-prop-revert-layer.html

* css/CSSProperties.json:

LayoutTests:

Some failures are now passing.

* platform/mac-wk1/imported/w3c/web-platform-tests/css/css-cascade/all-prop-revert-layer-expected.txt:

Modified Paths

Diff

Modified: trunk/LayoutTests/ChangeLog (293601 => 293602)


--- trunk/LayoutTests/ChangeLog	2022-04-29 01:28:29 UTC (rev 293601)
+++ trunk/LayoutTests/ChangeLog	2022-04-29 01:46:53 UTC (rev 293602)
@@ -1,3 +1,14 @@
+2022-04-28  Oriol Brufau  <obru...@igalia.com>
+
+        [css-cascade] Mark properties sharing a computed value as related
+        https://bugs.webkit.org/show_bug.cgi?id=239579
+
+        Reviewed by Tim Nguyen.
+
+        Some failures are now passing.
+
+        * platform/mac-wk1/imported/w3c/web-platform-tests/css/css-cascade/all-prop-revert-layer-expected.txt:
+
 2022-04-28  Karl Rackler  <rack...@apple.com>
 
         [ macOS wk1 ] imported/w3c/web-platform-tests/css/css-text/text-transform/text-transform-upperlower-003.html is a flaky image failure

Modified: trunk/LayoutTests/imported/w3c/ChangeLog (293601 => 293602)


--- trunk/LayoutTests/imported/w3c/ChangeLog	2022-04-29 01:28:29 UTC (rev 293601)
+++ trunk/LayoutTests/imported/w3c/ChangeLog	2022-04-29 01:46:53 UTC (rev 293602)
@@ -1,3 +1,14 @@
+2022-04-28  Oriol Brufau  <obru...@igalia.com>
+
+        [css-cascade] Mark properties sharing a computed value as related
+        https://bugs.webkit.org/show_bug.cgi?id=239579
+
+        Reviewed by Tim Nguyen.
+
+        Some failures are now passing.
+
+        * web-platform-tests/css/css-cascade/all-prop-revert-layer-expected.txt:
+
 2022-04-28  Arcady Goldmints-Orlov  <agoldmi...@igalia.com>
 
         [GLIB] Update test expectations and baselines. Unreviewed test gardening.

Modified: trunk/LayoutTests/imported/w3c/web-platform-tests/css/css-cascade/all-prop-revert-layer-expected.txt (293601 => 293602)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/css/css-cascade/all-prop-revert-layer-expected.txt	2022-04-29 01:28:29 UTC (rev 293601)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/css/css-cascade/all-prop-revert-layer-expected.txt	2022-04-29 01:46:53 UTC (rev 293602)
@@ -184,10 +184,10 @@
 PASS marker-end
 PASS marker-mid
 PASS marker-start
-FAIL mask-clip assert_not_equals: Should get a different computed value. got disallowed value "border-box"
-FAIL mask-composite assert_not_equals: Should get a different computed value. got disallowed value "add"
+PASS mask-clip
+PASS mask-composite
 PASS mask-image
-FAIL mask-mode assert_not_equals: Should get a different computed value. got disallowed value "match-source"
+PASS mask-mode
 PASS mask-origin
 PASS mask-repeat
 PASS mask-size
@@ -284,7 +284,7 @@
 PASS table-layout
 PASS text-align
 PASS text-anchor
-FAIL text-combine-upright assert_not_equals: Should get a different computed value. got disallowed value "none"
+PASS text-combine-upright
 PASS text-decoration
 PASS text-decoration-color
 PASS text-decoration-line

Modified: trunk/LayoutTests/platform/mac-wk1/imported/w3c/web-platform-tests/css/css-cascade/all-prop-revert-layer-expected.txt (293601 => 293602)


--- trunk/LayoutTests/platform/mac-wk1/imported/w3c/web-platform-tests/css/css-cascade/all-prop-revert-layer-expected.txt	2022-04-29 01:28:29 UTC (rev 293601)
+++ trunk/LayoutTests/platform/mac-wk1/imported/w3c/web-platform-tests/css/css-cascade/all-prop-revert-layer-expected.txt	2022-04-29 01:46:53 UTC (rev 293602)
@@ -184,10 +184,10 @@
 PASS marker-end
 PASS marker-mid
 PASS marker-start
-FAIL mask-clip assert_not_equals: Should get a different computed value. got disallowed value "border-box"
-FAIL mask-composite assert_not_equals: Should get a different computed value. got disallowed value "add"
+PASS mask-clip
+PASS mask-composite
 PASS mask-image
-FAIL mask-mode assert_not_equals: Should get a different computed value. got disallowed value "match-source"
+PASS mask-mode
 PASS mask-origin
 PASS mask-repeat
 PASS mask-size
@@ -283,7 +283,7 @@
 PASS table-layout
 PASS text-align
 PASS text-anchor
-FAIL text-combine-upright assert_not_equals: Should get a different computed value. got disallowed value "none"
+PASS text-combine-upright
 PASS text-decoration
 PASS text-decoration-color
 PASS text-decoration-line

Modified: trunk/Source/WebCore/ChangeLog (293601 => 293602)


--- trunk/Source/WebCore/ChangeLog	2022-04-29 01:28:29 UTC (rev 293601)
+++ trunk/Source/WebCore/ChangeLog	2022-04-29 01:46:53 UTC (rev 293602)
@@ -1,3 +1,29 @@
+2022-04-28  Oriol Brufau  <obru...@igalia.com>
+
+        [css-cascade] Mark properties sharing a computed value as related
+        https://bugs.webkit.org/show_bug.cgi?id=239579
+
+        Reviewed by Tim Nguyen.
+
+        Some longhand properties share a computed value with another property,
+        like a legacy -webkit- prefixed one.
+
+        In that case, when both properties are specified, the last one should
+        win. That is typically done by marking the properties as related, using
+        the "related-property" field. This defers the properties and makes
+        them cascade properly.
+
+        However, some properties weren't marked as related despite sharing a
+        computed value. So this patch marks these pairs:
+         - mask-clip and -webkit-mask-clip
+         - mask-composite and -webkit-mask-composite
+         - mask-mode and -webkit-mask-source-type
+         - text-combine-upright and -webkit-text-combine
+
+        Test: imported/w3c/web-platform-tests/css/css-cascade/all-prop-revert-layer.html
+
+        * css/CSSProperties.json:
+
 2022-04-28  Yusuke Suzuki  <ysuz...@apple.com>
 
         Support C files in Unified Builds

Modified: trunk/Source/WebCore/css/CSSProperties.json (293601 => 293602)


--- trunk/Source/WebCore/css/CSSProperties.json	2022-04-29 01:28:29 UTC (rev 293601)
+++ trunk/Source/WebCore/css/CSSProperties.json	2022-04-29 01:46:53 UTC (rev 293602)
@@ -3331,6 +3331,7 @@
         },
         "mask-clip": {
             "codegen-properties": {
+                "related-property": "-webkit-mask-clip",
                 "name-for-methods": "Clip",
                 "fill-layer-property": true
             },
@@ -3341,6 +3342,7 @@
         },
         "mask-composite": {
             "codegen-properties": {
+                "related-property": "-webkit-mask-composite",
                 "name-for-methods": "Composite",
                 "fill-layer-property": true
             },
@@ -3364,6 +3366,7 @@
         },
         "mask-mode": {
             "codegen-properties": {
+                "related-property": "-webkit-mask-source-type",
                 "name-for-methods": "MaskMode",
                 "fill-layer-property": true
             },
@@ -6581,6 +6584,7 @@
         },
         "-webkit-mask-clip": {
             "codegen-properties": {
+                "related-property": "mask-clip",
                 "name-for-methods": "Clip",
                 "fill-layer-property": true
             },
@@ -6594,6 +6598,7 @@
         },
         "-webkit-mask-composite": {
             "codegen-properties": {
+                "related-property": "mask-composite",
                 "name-for-methods": "Composite",
                 "fill-layer-property": true
             },
@@ -6607,6 +6612,7 @@
         },
         "-webkit-mask-source-type": {
             "codegen-properties": {
+                "related-property": "mask-mode",
                 "synonym": "mask-mode",
                 "comment": "Deprecated alias for mask-mode, supports an 'auto' value, does not support 'match-source'"
             },
@@ -6796,6 +6802,7 @@
                 "horizontal"
             ],
             "codegen-properties": {
+                "related-property": "text-combine-upright",
                 "aliases": [
                     "-epub-text-combine"
                 ]
@@ -6808,6 +6815,7 @@
         "text-combine-upright": {
             "inherited": true,
             "codegen-properties": {
+                "related-property": "-webkit-text-combine",
                 "name-for-methods": "TextCombine"
             },
             "values": [
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to