Source code

Revision control

Copy as Markdown

Other Tools

Test Info:

<!DOCTYPE html>
<link rel="match" href="scrollbar-container-units-block-ref.html">
<style>
.container {
display: inline-block;
border: solid 3px cornflowerblue;
width: 100px;
height: 100px;
container-type: size;
}
div > div {
box-sizing: border-box;
width: 200px;
height: 100cqh;
border: solid 10px orange;
}
</style>
<div class="container" style="overflow-x: scroll;">
<div></div>
</div>
<div class="container" style="overflow-x: auto;">
<div></div>
</div>