The :only-child selector applies to elements that are the only element child of their parent. They can have text siblings, just not element siblings. I can't think of any use cases for this, but, I can think of several for a selector that selects an element that is the only child of it's parent and /does not/ have any text siblings aside from whitespace. I want to be able to select <pre> <code> things like this </code> </pre> but not <pre> things like <code>this</code> </pre> Can't think of any good names for it (:only-child-content?), but I'd like to see this in some future version of CSS. ~fantasaiReceived on Thursday, 8 March 2007 21:47:48 GMT
This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 23 April 2007 18:22:36 GMT