Page is a not externally linkable
Paul_o_b - 6:23 pm on Dec 3, 2011 (gmt 0)
It's certainly a bug because an element with zero width that has content of 400px width should still remain at zero width. The content should overflow the container as per the default (overflow:visible) and have no effect on surrounding content (except to overlap).
It looks like chrome has forgotten that the overflowing content was contained inside an element of zero width.
Actually, on testing again the bug is actually the zero width itself. If you change it to width:1px then chrome shrinks the parent to match. Change it to zero and the element expands.
Definately a bug :)
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>Untitled Document</title>
<style>
.tab{float:left;background:red;}
</style>
</head>
<body>
<div class="tab">
<div class="tab-button" style="cursor: pointer;"> <span>2011</span> </div>
<div class="tab-content" style="width: 1px;">
<p style="width:400px"> .... // content with a fixed width of 400px</p>
</div>
</div>
</body>
</html>
You should log a bug at the Chrome site or it won't get fixed.