OLD | NEW |
1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
2 <html> | 2 <html> |
3 | 3 |
4 <div id="host1"><div>Host Child</div></div> | 4 <div id="host1"><div>Host Child</div></div> |
5 | 5 |
6 <script> | 6 <script> |
7 var shadowRoot1 = host1.createShadowRoot(); | 7 var shadowRoot1 = host1.createShadowRoot(); |
8 shadowRoot1.innerHTML = '<div id="host2">Oldest ShadowRoot Child</div>'; | 8 shadowRoot1.innerHTML = '<div id="host2">Oldest ShadowRoot Child</div>'; |
9 | 9 |
10 var shadowRoot2 = host1.createShadowRoot(); | 10 var shadowRoot2 = host1.createShadowRoot(); |
11 shadowRoot2.innerHTML = '<shadow></shadow><content></content><shadow><div>Should
not be selected</div></shadow>'; | 11 shadowRoot2.innerHTML = '<shadow></shadow><content></content><shadow><div>Should
not be selected</div></shadow>'; |
12 | 12 |
13 var shadowRoot3 = host1.createShadowRoot(); | 13 var shadowRoot3 = host1.createShadowRoot(); |
14 shadowRoot3.innerHTML = '<div id="host4"><shadow><content></content></shadow><sh
adow><div>Should not be selected</div></shadow><span>Not rendered (1)</span><sha
dow><span>Not rendered (2)</span></shadow></div>'; | 14 shadowRoot3.innerHTML = '<div id="host4"><shadow></shadow><shadow><div>Should no
t be selected</div></shadow><span>Not rendered (1)</span><shadow><span>Not rende
red (2)</span></shadow></div>'; |
15 | 15 |
16 var host4 = shadowRoot3.getElementById('host4'); | 16 var host4 = shadowRoot3.getElementById('host4'); |
17 var shadowRoot4 = host4.createShadowRoot(); | 17 var shadowRoot4 = host4.createShadowRoot(); |
18 | 18 |
19 shadowRoot4.innerHTML = '<content select="div"></content>'; | 19 shadowRoot4.innerHTML = '<content select="div"></content>'; |
20 </script> | 20 </script> |
21 | 21 |
22 </html> | 22 </html> |
OLD | NEW |