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> | 4 <script> |
5 if (window.testRunner) | 5 if (window.testRunner) |
6 testRunner.overridePreference("WebKitCSSGridLayoutEnabled", 1); | 6 testRunner.overridePreference("WebKitCSSGridLayoutEnabled", 1); |
7 </script> | 7 </script> |
8 <link href="resources/grid.css" rel="stylesheet"> | 8 <link href="resources/grid.css" rel="stylesheet"> |
9 <style> | 9 <style> |
10 .gridAutoFixedFixed { | 10 .gridAutoFixedFixed { |
11 grid-auto-rows: 30px; | 11 grid-auto-rows: 30px; |
12 grid-auto-columns: 50px; | 12 grid-auto-columns: 50px; |
13 } | 13 } |
14 | 14 |
15 .gridAutoMinMax { | 15 .gridAutoMinMax { |
16 grid-auto-rows: minmax(10%, 15px); | 16 grid-auto-rows: minmax(10%, 15px); |
17 grid-auto-columns: minmax(30%, 100px); | 17 grid-auto-columns: minmax(30%, 100px); |
18 } | 18 } |
19 | 19 |
20 .gridAutoMinMaxContent { | 20 .gridAutoMinMaxContent { |
21 grid-auto-rows: min-content; | 21 grid-auto-rows: min-content; |
22 grid-auto-columns: max-content; | 22 grid-auto-columns: max-content; |
23 } | 23 } |
24 </style> | 24 </style> |
25 <script src="../js/resources/js-test-pre.js"></script> | 25 <script src="../../resources/js-test.js"></script> |
26 </head> | 26 </head> |
27 <body> | 27 <body> |
28 <div class="grid gridAutoFixedFixed" id="gridAutoFixedFixed"></div> | 28 <div class="grid gridAutoFixedFixed" id="gridAutoFixedFixed"></div> |
29 <div class="grid gridAutoMinMax" id="gridAutoMinMax"></div> | 29 <div class="grid gridAutoMinMax" id="gridAutoMinMax"></div> |
30 <div class="grid gridAutoMinMaxContent" id="gridAutoMinMaxContent"></div> | 30 <div class="grid gridAutoMinMaxContent" id="gridAutoMinMaxContent"></div> |
31 <script> | 31 <script> |
32 description('Test that setting and getting grid-auto-columns and grid-auto-rows
works as expected'); | 32 description('Test that setting and getting grid-auto-columns and grid-auto-rows
works as expected'); |
33 | 33 |
34 debug("Test getting grid-auto-columns and grid-auto-rows set through CSS"); | 34 debug("Test getting grid-auto-columns and grid-auto-rows set through CSS"); |
35 var gridAutoFixedFixed = document.getElementById("gridAutoFixedFixed"); | 35 var gridAutoFixedFixed = document.getElementById("gridAutoFixedFixed"); |
(...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
153 shouldBe("getComputedStyle(element, '').getPropertyValue('grid-auto-rows')",
"'auto'"); | 153 shouldBe("getComputedStyle(element, '').getPropertyValue('grid-auto-rows')",
"'auto'"); |
154 | 154 |
155 document.body.removeChild(element); | 155 document.body.removeChild(element); |
156 } | 156 } |
157 debug(""); | 157 debug(""); |
158 debug("Test setting grid-auto-columns and grid-auto-rows to 'initial' through JS
"); | 158 debug("Test setting grid-auto-columns and grid-auto-rows to 'initial' through JS
"); |
159 testInitial(); | 159 testInitial(); |
160 </script> | 160 </script> |
161 </body> | 161 </body> |
162 </html> | 162 </html> |
OLD | NEW |