Re: [csswg-drafts] [CSS2] How do zero-width floats affect subsequent content (#2312)

As I see it, it's still possible to overlap a float even if it has an area of 0. Along the same lines, #5641 said that boxes with an area of 0 can intersect the viewport.

It's worth noting that there are some browser differences depending on which dimension is 0:

```html
<!DOCTYPE html>
<div style="margin-left:50px; width:100px;">
  <div style="float:left; width:0px; height:50px; outline:solid red"></div>
  <div style="float:right; width:0px; height:50px; outline:solid red;"></div>
  <div style="float:left; clear:both; width:25px; height:0px; outline:solid green"></div>
  <div style="float:right; clear:both; width:25px; height:0px; outline:solid green;"></div>
  <div style="float:left; width:0px; height:50px; outline:solid blue"></div>
  <div style="float:right; width:0px; height:50px; outline:solid blue;"></div>
  <div style="overflow:hidden; width:200px; margin:0 -50px; height:150px; background:cyan;"></div>
</div>
```

| Gecko, WebKit | Blink | Spec |
| - | - | - |
| ![](https://github.com/w3c/csswg-drafts/assets/7477678/e7993bc6-f47f-4ed3-8e0c-6de2748f6772) | ![](https://github.com/w3c/csswg-drafts/assets/7477678/076f7458-cce0-47f2-91cb-707d9628756d) | ![](https://github.com/w3c/csswg-drafts/assets/7477678/42ada657-57d6-4647-9245-b36c989a385c) |

-- 
GitHub Notification of comment by Loirooriol
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/2312#issuecomment-1670425930 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Tuesday, 8 August 2023 23:03:18 UTC