summaryrefslogtreecommitdiffstats
path: root/layout/reftests/webcomponents/shadow-style-3.html
blob: ea2c7e7eda5e94645135a624710320c646b8fb05 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
<!DOCTYPE html>
<body>
<style>
body { color: red; }
</style>
<script>
var div = document.createElement("div");
var shadow = div.attachShadow({ mode: "open" });
var div2 = document.createElement("div");
var shadow2 = div2.attachShadow({ mode: "open" });
shadow2.innerHTML = '<style>p { color: green; }</style><p>This should be green.</p>';
shadow.appendChild(div2);
document.body.appendChild(div);
</script>