Source code

Revision control

Copy as Markdown

Other Tools

Test Info:

<!DOCTYPE html>
<html>
<meta charset="utf-8">
<title>CSS Shape Test: float left, border-box, with margins</title>
<link rel="match" href="reference/shape-outside-border-box-with-margin-ref.html">
<meta name="assert" content="The float's inline start margin offsets the border-box shape, and its inline end margin is not part of the float area.">
<style>
.container {
width: 100px;
line-height: 0;
}
.shape {
float: left;
shape-outside: border-box;
width: 50px;
height: 100px;
margin: 0 25px;
background-color: orange;
}
.box {
display: inline-block;
width: 25px;
height: 25px;
background-color: blue;
}
</style>
<main class="container">
<div class="shape"></div>
<div><div class="box"></div><div class="box"></div><div class="box"></div><div class="box"></div></div>
</main>
</html>