<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.webkit.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4.1"
          urlbase="https://bugs.webkit.org/"
          
          maintainer="admin@webkit.org"
>

    <bug>
          <bug_id>105274</bug_id>
          
          <creation_ts>2012-12-18 03:14:20 -0800</creation_ts>
          <short_desc>The style sheets, represented by the shadow nodes are not hidden</short_desc>
          <delta_ts>2013-03-14 21:59:11 -0700</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>DOM</component>
          <version>528+ (Nightly build)</version>
          <rep_platform>Unspecified</rep_platform>
          <op_sys>Unspecified</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>DUPLICATE</resolution>
          <dup_id>100332</dup_id>
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          <blocked>63606</blocked>
    
    <blocked>103230</blocked>
          <everconfirmed>0</everconfirmed>
          <reporter name="Aleksei Yu. Semenov">a.semenov</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>dglazkov</cc>
    
    <cc>morrita</cc>
    
    <cc>shinyak</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>793509</commentid>
    <comment_count>0</comment_count>
    <who name="Aleksei Yu. Semenov">a.semenov</who>
    <bug_when>2012-12-18 03:14:20 -0800</bug_when>
    <thetext>The Shadow DOM Specification reads:

&quot;4.1 Upper-boundary Encapsulation

To maintain the upper-boundary encapsulation, the following scoping constraints must apply to all nodes in a shadow tree:
....
 * The style sheets, represented by the nodes are not accessible using shadow host document&apos;s CSSOM extensions&quot;

However in Google Chrome browser version 25.0.1363.0 canary, shadowed style node is accessible via document.styleSeets.

Here is sample code:

&lt;html&gt;
&lt;head&gt;
&lt;script&gt;
function test(){
	var shadowRoot = new window.WebKitShadowRoot(document.head);
	var style = document.createElement(&apos;style&apos;);
	shadowRoot.appendChild(style);
	document.write(&apos;StyleSheets count: &apos; + document.styleSheets.length + &apos;(expected: 0)&apos;);
}
&lt;/script&gt;
&lt;/head&gt;
&lt;body onload=&apos;test()&apos;&gt;
&lt;/body&gt;
&lt;html&gt;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>855687</commentid>
    <comment_count>1</comment_count>
    <who name="Hajime Morrita">morrita</who>
    <bug_when>2013-03-14 21:59:11 -0700</bug_when>
    <thetext>

*** This bug has been marked as a duplicate of bug 100332 ***</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>