Skip to content

Commit

Permalink
Fix :root pseudo-selector
Browse files Browse the repository at this point in the history
  • Loading branch information
nicoburns committed Jun 24, 2024
1 parent 986e25b commit cf5a985
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion packages/dom/src/stylo.rs
Original file line number Diff line number Diff line change
Expand Up @@ -612,7 +612,9 @@ impl<'a> selectors::Element for BlitzNode<'a> {
}

fn is_root(&self) -> bool {
self.parent_node().is_none()
self.parent_node()
.and_then(|parent| parent.parent_node())
.is_none()
}

fn has_custom_state(
Expand Down

0 comments on commit cf5a985

Please sign in to comment.