Title: [287926] trunk
Revision
287926
Author
grao...@webkit.org
Date
2022-01-12 08:54:57 -0800 (Wed, 12 Jan 2022)

Log Message

css/css-transitions/pseudo-elements-002.html WPT is a failure
https://bugs.webkit.org/show_bug.cgi?id=234987

Reviewed by Antti Koivisto.

LayoutTests/imported/w3c:

Mark WPT progression.

* web-platform-tests/css/css-transitions/pseudo-elements-002-expected.txt:
* web-platform-tests/css/cssom/getComputedStyle-pseudo-expected.txt:

Source/WebCore:

When checking for style validity, we would only check the element itself and not its host
in the case where the element were a PseudoElement. Ideally, we'd eradicate all use of
PseudoElement throughout this source file, but this is a start, and I'll attempt a
refactor in a followup patch.

* css/CSSComputedStyleDeclaration.cpp:
(WebCore::hasValidStyleForProperty):

Modified Paths

Diff

Modified: trunk/LayoutTests/imported/w3c/ChangeLog (287925 => 287926)


--- trunk/LayoutTests/imported/w3c/ChangeLog	2022-01-12 16:51:10 UTC (rev 287925)
+++ trunk/LayoutTests/imported/w3c/ChangeLog	2022-01-12 16:54:57 UTC (rev 287926)
@@ -1,5 +1,17 @@
 2022-01-12  Antoine Quint  <grao...@webkit.org>
 
+        css/css-transitions/pseudo-elements-002.html WPT is a failure
+        https://bugs.webkit.org/show_bug.cgi?id=234987
+
+        Reviewed by Antti Koivisto.
+
+        Mark WPT progression.
+
+        * web-platform-tests/css/css-transitions/pseudo-elements-002-expected.txt:
+        * web-platform-tests/css/cssom/getComputedStyle-pseudo-expected.txt:
+
+2022-01-12  Antoine Quint  <grao...@webkit.org>
+
         Remove WebKitTransitionEvent and WebKitAnimationEvent
         https://bugs.webkit.org/show_bug.cgi?id=235113
 

Modified: trunk/LayoutTests/imported/w3c/web-platform-tests/css/css-transitions/pseudo-elements-002-expected.txt (287925 => 287926)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/css/css-transitions/pseudo-elements-002-expected.txt	2022-01-12 16:51:10 UTC (rev 287925)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/css/css-transitions/pseudo-elements-002-expected.txt	2022-01-12 16:54:57 UTC (rev 287926)
@@ -1,3 +1,3 @@
 
-FAIL Check that transitions run on a pseudo element whose ancestor changes display type. assert_equals: expected "200px" but got "100px"
+PASS Check that transitions run on a pseudo element whose ancestor changes display type.
 

Modified: trunk/LayoutTests/imported/w3c/web-platform-tests/css/cssom/getComputedStyle-pseudo-expected.txt (287925 => 287926)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/css/cssom/getComputedStyle-pseudo-expected.txt	2022-01-12 16:51:10 UTC (rev 287925)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/css/cssom/getComputedStyle-pseudo-expected.txt	2022-01-12 16:54:57 UTC (rev 287926)
@@ -6,6 +6,6 @@
 PASS Item-based blockification of pseudo-elements
 FAIL Item-based blockification of nonexistent pseudo-elements assert_equals: Pseudo-styles of display: flex elements should get blockified expected "block" but got "inline"
 PASS display: contents on pseudo-elements
-FAIL Dynamically change to display: contents on pseudo-elements assert_equals: display: contents in :before should get reflected on CSSOM expected "contents" but got "block"
+PASS Dynamically change to display: contents on pseudo-elements
 FAIL Unknown pseudo-elements throw assert_throws_js: getComputedStyle with an unknown pseudo-element throws function "() => getComputedStyle(div, "totallynotapseudo")" did not throw
 

Modified: trunk/Source/WebCore/ChangeLog (287925 => 287926)


--- trunk/Source/WebCore/ChangeLog	2022-01-12 16:51:10 UTC (rev 287925)
+++ trunk/Source/WebCore/ChangeLog	2022-01-12 16:54:57 UTC (rev 287926)
@@ -1,5 +1,20 @@
 2022-01-12  Antoine Quint  <grao...@webkit.org>
 
+        css/css-transitions/pseudo-elements-002.html WPT is a failure
+        https://bugs.webkit.org/show_bug.cgi?id=234987
+
+        Reviewed by Antti Koivisto.
+
+        When checking for style validity, we would only check the element itself and not its host
+        in the case where the element were a PseudoElement. Ideally, we'd eradicate all use of
+        PseudoElement throughout this source file, but this is a start, and I'll attempt a
+        refactor in a followup patch.
+
+        * css/CSSComputedStyleDeclaration.cpp:
+        (WebCore::hasValidStyleForProperty):
+
+2022-01-12  Antoine Quint  <grao...@webkit.org>
+
         Remove WebKitTransitionEvent and WebKitAnimationEvent
         https://bugs.webkit.org/show_bug.cgi?id=235113
 

Modified: trunk/Source/WebCore/css/CSSComputedStyleDeclaration.cpp (287925 => 287926)


--- trunk/Source/WebCore/css/CSSComputedStyleDeclaration.cpp	2022-01-12 16:51:10 UTC (rev 287925)
+++ trunk/Source/WebCore/css/CSSComputedStyleDeclaration.cpp	2022-01-12 16:54:57 UTC (rev 287926)
@@ -2450,6 +2450,12 @@
 {
     if (element.styleValidity() != Style::Validity::Valid)
         return false;
+    if (element.isPseudoElement()) {
+        if (auto* host = downcast<PseudoElement>(element).hostElement()) {
+            if (host->styleValidity() != Style::Validity::Valid)
+                return false;
+        }
+    }
     if (element.document().hasPendingFullStyleRebuild())
         return false;
     if (!element.document().childNeedsStyleRecalc())
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to