LibWeb: Ignore all pseudo element rules when matching non-pseudo element

This commit is contained in:
Andreas Kling 2024-03-19 07:34:00 +01:00
parent 4679dbc9df
commit 08a956f544
Notes: sideshowbarker 2024-07-16 22:22:13 +09:00

View file

@ -319,7 +319,7 @@ Vector<MatchingRule> StyleComputer::collect_matching_rules(DOM::Element const& e
}
} else {
for (auto const& rule : rules) {
if (filter_namespace_rule(element, rule))
if (!rule.contains_pseudo_element && filter_namespace_rule(element, rule))
rules_to_run.unchecked_append(rule);
}
}