ladybird/Tests/LibWeb/Layout/input/block-and-inline/float-fits-exactly.html
Ruben 3263b629c6 LibWeb: Correct the calculation for right float intrusion
We used to subtract the maximum right margin of any containing box,
but we want to subtract the entire right margin instead. This yielded
incorrect intrusions for right floats not placed in the root.
2025-05-27 17:31:47 +02:00

32 lines
437 B
HTML

<!DOCTYPE html>
<head>
<style>
.container {
width: 400px;
height: 50px;
border: 1px solid black;
}
.left {
float: left;
height: 50px;
}
.right {
float: right;
height: 50px;
}
.w320 { width: 320px; }
.w80 { width: 80px; }
.red { background: red; }
.blue { background: blue; }
</style>
</head>
<body>
<div class="container">
<div class="right w320 red"></div>
<div class="left w80 blue"></div>
</div>
</body>