<!DOCTYPE html> <!-- webkit-test-runner [ LayoutFormattingContextEnabled=true InlineFormattingContextIntegrationEnabled=false ] --> | |
<style> | |
.container { | |
width: 100px; | |
height: 100px; | |
} | |
.floatBox { | |
float: left; | |
width: 40px; | |
height: 100px; | |
background-color: green; | |
} | |
.floatAvoider { | |
overflow: hidden; | |
height: 100%; | |
background-color: blue; | |
max-width: 10%; | |
} | |
</style> | |
<div class=container> | |
<div class=floatBox></div> | |
<div class=floatAvoider></div> | |
</div> |