Skip to content

Commit b86026d

Browse files
committed
[selectors-4] Limit :nth-child() etc. to compound selectors. w3c#3760
1 parent fecadfd commit b86026d

File tree

1 file changed

+10
-2
lines changed

1 file changed

+10
-2
lines changed

selectors-4/Overview.bs

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2834,7 +2834,7 @@ Child-indexed Pseudo-classes</h3>
28342834
are among <var>An+B</var>th elements
28352835
from the list composed of
28362836
their <a>inclusive siblings</a> that match the <a>selector list</a> <var>S</var>,
2837-
which is [=parsed as a forgiving selector list=].
2837+
which is a <<compound-selector-list>> [=parsed as a forgiving selector list=].
28382838
If <var>S</var> is omitted,
28392839
it defaults to ''*|*''.
28402840

@@ -2922,6 +2922,9 @@ Child-indexed Pseudo-classes</h3>
29222922
</pre>
29232923
</div>
29242924

2925+
Note: We intend to extend '':nth-child()'' to accept <<complex-selector-list>>
2926+
in Level 5.
2927+
29252928
<h4 id="the-nth-last-child-pseudo">
29262929
'':nth-last-child()'' pseudo-class</h4>
29272930

@@ -2931,7 +2934,7 @@ Child-indexed Pseudo-classes</h3>
29312934
from the list composed of
29322935
their <a>inclusive siblings</a> that match the <a>selector list</a> <var>S</var>,
29332936
counting backwards from the end.
2934-
<var>S</var> is [=parsed as a forgiving selector list=].
2937+
<var>S</var> is <<compound-selector-list>> [=parsed as a forgiving selector list=].
29352938
If <var>S</var> is omitted,
29362939
it defaults to ''*|*''.
29372940

@@ -2954,6 +2957,9 @@ Child-indexed Pseudo-classes</h3>
29542957
</pre>
29552958
</div>
29562959

2960+
Note: We intend to extend '':nth-last-child()'' to accept <<complex-selector-list>>
2961+
in Level 5.
2962+
29572963
<h4 id="the-first-child-pseudo">
29582964
'':first-child'' pseudo-class</h4>
29592965

@@ -4038,6 +4044,8 @@ Changes since the 21 November 2018 Working Draft</h3>
40384044
<li>Defined '':is()'', '':where()'', '':has()'', '':nth-child()'', and '':nth-last-child()''
40394045
to not be themselves invalidated when containing an invalid selector.
40404046
(<a href="https://github.com/w3c/csswg-drafts/issues/3264">Issue 3264</a>)
4047+
<li>Limited selectors in '':nth-child()'' and '':nth-last-child()'' to [=compound selectors=] for now.
4048+
(<a href="https://github.com/w3c/csswg-drafts/issues/3760">Issue 3760</a>)
40414049
<li>Clarified case-sensitive string matching by referencing string identity as defined in [[INFRA]].
40424050
<li>Clarified that UA-provided placeholder text still triggers '':placeholder-shown''.
40434051
<li>Rewrote '':focus-visible'' definition for clarity.

0 commit comments

Comments
 (0)