Side navigation
#4158 closed bug (fixed)
Opened February 15, 2009 10:42PM UTC
Closed February 16, 2009 05:58PM UTC
Last modified February 20, 2009 01:26PM UTC
multiple pseudo selector issues
Reported by: | initjh | Owned by: | |
---|---|---|---|
Priority: | major | Milestone: | 1.3.2 |
Component: | selector | Version: | 1.3.1 |
Keywords: | Cc: | ||
Blocked by: | Blocking: |
Description
Attachments (2)
Change History (9)
Changed February 15, 2009 11:09PM UTC by comment:1
Changed February 15, 2009 11:13PM UTC by comment:2
Replying to [comment:1 initjh]:
Seems I made a slight mistake, it only fails on :not(:nth-child(1)). Sorry.
Sorry, misread debugger. It does fail on :has(:nth-child(1)).
Changed February 16, 2009 07:58AM UTC by comment:3
Simplified test case:
Changed February 16, 2009 02:02PM UTC by comment:4
Actually, that's a different problem.
You should make a new ticket for that. I noticed that while testing on Chrome. The selector is processed in Chrome, but it selects the parent like you have shown.
This one is (I think) related to some RegEx problems in Sizzle, when you put :nth-child in :not or :has. Another example, :not(:not(:not(div))).
Changed February 16, 2009 02:07PM UTC by comment:5
Simplified test case, thanks for the test case site dz.
Changed February 16, 2009 04:24PM UTC by comment:6
I found a way to make it behave properly:
On the first iteration in Sizzle.filter, have it process PSEUDO type first instead of CHILD. It will then properly parse the :nth-child selector, and apply :not to it as expected.
Changed February 16, 2009 04:37PM UTC by comment:7
Changed February 16, 2009 05:58PM UTC by comment:8
component: | core → selector |
---|---|
resolution: | → fixed |
status: | new → closed |
Fixed in SVN rev [6212].
Changed February 20, 2009 01:26PM UTC by comment:9
description: | :not(:nth-child(1)) \ :has(:nth-child(1)) \ → :not(:nth-child(1)) \ \ See http://dev.jquery.com/ticket/4169 for: \ :has(:nth-child(1)) \ |
---|
Seems I made a slight mistake, it only fails on :not(nth-child(1)). Sorry.