mirror of
https://github.com/servo/servo.git
synced 2025-08-05 21:50:18 +01:00
style: Properly increase the nesting level when matching :nth-child(of) selectors
Differential Revision: https://phabricator.services.mozilla.com/D178920
This commit is contained in:
parent
520f851d8c
commit
b329d547be
1 changed files with 8 additions and 6 deletions
|
@ -876,12 +876,14 @@ where
|
|||
Component::Nth(ref nth_data) => {
|
||||
matches_generic_nth_child(element, context.shared, nth_data, &[])
|
||||
},
|
||||
Component::NthOf(ref nth_of_data) => matches_generic_nth_child(
|
||||
element,
|
||||
context.shared,
|
||||
nth_of_data.nth_data(),
|
||||
nth_of_data.selectors(),
|
||||
),
|
||||
Component::NthOf(ref nth_of_data) => context.shared.nest(|context| {
|
||||
matches_generic_nth_child(
|
||||
element,
|
||||
context,
|
||||
nth_of_data.nth_data(),
|
||||
nth_of_data.selectors(),
|
||||
)
|
||||
}),
|
||||
Component::Is(ref list) | Component::Where(ref list) => context
|
||||
.shared
|
||||
.nest(|context| list_matches_complex_selector(list, element, context)),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue