blob: 0cdb4c22bdf5155793f94e40f5acebe648bb1a2c [file] [log] [blame]
<!DOCTYPE html>
| It should be possible to have children inside an inline-block box that
| both define and depend on the width of the parent box.
body {
margin: 0px;
color: #fff;
font-family: Roboto;
font-size: 50px;
font-weight: bold;
.inline-block {
background-color: #2196f3;
display: inline-block;
.percentage-width {
background-color: #3f51b5;
height: 50px;
width: 50%;
.spacer {
height: 5px;
<div class="inline-block">
<div class="percentage-width"></div>
<div class="spacer"></div>
<div class="inline-block">
<div class="percentage-width">there!</div>