forked from burg/timelapse
/
floated-flexbox.html
34 lines (31 loc) · 1 KB
/
floated-flexbox.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
<!DOCTYPE html>
<html>
<style>
.flexbox {
display: -webkit-flex;
background-color: #aaa;
border: 5px solid blue;
float:left;
}
.flexbox :nth-child(1) {
background-color: salmon;
}
.flexbox :nth-child(2) {
background-color: lime;
}
</style>
<script src="../../resources/check-layout.js"></script>
<body onload="checkLayout('.flexbox')">
<div data-expected-width=130 data-expected-height=30 class=flexbox>
<div style="background-color:pink; width: 20px; height: 20px;"></div>
<div style="background-color:red; width: 100px; height: 20px;"></div>
</div>
<div style="clear: left; position: relative">
<div style="width: 100px; height: 100px; background-color: green; float: left"></div>
<div data-expected-height=30 data-offset-x=100 data-offset-y=0 class="flexbox" style="float: none">
<div data-expected-height=20 data style="height: 20px; -webkit-flex: 1"></div>
<div data-expected-height=20 style="height: 20px; -webkit-flex: 1"></div>
</div>
</div>
</body>
</html>