<!DOCTYPE html> | |
<!-- | |
| The "width" property does not apply. | |
| https://www.w3.org/TR/CSS21/visudet.html#inline-width | |
--> | |
<html> | |
<head> | |
<style> | |
.non-replaced-inline { | |
background-color: #f44336; | |
display: inline; | |
width: 100px; | |
} | |
.vertical-strut { | |
display: inline-block; | |
height: 100px; | |
} | |
</style> | |
</head> | |
<body> | |
<span class="non-replaced-inline"> | |
<div class="vertical-strut"></div> | |
</span> | |
</body> | |
</html> |