gecko-dev/testing/web-platform/tests/css/CSS2/floats/zero-width-floats.html
Morten Stenshorne c5582233ef Bug 1438515 [wpt PR 9538] - [LayoutNG] Don't add zero-width floats to the exclusion space., a=testonly
Automatic update from web-platform-tests[LayoutNG] Don't add zero-width floats to the exclusion space.

The only thing such floats should affect is the block position of
subsequent floats (float rule ยง5 [1] and clearance). They should not
affect the inline position or inline size of subsequent floats or new
formatting contexts.

The spec isn't actually clear here, although the browsers agree on the
above. Submitted https://github.com/w3c/csswg-drafts/issues/2312

[1] https://www.w3.org/TR/CSS22/visuren.html#float-position

Cq-Include-Trybots: master.tryserver.chromium.linux:linux_layout_tests_layout_ng
Change-Id: Ia9e724c8a58fcb017f86f26bdf90394f09414f4e
Reviewed-on: https://chromium-review.googlesource.com/919065
Reviewed-by: Ian Kilpatrick <ikilpatrick@chromium.org>
Commit-Queue: Morten Stenshorne <mstensho@chromium.org>
Cr-Commit-Position: refs/heads/master@{#537274}

wpt-commits: ae06fa4ce5d170f7f34e979b014315e318344ec4
wpt-pr: 9538
wpt-commits: ae06fa4ce5d170f7f34e979b014315e318344ec4
wpt-pr: 9538
2018-03-31 22:22:26 +01:00

12 lines
798 B
HTML

<!DOCTYPE html>
<title>Zero width floats</title>
<link rel="author" title="Morten Stenshorne" href="mstensho@chromium.org">
<link rel="help" href="https://www.w3.org/TR/CSS22/visudet.html#float-width" title="10.3.5 Floating, non-replaced elements">
<link rel="match" href="../../reference/ref-filled-green-200px-square.html">
<p>Test passes if there is a filled green square and <strong>no red</strong>.</p>
<div style="margin-left:50px; width:100px;">
<div style="float:left; width:0; height:50px;"></div>
<div style="float:right; clear:left; width:0; height:150px;"></div>
<div style="overflow:hidden; margin:0 -50px; height:100px; background:green;"></div>
</div>
<div style="position:relative; top:-100px; overflow:hidden; clear:both; width:200px; height:100px; background:green;"></div>