| OLD | NEW |
| 1 <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN"> | 1 <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN"> |
| 2 <html> | 2 <html> |
| 3 <head> | 3 <head> |
| 4 <script src="../../../fast/js/resources/js-test-pre.js"></script> | 4 <script src="../../../fast/js/resources/js-test-pre.js"></script> |
| 5 <style> | 5 <style> |
| 6 | 6 |
| 7 input.with-border::-webkit-inner-spin-button { | 7 input.with-border::-webkit-inner-spin-button { |
| 8 border: 10px solid; | 8 border: 10px solid; |
| 9 } | 9 } |
| 10 input.with-padding::-webkit-inner-spin-button { | 10 input.with-padding::-webkit-inner-spin-button { |
| (...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 56 debug('The number whose width is specified should respect the setting'); | 56 debug('The number whose width is specified should respect the setting'); |
| 57 shouldBe('numberWithWidth.offsetWidth', '100'); | 57 shouldBe('numberWithWidth.offsetWidth', '100'); |
| 58 shouldBe('numberWithWidth.min = 0; numberWithWidth.max = 100; numberWithWidth.of
fsetWidth', '100'); | 58 shouldBe('numberWithWidth.min = 0; numberWithWidth.max = 100; numberWithWidth.of
fsetWidth', '100'); |
| 59 debug(''); | 59 debug(''); |
| 60 | 60 |
| 61 debug('The number input should ignore size attribute for layout'); | 61 debug('The number input should ignore size attribute for layout'); |
| 62 shouldBe('number.size = 10; number.offsetWidth', 'text.offsetWidth'); | 62 shouldBe('number.size = 10; number.offsetWidth', 'text.offsetWidth'); |
| 63 shouldBe('number.size', '10'); | 63 shouldBe('number.size', '10'); |
| 64 shouldBe('number.size = 100; number.offsetWidth', 'text.offsetWidth'); | 64 shouldBe('number.size = 100; number.offsetWidth', 'text.offsetWidth'); |
| 65 shouldBe('number.size', '100'); | 65 shouldBe('number.size', '100'); |
| 66 shouldThrow('number.size = null', '"Error: IndexSizeError: DOM Exception 1"'); | 66 shouldThrow('number.size = null', '"IndexSizeError: Index or size was negative,
or greater than the allowed value."'); |
| 67 debug(''); | 67 debug(''); |
| 68 | 68 |
| 69 function numberWidth(min, max, step, className) { | 69 function numberWidth(min, max, step, className) { |
| 70 number.className = className; | 70 number.className = className; |
| 71 number.step = step; | 71 number.step = step; |
| 72 number.min = min; | 72 number.min = min; |
| 73 number.max = max; | 73 number.max = max; |
| 74 return number.offsetWidth; | 74 return number.offsetWidth; |
| 75 } | 75 } |
| 76 | 76 |
| (...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 151 | 151 |
| 152 shouldBe('numberWidth(123456, 123456, 0.0000005)', 'textWidthPlusSpinButtonWidth
(14)'); | 152 shouldBe('numberWidth(123456, 123456, 0.0000005)', 'textWidthPlusSpinButtonWidth
(14)'); |
| 153 | 153 |
| 154 debug('') | 154 debug('') |
| 155 </script> | 155 </script> |
| 156 | 156 |
| 157 | 157 |
| 158 <script src="../../../fast/js/resources/js-test-post.js"></script> | 158 <script src="../../../fast/js/resources/js-test-post.js"></script> |
| 159 </body> | 159 </body> |
| 160 </html> | 160 </html> |
| OLD | NEW |