Re: [csswg-drafts] [css-display] Display values for <br> and <wbr>

It does for now, but that spec “is a very rough draft, and is not 
ready for implementation” (cf its status section). By the time it 
matures, I expect it will no longer allow it, at least not without 
some syntax shenanigans, because of a major web compat problem.

The problem is that lots of sites who meant to write this something 
like this
```css
.clearfix::after {
     content: ".";
     visibility: hidden;
     display: block;
     clear: both;
     height: 0;
}
```
would instead write:
```css
.clearfix {
     content: ".";
     visibility: hidden;
     display: block;
     clear: both;
     height: 0;
}
```
Same thing without the `::after` pseudo. Of course, that does not 
work, but that does not prevent people from leaving it behind in their
 stylesheets. Some other part of the cascade overrides the 
`visibility`/`height` or whichever part of their variant of clearfix 
would break the site, but nothing stands in the way of the `content` 
property.

If we were to make `content` apply to elements, a non negligible part 
of the web would be replaced by "." or " " or ""...

I believe presto-based opera actually tried, and rolled it back 
because of that. I have not checked recently if that was still true, 
but I would be surprised if it had gone away. That would be a good 
surprise, but a surprise still.

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

Received on Wednesday, 25 January 2017 18:31:01 UTC