OLD | NEW |
1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
2 <html> | 2 <html> |
3 <head> | 3 <head> |
4 <link href="resources/grid.css" rel="stylesheet"> | 4 <link href="resources/grid.css" rel="stylesheet"> |
5 <style> | 5 <style> |
6 .grid { | 6 .grid { |
7 grid-template: "firstArea" "secondArea" | 7 grid-template: "firstArea secondArea" |
8 "thirdArea" "thirdArea"; | 8 "thirdArea thirdArea"; |
9 } | 9 } |
10 | 10 |
11 #oneValueGridArea { | 11 #oneValueGridArea { |
12 grid-area: 1; | 12 grid-area: 1; |
13 } | 13 } |
14 | 14 |
15 #oneValueIdentGridArea { | 15 #oneValueIdentGridArea { |
16 grid-area: thirdArea; | 16 grid-area: thirdArea; |
17 } | 17 } |
18 | 18 |
(...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
122 document.body.removeChild(parentElement); | 122 document.body.removeChild(parentElement); |
123 } | 123 } |
124 | 124 |
125 debug("Test getting grid-area set through CSS"); | 125 debug("Test getting grid-area set through CSS"); |
126 testGridAreaCSSParsing("oneValueGridArea", "1"); | 126 testGridAreaCSSParsing("oneValueGridArea", "1"); |
127 testGridAreaCSSParsing("oneValueIdentGridArea", "thirdArea", "thirdArea", "t
hirdArea", "thirdArea"); | 127 testGridAreaCSSParsing("oneValueIdentGridArea", "thirdArea", "thirdArea", "t
hirdArea", "thirdArea"); |
128 testGridAreaCSSParsing("twoValueGridArea", "-1", "span 1"); | 128 testGridAreaCSSParsing("twoValueGridArea", "-1", "span 1"); |
129 testGridAreaCSSParsing("twoValueIdentGridArea", "firstArea", "secondArea", "
firstArea", "secondArea"); | 129 testGridAreaCSSParsing("twoValueIdentGridArea", "firstArea", "secondArea", "
firstArea", "secondArea"); |
130 testGridAreaCSSParsing("threeValueGridArea", "span 1", "10", "-1"); | 130 testGridAreaCSSParsing("threeValueGridArea", "span 1", "10", "-1"); |
131 testGridAreaCSSParsing("fourValueGridArea", "-5", "span 5", "span 8", "9"); | 131 testGridAreaCSSParsing("fourValueGridArea", "-5", "span 5", "span 8", "9"); |
132 testGridAreaCSSParsing("fourValueMixedGridArea", "firstArea", "span 1", "non
Existent", "1 foobar"); | 132 testGridAreaCSSParsing("fourValueMixedGridArea", "firstArea", "span 1", "aut
o", "1 foobar"); |
133 | 133 |
134 debug(""); | 134 debug(""); |
135 debug("Test getting and setting grid-area set through JS"); | 135 debug("Test getting and setting grid-area set through JS"); |
136 testGridAreaJSParsing("-1"); | 136 testGridAreaJSParsing("-1"); |
137 testGridAreaJSParsing("-1 / span 5"); | 137 testGridAreaJSParsing("-1 / span 5"); |
138 testGridAreaJSParsing("-1 / 10 / span 3"); | 138 testGridAreaJSParsing("-1 / 10 / span 3"); |
139 | 139 |
140 debug(""); | 140 debug(""); |
141 debug("Test setting grid-area to 'initial' through JS"); | 141 debug("Test setting grid-area to 'initial' through JS"); |
142 testInitialGridArea(); | 142 testInitialGridArea(); |
143 | 143 |
144 debug(""); | 144 debug(""); |
145 debug("Test setting grid-area to 'inherit' through JS"); | 145 debug("Test setting grid-area to 'inherit' through JS"); |
146 testInheritGridArea(); | 146 testInheritGridArea(); |
147 | 147 |
148 debug(""); | 148 debug(""); |
149 debug("Test setting some positions to invalid values through JS"); | 149 debug("Test setting some positions to invalid values through JS"); |
150 testGridAreaInvalidJSParsing("span / span / span /"); | 150 testGridAreaInvalidJSParsing("span / span / span /"); |
151 testGridAreaInvalidJSParsing("1/ span span / 1 / span"); | 151 testGridAreaInvalidJSParsing("1/ span span / 1 / span"); |
152 testGridAreaInvalidJSParsing("span / 1 / -1 / 1 -1"); | 152 testGridAreaInvalidJSParsing("span / 1 / -1 / 1 -1"); |
153 testGridAreaInvalidJSParsing("span / 1 / -1 / 1 span -1"); | 153 testGridAreaInvalidJSParsing("span / 1 / -1 / 1 span -1"); |
154 </script> | 154 </script> |
155 </body> | 155 </body> |
156 </html> | 156 </html> |
OLD | NEW |