OLD | NEW |
1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
2 <html> | 2 <html> |
3 <head> | 3 <head> |
| 4 <link href="../css-intrinsic-dimensions/resources/width-keyword-classes.css" rel
="stylesheet"> |
4 <link href="resources/grid.css" rel="stylesheet"> | 5 <link href="resources/grid.css" rel="stylesheet"> |
| 6 <link href="resources/grid-alignment.css" rel="stylesheet"> |
5 <script src="../../resources/check-layout.js"></script> | 7 <script src="../../resources/check-layout.js"></script> |
6 <style> | 8 <style> |
7 body { | 9 body { |
8 margin: 0; | 10 margin: 0; |
9 } | 11 } |
10 | 12 |
11 .grid { | 13 .grid { |
12 grid-template-columns: 150px 150px; | 14 grid-template-columns: 150px 150px; |
13 grid-template-rows: 120px 120px 120px; | 15 grid-template-rows: 120px 120px 120px; |
14 width: -webkit-fit-content; | |
15 margin-bottom: 20px; | 16 margin-bottom: 20px; |
16 } | 17 } |
17 | 18 |
18 .cellOverflowWidth { | 19 .cellOverflowWidth { |
19 width: 180px; | 20 width: 180px; |
20 height: 40px; | 21 height: 40px; |
21 } | 22 } |
22 | 23 |
23 .cellOverflowHeight { | 24 .cellOverflowHeight { |
24 width: 50px; | 25 width: 50px; |
25 height: 150px; | 26 height: 150px; |
26 } | 27 } |
27 | 28 |
28 .cellWithNoOverflow { | 29 .cellWithNoOverflow { |
29 width: 50px; | 30 width: 50px; |
30 height: 40px; | 31 height: 40px; |
31 } | 32 } |
32 | 33 |
33 .alignItemsCenter { | |
34 align-items: center; | |
35 } | |
36 | |
37 .alignItemsCenterSafe { | |
38 align-items: center safe; | |
39 } | |
40 | |
41 .alignItemsCenterUnsafe { | |
42 align-items: center unsafe; | |
43 } | |
44 | |
45 .alignItemsEnd { | |
46 align-items: end; | |
47 } | |
48 | |
49 .alignItemsEndSafe { | |
50 align-items: end safe; | |
51 } | |
52 | |
53 .alignItemsEndUnsafe { | |
54 align-items: end unsafe; | |
55 } | |
56 | |
57 .alignSelfCenter { | |
58 align-self: center; | |
59 } | |
60 | |
61 .alignSelfCenterSafe { | |
62 align-self: center safe; | |
63 } | |
64 | |
65 .alignSelfCenterUnsafe { | |
66 align-self: center unsafe; | |
67 } | |
68 | |
69 .alignSelfEnd { | |
70 align-self: end; | |
71 } | |
72 | |
73 .alignSelfEndSafe { | |
74 align-self: end safe; | |
75 } | |
76 | |
77 .alignSelfEndUnsafe { | |
78 align-self: end unsafe; | |
79 } | |
80 | |
81 .justifyItemsCenter { | |
82 justify-items: center; | |
83 } | |
84 | |
85 .justifyItemsCenterSafe { | |
86 justify-items: center safe; | |
87 } | |
88 | |
89 .justifyItemsCenterUnsafe { | |
90 justify-items: center unsafe; | |
91 } | |
92 | |
93 .justifyItemsEnd { | |
94 justify-items: end; | |
95 } | |
96 | |
97 .justifyItemsEndSafe { | |
98 justify-items: end safe; | |
99 } | |
100 | |
101 .justifyItemsEndUnsafe { | |
102 justify-items: end unsafe; | |
103 } | |
104 | |
105 .justifySelfCenter { | |
106 justify-self: center; | |
107 } | |
108 | |
109 .justifySelfCenterSafe { | |
110 justify-self: center safe; | |
111 } | |
112 | |
113 .justifySelfCenterUnsafe { | |
114 justify-self: center unsafe; | |
115 } | |
116 | |
117 .justifySelfEnd { | |
118 justify-self: end; | |
119 } | |
120 | |
121 .thirdRowFirstColumn { | 34 .thirdRowFirstColumn { |
122 background-color: green; | 35 background-color: green; |
123 grid-column: 1; | 36 grid-column: 1; |
124 grid-row: 3; | 37 grid-row: 3; |
125 } | 38 } |
126 </style> | 39 </style> |
127 </head> | 40 </head> |
128 <body onload="checkLayout('.grid')"> | 41 <body onload="checkLayout('.grid')"> |
129 | 42 |
130 <p>This test checks that the 'overflow' keyword is applied correctly for 'align'
and 'justify' properties.</p> | 43 <p>This test checks that the 'overflow' keyword is applied correctly for 'align'
and 'justify' properties.</p> |
131 | 44 |
132 <div style="position: relative"> | 45 <div style="position: relative"> |
133 <div class="grid alignItemsCenter justifyItemsCenter" data-expected-width="3
00" data-expected-height="360"> | 46 <div class="grid fit-content alignItemsCenter justifyItemsCenter" data-expec
ted-width="300" data-expected-height="360"> |
134 <div class="cellOverflowWidth firstRowFirstColumn" data-offset-x="-15"
data-offset-y="40" data-expected-width="180" data-expected-height="40"></div> | 47 <div class="cellOverflowWidth firstRowFirstColumn" data-offset-x="-15"
data-offset-y="40" data-expected-width="180" data-expected-height="40"></div> |
135 <div class="cellWithNoOverflow secondRowFirstColumn" data-offset-x="50"
data-offset-y="160" data-expected-width="50" data-expected-height="40"></div> | 48 <div class="cellWithNoOverflow secondRowFirstColumn" data-offset-x="50"
data-offset-y="160" data-expected-width="50" data-expected-height="40"></div> |
136 <div class="cellWithNoOverflow thirdRowFirstColumn" data-offset-x="50" d
ata-offset-y="280" data-expected-width="50" data-expected-height="40"></div> | 49 <div class="cellWithNoOverflow thirdRowFirstColumn" data-offset-x="50" d
ata-offset-y="280" data-expected-width="50" data-expected-height="40"></div> |
137 <div class="cellWithNoOverflow firstRowSecondColumn" data-offset-x="200"
data-offset-y="40" data-expected-width="50" data-expected-height="40"></div> | 50 <div class="cellWithNoOverflow firstRowSecondColumn" data-offset-x="200"
data-offset-y="40" data-expected-width="50" data-expected-height="40"></div> |
138 <div class="cellOverflowWidth secondRowSecondColumn" data-offset-x="135
" data-offset-y="160" data-expected-width="180" data-expected-height="40"></div> | 51 <div class="cellOverflowWidth secondRowSecondColumn" data-offset-x="135
" data-offset-y="160" data-expected-width="180" data-expected-height="40"></div> |
139 <div class="cellWithNoOverflow thirdRowSecondColumn" data-offset-x="200"
data-offset-y="280" data-expected-width="50" data-expected-height="40"></div> | 52 <div class="cellWithNoOverflow thirdRowSecondColumn" data-offset-x="200"
data-offset-y="280" data-expected-width="50" data-expected-height="40"></div> |
140 </div> | 53 </div> |
141 </div> | 54 </div> |
142 | 55 |
143 <div style="position: relative"> | 56 <div style="position: relative"> |
144 <div class="grid alignItemsCenterUnsafe justifyItemsCenterUnsafe" data-expec
ted-width="300" data-expected-height="360"> | 57 <div class="grid fit-content alignItemsCenterUnsafe justifyItemsCenterUnsafe
" data-expected-width="300" data-expected-height="360"> |
145 <div class="cellOverflowHeight firstRowFirstColumn" data-offset-x="50" d
ata-offset-y="-15" data-expected-width="50" data-expected-height="150"></div> | 58 <div class="cellOverflowHeight firstRowFirstColumn" data-offset-x="50" d
ata-offset-y="-15" data-expected-width="50" data-expected-height="150"></div> |
146 <div class="cellWithNoOverflow secondRowFirstColumn" data-offset-x="50"
data-offset-y="160" data-expected-width="50" data-expected-height="40"></div> | 59 <div class="cellWithNoOverflow secondRowFirstColumn" data-offset-x="50"
data-offset-y="160" data-expected-width="50" data-expected-height="40"></div> |
147 <div class="cellWithNoOverflow thirdRowFirstColumn" data-offset-x="50" d
ata-offset-y="280" data-expected-width="50" data-expected-height="40"></div> | 60 <div class="cellWithNoOverflow thirdRowFirstColumn" data-offset-x="50" d
ata-offset-y="280" data-expected-width="50" data-expected-height="40"></div> |
148 <div class="cellWithNoOverflow firstRowSecondColumn" data-offset-x="200"
data-offset-y="40" data-expected-width="50" data-expected-height="40"></div> | 61 <div class="cellWithNoOverflow firstRowSecondColumn" data-offset-x="200"
data-offset-y="40" data-expected-width="50" data-expected-height="40"></div> |
149 <div class="cellOverflowHeight secondRowSecondColumn" data-offset-x="200
" data-offset-y="105" data-expected-width="50" data-expected-height="150"></div> | 62 <div class="cellOverflowHeight secondRowSecondColumn" data-offset-x="200
" data-offset-y="105" data-expected-width="50" data-expected-height="150"></div> |
150 <div class="cellWithNoOverflow thirdRowSecondColumn" data-offset-x="200"
data-offset-y="280" data-expected-width="50" data-expected-height="40"></div> | 63 <div class="cellWithNoOverflow thirdRowSecondColumn" data-offset-x="200"
data-offset-y="280" data-expected-width="50" data-expected-height="40"></div> |
151 </div> | 64 </div> |
152 </div> | 65 </div> |
153 | 66 |
154 <div style="position: relative"> | 67 <div style="position: relative"> |
155 <div class="grid alignItemsCenterSafe justifyItemsCenterSafe" data-expected-
width="300" data-expected-height="360"> | 68 <div class="grid fit-content alignItemsCenterSafe justifyItemsCenterSafe" da
ta-expected-width="300" data-expected-height="360"> |
156 <div class="cellOverflowWidth firstRowFirstColumn" data-offset-x="0" da
ta-offset-y="40" data-expected-width="180" data-expected-height="40"></div> | 69 <div class="cellOverflowWidth firstRowFirstColumn" data-offset-x="0" da
ta-offset-y="40" data-expected-width="180" data-expected-height="40"></div> |
157 <div class="cellWithNoOverflow secondRowFirstColumn" data-offset-x="50"
data-offset-y="160" data-expected-width="50" data-expected-height="40"></div> | 70 <div class="cellWithNoOverflow secondRowFirstColumn" data-offset-x="50"
data-offset-y="160" data-expected-width="50" data-expected-height="40"></div> |
158 <div class="cellWithNoOverflow thirdRowFirstColumn" data-offset-x="50" d
ata-offset-y="280" data-expected-width="50" data-expected-height="40"></div> | 71 <div class="cellWithNoOverflow thirdRowFirstColumn" data-offset-x="50" d
ata-offset-y="280" data-expected-width="50" data-expected-height="40"></div> |
159 <div class="cellWithNoOverflow firstRowSecondColumn" data-offset-x="200"
data-offset-y="40" data-expected-width="50" data-expected-height="40"></div> | 72 <div class="cellWithNoOverflow firstRowSecondColumn" data-offset-x="200"
data-offset-y="40" data-expected-width="50" data-expected-height="40"></div> |
160 <div class="cellOverflowWidth secondRowSecondColumn" data-offset-x="150
" data-offset-y="160" data-expected-width="180" data-expected-height="40"></div> | 73 <div class="cellOverflowWidth secondRowSecondColumn" data-offset-x="150
" data-offset-y="160" data-expected-width="180" data-expected-height="40"></div> |
161 <div class="cellWithNoOverflow thirdRowSecondColumn" data-offset-x="200"
data-offset-y="280" data-expected-width="50" data-expected-height="40"></div> | 74 <div class="cellWithNoOverflow thirdRowSecondColumn" data-offset-x="200"
data-offset-y="280" data-expected-width="50" data-expected-height="40"></div> |
162 </div> | 75 </div> |
163 </div> | 76 </div> |
164 | 77 |
165 <div style="position: relative"> | 78 <div style="position: relative"> |
166 <div class="grid alignItemsCenterSafe justifyItemsCenterSafe" data-expected-
width="300" data-expected-height="360"> | 79 <div class="grid fit-content alignItemsCenterSafe justifyItemsCenterSafe" da
ta-expected-width="300" data-expected-height="360"> |
167 <div class="cellOverflowHeight firstRowFirstColumn" data-offset-x="50" d
ata-offset-y="0" data-expected-width="50" data-expected-height="150"></div> | 80 <div class="cellOverflowHeight firstRowFirstColumn" data-offset-x="50" d
ata-offset-y="0" data-expected-width="50" data-expected-height="150"></div> |
168 <div class="cellWithNoOverflow secondRowFirstColumn" data-offset-x="50"
data-offset-y="160" data-expected-width="50" data-expected-height="40"></div> | 81 <div class="cellWithNoOverflow secondRowFirstColumn" data-offset-x="50"
data-offset-y="160" data-expected-width="50" data-expected-height="40"></div> |
169 <div class="cellWithNoOverflow thirdRowFirstColumn" data-offset-x="50" d
ata-offset-y="280" data-expected-width="50" data-expected-height="40"></div> | 82 <div class="cellWithNoOverflow thirdRowFirstColumn" data-offset-x="50" d
ata-offset-y="280" data-expected-width="50" data-expected-height="40"></div> |
170 <div class="cellWithNoOverflow firstRowSecondColumn" data-offset-x="200"
data-offset-y="40" data-expected-width="50" data-expected-height="40"></div> | 83 <div class="cellWithNoOverflow firstRowSecondColumn" data-offset-x="200"
data-offset-y="40" data-expected-width="50" data-expected-height="40"></div> |
171 <div class="cellOverflowHeight secondRowSecondColumn alignSelfCenterSafe
justifySelfCenterSafe" data-offset-x="200" data-offset-y="120" data-expected-wi
dth="50" data-expected-height="150"></div> | 84 <div class="cellOverflowHeight secondRowSecondColumn alignSelfCenterSafe
justifySelfCenterSafe" data-offset-x="200" data-offset-y="120" data-expected-wi
dth="50" data-expected-height="150"></div> |
172 <div class="cellWithNoOverflow thirdRowSecondColumn" data-offset-x="200"
data-offset-y="280" data-expected-width="50" data-expected-height="40"></div> | 85 <div class="cellWithNoOverflow thirdRowSecondColumn" data-offset-x="200"
data-offset-y="280" data-expected-width="50" data-expected-height="40"></div> |
173 </div> | 86 </div> |
174 </div> | 87 </div> |
175 | 88 |
176 <div style="position: relative"> | 89 <div style="position: relative"> |
177 <div class="grid alignItemsEnd justifyItemsEnd" data-expected-width="300" da
ta-expected-height="360"> | 90 <div class="grid fit-content alignItemsEnd justifyItemsEnd" data-expected-wi
dth="300" data-expected-height="360"> |
178 <div class="cellOverflowWidth firstRowFirstColumn" data-offset-x="-30"
data-offset-y="80" data-expected-width="180" data-expected-height="40"></div> | 91 <div class="cellOverflowWidth firstRowFirstColumn" data-offset-x="-30"
data-offset-y="80" data-expected-width="180" data-expected-height="40"></div> |
179 <div class="cellWithNoOverflow secondRowFirstColumn justifySelfCenter" d
ata-offset-x="50" data-offset-y="200" data-expected-width="50" data-expected-hei
ght="40"></div> | 92 <div class="cellWithNoOverflow secondRowFirstColumn justifySelfCenter" d
ata-offset-x="50" data-offset-y="200" data-expected-width="50" data-expected-hei
ght="40"></div> |
180 <div class="cellWithNoOverflow thirdRowFirstColumn" data-offset-x="100"
data-offset-y="320" data-expected-width="50" data-expected-height="40"></div> | 93 <div class="cellWithNoOverflow thirdRowFirstColumn" data-offset-x="100"
data-offset-y="320" data-expected-width="50" data-expected-height="40"></div> |
181 <div class="cellWithNoOverflow firstRowSecondColumn" data-offset-x="250"
data-offset-y="80" data-expected-width="50" data-expected-height="40"></div> | 94 <div class="cellWithNoOverflow firstRowSecondColumn" data-offset-x="250"
data-offset-y="80" data-expected-width="50" data-expected-height="40"></div> |
182 <div class="cellOverflowWidth secondRowSecondColumn" data-offset-x="120
" data-offset-y="200" data-expected-width="180" data-expected-height="40"></div> | 95 <div class="cellOverflowWidth secondRowSecondColumn" data-offset-x="120
" data-offset-y="200" data-expected-width="180" data-expected-height="40"></div> |
183 <div class="cellWithNoOverflow thirdRowSecondColumn" data-offset-x="250"
data-offset-y="320" data-expected-width="50" data-expected-height="40"></div> | 96 <div class="cellWithNoOverflow thirdRowSecondColumn" data-offset-x="250"
data-offset-y="320" data-expected-width="50" data-expected-height="40"></div> |
184 </div> | 97 </div> |
185 </div> | 98 </div> |
186 | 99 |
187 <div style="position: relative"> | 100 <div style="position: relative"> |
188 <div class="grid alignItemsEndUnsafe justifyItemsEndUnsafe" data-expected-wi
dth="300" data-expected-height="360"> | 101 <div class="grid fit-content alignItemsEndUnsafe justifyItemsEndUnsafe" data
-expected-width="300" data-expected-height="360"> |
189 <div class="cellOverflowHeight firstRowFirstColumn" data-offset-x="100"
data-offset-y="-30" data-expected-width="50" data-expected-height="150"></div> | 102 <div class="cellOverflowHeight firstRowFirstColumn" data-offset-x="100"
data-offset-y="-30" data-expected-width="50" data-expected-height="150"></div> |
190 <div class="cellWithNoOverflow secondRowFirstColumn" data-offset-x="100"
data-offset-y="200" data-expected-width="50" data-expected-height="40"></div> | 103 <div class="cellWithNoOverflow secondRowFirstColumn" data-offset-x="100"
data-offset-y="200" data-expected-width="50" data-expected-height="40"></div> |
191 <div class="cellWithNoOverflow thirdRowFirstColumn" data-offset-x="100"
data-offset-y="320" data-expected-width="50" data-expected-height="40"></div> | 104 <div class="cellWithNoOverflow thirdRowFirstColumn" data-offset-x="100"
data-offset-y="320" data-expected-width="50" data-expected-height="40"></div> |
192 <div class="cellWithNoOverflow firstRowSecondColumn alignSelfCenter" dat
a-offset-x="250" data-offset-y="40" data-expected-width="50" data-expected-heigh
t="40"></div> | 105 <div class="cellWithNoOverflow firstRowSecondColumn alignSelfCenter" dat
a-offset-x="250" data-offset-y="40" data-expected-width="50" data-expected-heigh
t="40"></div> |
193 <div class="cellOverflowHeight secondRowSecondColumn" data-offset-x="250
" data-offset-y="90" data-expected-width="50" data-expected-height="150"></div> | 106 <div class="cellOverflowHeight secondRowSecondColumn" data-offset-x="250
" data-offset-y="90" data-expected-width="50" data-expected-height="150"></div> |
194 <div class="cellWithNoOverflow thirdRowSecondColumn" data-offset-x="250"
data-offset-y="320" data-expected-width="50" data-expected-height="40"></div> | 107 <div class="cellWithNoOverflow thirdRowSecondColumn" data-offset-x="250"
data-offset-y="320" data-expected-width="50" data-expected-height="40"></div> |
195 </div> | 108 </div> |
196 </div> | 109 </div> |
197 | 110 |
198 <div style="position: relative"> | 111 <div style="position: relative"> |
199 <div class="grid alignItemsEndSafe justifyItemsEndSafe" data-expected-width=
"300" data-expected-height="360"> | 112 <div class="grid fit-content alignItemsEndSafe justifyItemsEndSafe" data-exp
ected-width="300" data-expected-height="360"> |
200 <div class="cellOverflowWidth firstRowFirstColumn" data-offset-x="0" da
ta-offset-y="80" data-expected-width="180" data-expected-height="40"></div> | 113 <div class="cellOverflowWidth firstRowFirstColumn" data-offset-x="0" da
ta-offset-y="80" data-expected-width="180" data-expected-height="40"></div> |
201 <div class="cellWithNoOverflow secondRowFirstColumn justifySelfCenterUns
afe" data-offset-x="50" data-offset-y="200" data-expected-width="50" data-expect
ed-height="40"></div> | 114 <div class="cellWithNoOverflow secondRowFirstColumn justifySelfCenterUns
afe" data-offset-x="50" data-offset-y="200" data-expected-width="50" data-expect
ed-height="40"></div> |
202 <div class="cellWithNoOverflow thirdRowFirstColumn" data-offset-x="100"
data-offset-y="320" data-expected-width="50" data-expected-height="40"></div> | 115 <div class="cellWithNoOverflow thirdRowFirstColumn" data-offset-x="100"
data-offset-y="320" data-expected-width="50" data-expected-height="40"></div> |
203 <div class="cellWithNoOverflow firstRowSecondColumn" data-offset-x="250"
data-offset-y="80" data-expected-width="50" data-expected-height="40"></div> | 116 <div class="cellWithNoOverflow firstRowSecondColumn" data-offset-x="250"
data-offset-y="80" data-expected-width="50" data-expected-height="40"></div> |
204 <div class="cellOverflowWidth secondRowSecondColumn" data-offset-x="150
" data-offset-y="200" data-expected-width="180" data-expected-height="40"></div> | 117 <div class="cellOverflowWidth secondRowSecondColumn" data-offset-x="150
" data-offset-y="200" data-expected-width="180" data-expected-height="40"></div> |
205 <div class="cellWithNoOverflow thirdRowSecondColumn" data-offset-x="250"
data-offset-y="320" data-expected-width="50" data-expected-height="40"></div> | 118 <div class="cellWithNoOverflow thirdRowSecondColumn" data-offset-x="250"
data-offset-y="320" data-expected-width="50" data-expected-height="40"></div> |
206 </div> | 119 </div> |
207 </div> | 120 </div> |
208 | 121 |
209 <div style="position: relative"> | 122 <div style="position: relative"> |
210 <div class="grid alignItemsEndSafe justifyItemsEndSafe" data-expected-width=
"300" data-expected-height="360"> | 123 <div class="grid fit-content alignItemsEndSafe justifyItemsEndSafe" data-exp
ected-width="300" data-expected-height="360"> |
211 <div class="cellOverflowHeight firstRowFirstColumn" data-offset-x="100"
data-offset-y="0" data-expected-width="50" data-expected-height="150"></div> | 124 <div class="cellOverflowHeight firstRowFirstColumn" data-offset-x="100"
data-offset-y="0" data-expected-width="50" data-expected-height="150"></div> |
212 <div class="cellWithNoOverflow secondRowFirstColumn" data-offset-x="100"
data-offset-y="200" data-expected-width="50" data-expected-height="40"></div> | 125 <div class="cellWithNoOverflow secondRowFirstColumn" data-offset-x="100"
data-offset-y="200" data-expected-width="50" data-expected-height="40"></div> |
213 <div class="cellWithNoOverflow thirdRowFirstColumn" data-offset-x="100"
data-offset-y="320" data-expected-width="50" data-expected-height="40"></div> | 126 <div class="cellWithNoOverflow thirdRowFirstColumn" data-offset-x="100"
data-offset-y="320" data-expected-width="50" data-expected-height="40"></div> |
214 <div class="cellWithNoOverflow firstRowSecondColumn alignSelfCenterUnsaf
e" data-offset-x="250" data-offset-y="40" data-expected-width="50" data-expected
-height="40"></div> | 127 <div class="cellWithNoOverflow firstRowSecondColumn alignSelfCenterUnsaf
e" data-offset-x="250" data-offset-y="40" data-expected-width="50" data-expected
-height="40"></div> |
215 <div class="cellOverflowHeight secondRowSecondColumn" data-offset-x="250
" data-offset-y="120" data-expected-width="50" data-expected-height="150"></div> | 128 <div class="cellOverflowHeight secondRowSecondColumn" data-offset-x="250
" data-offset-y="120" data-expected-width="50" data-expected-height="150"></div> |
216 <div class="cellWithNoOverflow thirdRowSecondColumn" data-offset-x="250"
data-offset-y="320" data-expected-width="50" data-expected-height="40"></div> | 129 <div class="cellWithNoOverflow thirdRowSecondColumn" data-offset-x="250"
data-offset-y="320" data-expected-width="50" data-expected-height="40"></div> |
217 </div> | 130 </div> |
218 </div> | 131 </div> |
219 | 132 |
220 </body> | 133 </body> |
221 </html> | 134 </html> |
OLD | NEW |