mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 06:37:44 +00: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
5 changed files with 11 additions and 0 deletions
|
@ -112,6 +112,7 @@ public:
|
|||
Active,
|
||||
Lang,
|
||||
Scope,
|
||||
Defined,
|
||||
};
|
||||
Type type;
|
||||
|
||||
|
@ -295,6 +296,8 @@ constexpr StringView pseudo_class_name(Selector::SimpleSelector::PseudoClass::Ty
|
|||
return "lang"sv;
|
||||
case Selector::SimpleSelector::PseudoClass::Type::Scope:
|
||||
return "scope"sv;
|
||||
case Selector::SimpleSelector::PseudoClass::Type::Defined:
|
||||
return "defined"sv;
|
||||
}
|
||||
VERIFY_NOT_REACHED();
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue