W3C home > Mailing lists > Public > www-style@w3.org > August 2012

Re: [css3-conditional] navigator.supportsCSS rather than window.supportsCSS

From: Glenn Adams <glenn@skynav.com>
Date: Wed, 15 Aug 2012 00:08:15 -0700
Message-ID: <CACQ=j+ct6RWmdw1Ot4UD15fVw-eLkmfwhbtXMCrmnGfd+mcExg@mail.gmail.com>
To: Elliott Sprehn <esprehn@gmail.com>
Cc: "Tab Atkins Jr." <jackalmage@gmail.com>, Boris Zbarsky <bzbarsky@mit.edu>, www-style list <www-style@w3.org>
On Tue, Aug 14, 2012 at 11:37 PM, Elliott Sprehn <esprehn@gmail.com> wrote:

> On Wed, Aug 8, 2012 at 9:40 AM, Tab Atkins Jr. <jackalmage@gmail.com>wrote:
>> So, based on the discussions on this thread, what does the group feel
>> about defining a new global named "CSS", which we use to hang new
>> css-related things off of that may not be worth polluting the global
>> object with (or that would require a cumbersome name if they were put
>> on the global).
> I don't like this idea. There's nothing like this in the platform yet, and
> the difference between CSS.PixelValue and CSSPixelValue is one letter.
> Either way, supports() really needs to be a document level feature anyway
> because browsers support different CSS properties in standards vs quirks
> mode (IE...), or even in extensions or apps vs web pages (ex -moz-binding).
> document.supportsCSS(property, value) is what you want.

I believe this is intended to be a function of the browser in general,
independent of whether operating in quirks mode or not, which is
effectively under author control. So NO, it should not be defined on
Document. Personally, if it is defined, I would prefer it be defined on
specific sub-interfaces of CSSRule, e.g.,
CSSFontFaceRule.supports(descriptor,value) or
CSSStyleRule.supports(propertyName, value) or
CSSPageRule.supports(pagePropertyName, value), since the first argument is
effectively local (distinct) according to the rule type. Having a single
global CSS.supports(name,value) doesn't sufficiently distinguish if one is
asking for support of a style property, a page property, a font face
descriptor, etc.
Received on Wednesday, 15 August 2012 07:09:05 UTC

This archive was generated by hypermail 2.4.0 : Friday, 25 March 2022 10:08:20 UTC