OLD | NEW |
1 <!DOCTYPE HTML> | 1 <!DOCTYPE HTML> |
2 </html> | 2 <html> |
3 <head> | 3 <head> |
4 <title>-webkit-columns shorthand getPropertyValue test</title> | 4 <title>-webkit-columns shorthand getPropertyValue test</title> |
5 <style> | 5 <style> |
6 .test { | 6 .test { |
7 width: 100px; | 7 width: 100px; |
8 height: 100px; | 8 height: 100px; |
9 } | 9 } |
10 </style> | 10 </style> |
11 <script src="../../resources/js-test.js"></script> | 11 <script src="../../resources/js-test.js"></script> |
12 <script> | 12 <script> |
(...skipping 12 matching lines...) Expand all Loading... |
25 <div id="columns8" class="test" style="-webkit-columns: foo;"></div> | 25 <div id="columns8" class="test" style="-webkit-columns: foo;"></div> |
26 <div id="columns9" class="test" style="-webkit-column-width: 10px;"></div> | 26 <div id="columns9" class="test" style="-webkit-column-width: 10px;"></div> |
27 <script> | 27 <script> |
28 description("<a href=\"https://bugs.webkit.org/show_bug.cgi?id=111011\">Bu
g 111011: getPropertyValue for -webkit-columns returns null, should compute the
shorthand value</a>"); | 28 description("<a href=\"https://bugs.webkit.org/show_bug.cgi?id=111011\">Bu
g 111011: getPropertyValue for -webkit-columns returns null, should compute the
shorthand value</a>"); |
29 | 29 |
30 function webkitColumnsValue(id) { | 30 function webkitColumnsValue(id) { |
31 var element = document.getElementById(id); | 31 var element = document.getElementById(id); |
32 return element.style.getPropertyValue("-webkit-columns"); | 32 return element.style.getPropertyValue("-webkit-columns"); |
33 } | 33 } |
34 | 34 |
35 shouldBeEqualToString('webkitColumnsValue("columns1")', '10px'); | 35 shouldBeEqualToString('webkitColumnsValue("columns1")', '10px auto'); |
36 shouldBeEqualToString('webkitColumnsValue("columns2")', '10'); | 36 shouldBeEqualToString('webkitColumnsValue("columns2")', 'auto 10'); |
37 shouldBeEqualToString('webkitColumnsValue("columns3")', '10px auto'); | 37 shouldBeEqualToString('webkitColumnsValue("columns3")', '10px auto'); |
38 shouldBeEqualToString('webkitColumnsValue("columns4")', 'auto'); | 38 shouldBeEqualToString('webkitColumnsValue("columns4")', 'auto auto'); |
39 shouldBeEqualToString('webkitColumnsValue("columns5")', 'auto 2'); | 39 shouldBeEqualToString('webkitColumnsValue("columns5")', 'auto 2'); |
40 shouldBeEqualToString('webkitColumnsValue("columns6")', '10px 2'); | 40 shouldBeEqualToString('webkitColumnsValue("columns6")', '10px 2'); |
41 shouldBeEqualToString('webkitColumnsValue("columns7")', 'auto auto'); | 41 shouldBeEqualToString('webkitColumnsValue("columns7")', 'auto auto'); |
42 debug("NOTE: 'foo' is an illegal CSS value for '-webkit-columns'."); | 42 debug("NOTE: 'foo' is an illegal CSS value for '-webkit-columns'."); |
43 shouldBe('webkitColumnsValue("columns8")', "null"); | 43 shouldBe('webkitColumnsValue("columns8")', "null"); |
44 debug("NOTE: If only few longhand properties are specified, getPropertyVal
ue for shorthand property returns null.") | 44 debug("NOTE: If only few longhand properties are specified, getPropertyVal
ue for shorthand property returns null.") |
45 shouldBe('webkitColumnsValue("columns9")', "null"); | 45 shouldBe('webkitColumnsValue("columns9")', "null"); |
46 </script> | 46 </script> |
47 </body> | 47 </body> |
48 </html> | 48 </html> |
OLD | NEW |