1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-28 12:25:06 +00:00

LibWeb: Parse and match the :visited pseudo-class (always fails)

If we don't do this, something like "a:visited" is parsed as "a" which
may then take precedence over a previous "a:link" etc.
This commit is contained in:
Andreas Kling 2020-06-13 00:21:42 +02:00
parent 62893a54cc
commit 483b371a7b
3 changed files with 6 additions and 0 deletions

View file

@ -53,6 +53,9 @@ bool matches(const Selector::SimpleSelector& component, const Element& element)
if (!element.is_link())
return false;
break;
case Selector::SimpleSelector::PseudoClass::Visited:
// FIXME: Maybe match this selector sometimes?
return false;
case Selector::SimpleSelector::PseudoClass::Hover:
if (!matches_hover_pseudo_class(element))
return false;