|
1 <!DOCTYPE html> |
|
2 <!-- Any copyright is dedicated to the Public Domain. |
|
3 http://creativecommons.org/publicdomain/zero/1.0/ --> |
|
4 <!-- Testcase for how we fragment a flex container with a single unbreakable |
|
5 child, with the flex container having "flex-direction: column". |
|
6 --> |
|
7 <html> |
|
8 <head> |
|
9 <style> |
|
10 .multicol { |
|
11 height: 10px; |
|
12 width: 100px; |
|
13 -moz-column-width: 20px; |
|
14 -moz-column-fill: auto; |
|
15 border: 2px solid orange; |
|
16 margin-bottom: 15px; /* (just for spacing between testcases) */ |
|
17 } |
|
18 .flexContainer { |
|
19 display: flex; |
|
20 flex-direction: column; |
|
21 background: teal; |
|
22 border: 1px dashed black; |
|
23 } |
|
24 .item { |
|
25 width: 100%; |
|
26 height: 20px; |
|
27 flex: none; |
|
28 } |
|
29 </style> |
|
30 </head> |
|
31 <body> |
|
32 <!-- auto-height container: --> |
|
33 <div class="multicol"> |
|
34 <div class="flexContainer"> |
|
35 <img src="" class="item"> |
|
36 </div> |
|
37 </div> |
|
38 |
|
39 <!-- fixed-height container, smaller than available height: --> |
|
40 <div class="multicol"> |
|
41 <div class="flexContainer" style="height: 8px"> |
|
42 <img src="" class="item"> |
|
43 </div> |
|
44 </div> |
|
45 |
|
46 <!-- fixed-height container, between available height and child height: --> |
|
47 <div class="multicol"> |
|
48 <div class="flexContainer" style="height: 15px"> |
|
49 <img src="" class="item"> |
|
50 </div> |
|
51 </div> |
|
52 |
|
53 <!-- fixed-height container, same as child height: --> |
|
54 <div class="multicol"> |
|
55 <div class="flexContainer" style="height: 20px"> |
|
56 <img src="" class="item"> |
|
57 </div> |
|
58 </div> |
|
59 |
|
60 <!-- fixed-height container, larger than child height: --> |
|
61 <div class="multicol"> |
|
62 <div class="flexContainer" style="height: 24px"> |
|
63 <img src="" class="item"> |
|
64 </div> |
|
65 </div> |
|
66 </body> |
|
67 </html> |