From 8dd16259287f58f9273002717ec4d27e97127719 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Wed, 12 Jun 2024 07:43:14 +0200 Subject: Merging upstream version 127.0. Signed-off-by: Daniel Baumann --- servo/components/style/traversal.rs | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) (limited to 'servo/components/style/traversal.rs') diff --git a/servo/components/style/traversal.rs b/servo/components/style/traversal.rs index fa256d0f60..651b5cb073 100644 --- a/servo/components/style/traversal.rs +++ b/servo/components/style/traversal.rs @@ -350,7 +350,11 @@ where rule_inclusion, PseudoElementResolution::IfApplicable, ) - .resolve_primary_style(style.as_deref(), layout_parent_style.as_deref()); + .resolve_primary_style( + style.as_deref(), + layout_parent_style.as_deref(), + selectors::matching::IncludeStartingStyle::No, + ); let is_display_contents = primary_style.style().is_display_contents(); @@ -639,7 +643,10 @@ where PseudoElementResolution::IfApplicable, ); - resolver.cascade_styles_with_default_parents(cascade_inputs) + resolver.cascade_styles_with_default_parents( + cascade_inputs, + data.may_have_starting_style(), + ) }, CascadeOnly => { // Skipping full matching, load cascade inputs from previous values. @@ -653,7 +660,10 @@ where PseudoElementResolution::IfApplicable, ); - resolver.cascade_styles_with_default_parents(cascade_inputs) + resolver.cascade_styles_with_default_parents( + cascade_inputs, + data.may_have_starting_style(), + ) }; // Insert into the cache, but only if this style isn't reused from a -- cgit v1.2.3