Re: Proposal for new `any of these elements' selector type

Matthew Thomas wrote:
>
> The cause of the problem is that instead of just selecting on UL, we're
> selecting on UL or OL or DIR or MENU. And while CSS allows selecting on
> one element (NameOfElementHere) or all elements (*), it does not allow
> selecting on a particular subset of elements.
> 
> So, I thought, why not introduce `any of these elements' syntax into
> CSS? Then all the above html.css code could be replaced with only three lines:
> |
> |                                   ul {list-style-type: disc;}
> |                  (ul,ol,menu,dir) ul {list-style-type: circle;}
> | (ul,ol,menu,dir) (ul,ol,menu,dir) ul {list-style-type: square;}
> 
> Discuss amongst yourselves. :-)

This can be done with the :matches() proposal - 

                                                  ul {list-style-type: disc;}
                         :matches(ul,ol,menu,dir) ul {list-style-type: circle;}
:matches(ul,ol,menu,dir) :matches(ul,ol,menu,dir) ul {list-style-type: square;}

Received on Wednesday, 2 January 2002 15:54:43 UTC