mirror of
https://github.com/LadybirdBrowser/ladybird
synced 2026-04-28 02:27:19 +02:00
The :scope pseudo-class inside :has(), :is(), :where(), and :not() selectors was not receiving the scoping root from outer selector contexts like Element.closest(). This fix passes the scope parameter through matches_has_pseudo_class(), matches_relative_selector(), and the :is()/:where()/:not() cases so that :scope correctly refers to the scoping root element. This fixes WPT tests for Element.closest() with selector ':has(> :scope)' and for comparing :has(:scope) with :is(:scope) selectors.
71 KiB
71 KiB