| OLD | NEW |
| (Empty) | |
| 1 <!DOCTYPE html> |
| 2 <body> |
| 3 <style> |
| 4 input { |
| 5 -webkit-appearance: none; |
| 6 background-color: white; |
| 7 border: none; |
| 8 color: black; |
| 9 margin: 2px; |
| 10 padding: 2px; |
| 11 } |
| 12 </style> |
| 13 <div><input type="button" value="button"></div> |
| 14 <div><input type="checkbox" value="checkbox"></div> |
| 15 <div><input type="color" value="#ff0000"></div> |
| 16 <div><input type="date" value="2013-09-05"></div> |
| 17 <div><input type="file"></div> |
| 18 <div><input type="hidden" value="hidden"></div> |
| 19 <div><input type="number" value="3.141592"></div> |
| 20 <div><input type="radio"></div> |
| 21 <div><input type="range"></div> |
| 22 <div><input type="search" value="search"></div> |
| 23 <div><input type="text" value="text"></div> |
| 24 <script> |
| 25 window.onload = function() { |
| 26 var inputs = document.querySelectorAll('input'); |
| 27 for (var i = 0; i < inputs.length; ++i) { |
| 28 var contentSpan = document.createElement('span'); |
| 29 contentSpan.textContent = 'Content'; |
| 30 inputs[i].appendChild(contentSpan); |
| 31 inputs[i].createShadowRoot().innerHTML = '<span>Shadow!</span><content s
elect="*"></content>'; |
| 32 } |
| 33 }; |
| 34 </script> |
| 35 </body> |
| OLD | NEW |