Add box-sizing support across the rendering pipeline so that width/height can refer to either the content-box (default) or the border-box (content + padding + border). This is one of the most commonly used CSS properties and is required by virtually every modern CSS reset. The implementation adjusts width/height resolution in block, flex, grid, and table layout engines, and defaults tables to border-box in the UA stylesheet to match Chrome/Firefox/Safari behavior. Five previously-failing WPT tests now pass and are promoted in the manifest. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
28 lines
454 B
HTML
28 lines
454 B
HTML
<!DOCTYPE html>
|
|
<html>
|
|
<head>
|
|
<style>
|
|
.content-box {
|
|
box-sizing: content-box;
|
|
width: 200px;
|
|
height: 100px;
|
|
padding: 10px;
|
|
border: 5px solid black;
|
|
background-color: #ccc;
|
|
}
|
|
.border-box {
|
|
box-sizing: border-box;
|
|
width: 200px;
|
|
height: 100px;
|
|
padding: 10px;
|
|
border: 5px solid black;
|
|
background-color: #aaa;
|
|
}
|
|
</style>
|
|
</head>
|
|
<body>
|
|
<div class="content-box">content-box</div>
|
|
<div class="border-box">border-box</div>
|
|
</body>
|
|
</html>
|