style: Store values for :nth- selectors in dedicated struct NthSelectorData

To accomplish this, all :nth- Components were replaced with type Nth,
which uses NthSelectorData.

Using NthSelectorData will make it easier to add selector lists for :nth
selectors later on, but this change by itself shouldn't change any
behavior.

Differential Revision: https://phabricator.services.mozilla.com/D165831
This commit is contained in:
Zach Hoffman 2023-01-03 08:35:20 +00:00 committed by Martin Robinson
parent b373d9c1c4
commit 281ae0748f
5 changed files with 49 additions and 49 deletions

View file

@ -1921,10 +1921,7 @@ fn component_needs_revalidation(
Component::FirstChild |
Component::LastChild |
Component::OnlyChild |
Component::NthChild(..) |
Component::NthLastChild(..) |
Component::NthOfType(..) |
Component::NthLastOfType(..) |
Component::Nth(..) |
Component::FirstOfType |
Component::LastOfType |
Component::OnlyOfType => true,