WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED DUPLICATE of
bug 5468
11386
CSS: :only-child, :only-of-type is applied to all first children
https://bugs.webkit.org/show_bug.cgi?id=11386
Summary
CSS: :only-child, :only-of-type is applied to all first children
Niels Leenheer (HTML5test)
Reported
2006-10-23 03:09:53 PDT
Current behavoir: The :only-child matches every first child and the :only-of-type selector matches every first child of a new type. Reason: The reason for this is that every time a new element is added to the DOM, it is checked to see if it matches one of the CSS selectors. Because the DOM is build one element at a time, every first child is at least for a moment the only child. The same applies to the first element of a certain type. It is at least for a moment the only of that type. Proper behavoir: The :only-child selector should only match elements that are *really* the only child. The :only-of-type selector should only match elements that are *really* the only child of a certain type. Once an element is no longer the only, or the only of a certain type, it should no longer match these selectors.
Attachments
Add attachment
proposed patch, testcase, etc.
Nicholas Shanks
Comment 1
2006-11-20 16:18:10 PST
*** This bug has been marked as a duplicate of
5468
***
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug