Skip to content

Commit

Permalink
Use elementstate for focus and hover matching
Browse files Browse the repository at this point in the history
  • Loading branch information
nicoburns committed Aug 1, 2024
1 parent 8f935f5 commit bc34942
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/dom/src/stylo.rs
Original file line number Diff line number Diff line change
Expand Up @@ -388,9 +388,9 @@ impl<'a> selectors::Element for BlitzNode<'a> {
NonTSPseudoClass::Defined => false,
NonTSPseudoClass::Disabled => false,
NonTSPseudoClass::Enabled => false,
NonTSPseudoClass::Focus => false,
NonTSPseudoClass::Focus => self.element_state.contains(ElementState::FOCUS),
NonTSPseudoClass::Fullscreen => false,
NonTSPseudoClass::Hover => self.is_hovered,
NonTSPseudoClass::Hover => self.element_state.contains(ElementState::HOVER),
NonTSPseudoClass::Indeterminate => false,
NonTSPseudoClass::Lang(_) => false,
NonTSPseudoClass::CustomState(_) => false,
Expand Down

0 comments on commit bc34942

Please sign in to comment.