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