Re: Custom dynamic properties

----- Original Message -----
> On Fri, Sep 17, 2010 at 10:34 AM, Paul Duffin <pduffin@volantis.com>
> wrote:
> > Given that HTML has no namespace support I had not considered using
> > attributes and attribute selectors due to the chance of clashing
> > with a built in or extension attribute. I had not considered the
> > data-* attributes which are frankly a poor substitute for a proper
> > namespace mechanism but it is sufficient.
> >
> > I am also concerned that there is some difference between the
> > behaviour of a pseudo class selector and an attribute selector.
> > Otherwise, what was the point of adding the :enabled and :disabled
> > pseudo classes when you could do that with attribute selectors and
> > the disabled attribute.
> 
> What difference do you think there is between pseudoclasses and
> attribute selectors? Other than the fact that they refer to different
> things, they're fairly similar.
> 

Personally, I find pseudo classes more abstract than attributes. However, you are correct that apart from the structural pseudo classes they could all be emulated using attribute selectors given the correct level of support from the browser.

> :enabled and :disabled were presumably introduced for parsimony with
> the other input-state-based pseudoclasses. It's also easier to write
> them than [disabled] and :not([disabled]) (plus, I don't think :not()
> existed at the time :enabled was first created?).
> 
> ~TJ

You don't need not(), just like you don't need :not-focused or :not-active.

Received on Friday, 17 September 2010 17:59:24 UTC