Enter a description of the change.

Docs: Fix the script in the example to actually clone the template contents, not the template element itself.

Review URL: https://codereview.chromium.org/680673002
This commit is contained in:
Hixie 2014-10-24 16:23:03 -07:00
parent 86cd8beee7
commit 3f008050a2

View file

@ -14,7 +14,7 @@ SKY MODULE - radio button and radio button group
module.exports.RadioElement = sky.registerElement('radio', class extends Element {
constructor () {
this.addEventListener('click', (event) => this.checked = true);
this.createShadowTree().appendChild(module.document.findId('radio-shadow').cloneNode(true));
this.createShadowTree().appendChild(module.document.findId('radio-shadow').content.cloneNode(true));
}
get checked () {
return this.hasAttribute('checked');