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

Scoped style sheets.

From: Andrew Fedoniouk <news@terrainformatica.com>
Date: Mon, 14 Jul 2008 15:50:44 -0700
Message-ID: <487BD844.5060409@terrainformatica.com>
To: Lachlan Hunt <lachlan.hunt@lachy.id.au>
CC: www-style <www-style@w3.org>, Ian Hickson <ian@hixie.ch>

One more thing about <style scoped />.

What would be a specificity of CSS rules in scoped style sheet?
Question is in markup:

<html>
<style>
   body #content p { color:red; }
<body>
   <div #content>
     <style scoped>
         p { color:green; }
     </style>
     <p>what would be the color of this text?</p>
   </div>
</body>
</html>

It appears as <style scoped> should always be more specific than rules 
in just a <style>.
Yes/no?

-- 
Andrew Fedoniouk.

http://terrainformatica.com
Received on Monday, 14 July 2008 22:51:35 GMT

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