Re: [selectors] Tree selectors

How about something similar to counters? [1]

   body, section, navigation { depth-weight: IDENT 1; }
   h:depth(IDENT, 3) {}

that is, :depth(IDENT, number) would match an element where the sum of
its ascenders' weight for the depth IDENT equals number.


/Mats Palmgren


[1] http://www.w3.org/TR/2003/WD-css3-content-20030514/#counters

Received on Tuesday, 22 March 2005 04:57:50 UTC