mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-06-10 01:51:03 +09:00
LibWeb: Implement the :defined
pseudo class
This selects an element if it is either a built-in element, or an upgraded custom element.
This commit is contained in:
parent
6ebdb9f824
commit
a744ae79ff
Notes:
sideshowbarker
2024-07-18 08:59:31 +09:00
Author: https://github.com/Lubrsi
Commit: a744ae79ff
Pull-request: https://github.com/SerenityOS/serenity/pull/18092
5 changed files with 11 additions and 0 deletions
|
@ -268,6 +268,8 @@ static inline bool matches_pseudo_class(CSS::Selector::SimpleSelector::PseudoCla
|
|||
return matches_checked_pseudo_class(element);
|
||||
case CSS::Selector::SimpleSelector::PseudoClass::Type::Indeterminate:
|
||||
return matches_indeterminate_pseudo_class(element);
|
||||
case CSS::Selector::SimpleSelector::PseudoClass::Type::Defined:
|
||||
return element.is_defined();
|
||||
case CSS::Selector::SimpleSelector::PseudoClass::Type::Is:
|
||||
case CSS::Selector::SimpleSelector::PseudoClass::Type::Where:
|
||||
for (auto& selector : pseudo_class.argument_selector_list) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue