W3C home > Mailing lists > Public > www-style@w3.org > July 2008

Re: Scoped style sheets.

From: Lachlan Hunt <lachlan.hunt@lachy.id.au>
Date: Tue, 15 Jul 2008 09:37:27 +0200
Message-ID: <487C53B7.9030609@lachy.id.au>
To: David Woolley <forums@david-woolley.me.uk>
Cc: www-style <www-style@w3.org>

David Woolley wrote:
> (One thing that concerns me about the whole use case is that it is based 
> on embedding what are really separete resources, for reasons that have 
> to do with ensuring that advertisements are seen, not to do with the 
> natural structure of the information.  However the want to meet 
> commercial constraints is so endemic these days, that I don't think I'd 
> win such an argument amongst implementors.  The real solution would be 
> to make object work!)

Commercial cases like that aren't the only use cases for scoped 
stylesheets.  Consider this use case.

A blog has a normal theme applied to all articles that covers the 
general styling issues quite well.  But then the author publishes an 
article that requires some additional enhancements to be made, but the 
author wants to avoid inadvertently affecting the style of other articles.

Adding more rules to the site's global stylesheet, perhaps scoped by 
some unique article ID isn't really ideal because if it happens 
frequently, it causes the global stylesheet to be filled with lots of 
article specific styles.  In some cases, the article author may not even 
have access to modify the global stylesheet.

The solution needs to work in all places where the article is listed, 
including on its individual page or in a monthly archive listing.  The 
scoped stylesheet allows the author associate the set of styles with the 
article.

-- 
Lachlan Hunt - Opera Software
http://lachy.id.au/
http://www.opera.com/
Received on Tuesday, 15 July 2008 07:38:10 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 27 April 2009 13:55:10 GMT