00c41457cddc63026443f52df0af255e82310e62
[platform/framework/web/crosswalk.git] / src / third_party / WebKit / LayoutTests / fast / html / imports / resources / custom-element-style.html
1 <!DOCTYPE html>
2 <template>
3 <style>
4 @import url(hello.css);
5 </style>
6 <h1>Hello</h1>
7 </template>
8 <script>
9 var t = document.currentScript.ownerDocument.querySelector('template');
10 var proto = Object.create(HTMLElement.prototype);
11 proto.createdCallback = function() {
12   var root = this.createShadowRoot();
13   root.appendChild(document.importNode(t.content, true));
14 };
15 document.registerElement('x-test', {prototype: proto});
16 </script>