blob: 523bcb8e8a21d0e4cc9dafe5c9105c09dd617db2 [file] [log] [blame]
<!DOCTYPE html>
<html>
<style>
.flexbox {
display: -webkit-flex;
background-color: #aaa;
position: relative;
}
.flexbox :nth-child(1) {
background-color: blue;
}
.flexbox :nth-child(2) {
background-color: green;
}
.flexbox :nth-child(3) {
background-color: red;
}
.flexbox > div {
width: 40%;
height: 40%;
}
.column {
-webkit-flex-flow: column wrap;
width: 100px;
height: 100px;
-webkit-align-content: flex-start;
}
</style>
<script src="../../resources/check-layout.js"></script>
<body onload="checkLayout('.flexbox')">
<div class="flexbox column">
<div data-expected-height="40" data-offset-x="0" data-offset-y="0"></div>
<div data-expected-height="40" data-offset-x="0" data-offset-y="40"></div>
<div data-expected-height="40" data-offset-x="40" data-offset-y="0"></div>
</div>
<div class="flexbox column">
<div data-expected-height="40" data-offset-x="0" data-offset-y="0" style="margin-bottom: 10%"></div>
<div data-expected-height="40" data-offset-x="40" data-offset-y="0" style="margin-bottom: 20%"></div>
<div data-expected-height="40" data-offset-x="40" data-offset-y="60"></div>
</div>
<div class="flexbox column">
<div data-expected-height="20" data-offset-x="0" data-offset-y="0" style="-webkit-flex: 1; min-height: 0; max-height: 20%"></div>
<div data-expected-height="40" data-offset-x="0" data-offset-y="20"></div>
<div data-expected-height="40" data-offset-x="0" data-offset-y="60"></div>
</div>
<div class="flexbox column" style="-webkit-writing-mode: vertical-rl">
<div data-expected-width="40" data-offset-x="60" data-offset-y="0"></div>
<div data-expected-width="40" data-offset-x="20" data-offset-y="0"></div>
<div data-expected-width="40" data-offset-x="60" data-offset-y="40"></div>
</div>
<div class="flexbox column" style="-webkit-writing-mode: vertical-rl">
<div data-expected-width="40" data-offset-x="60" data-offset-y="0" style="margin-bottom: 10%"></div>
<div data-expected-width="40" data-offset-x="20" data-offset-y="0" style="margin-bottom: 20%"></div>
<div data-expected-width="40" data-offset-x="60" data-offset-y="60"></div>
</div>
<div class="flexbox column" style="-webkit-writing-mode: vertical-rl">
<div data-expected-width="20" data-offset-x="80" data-offset-y="0" style="-webkit-flex: 1; min-width: 0; max-width: 20%"></div>
<div data-expected-width="40" data-offset-x="40" data-offset-y="0"></div>
<div data-expected-width="40" data-offset-x="0" data-offset-y="0"></div>
</div>
</body>
</html>