Re: [whatwg] hidden attribute useless with display: flex?

Ok, sorry, I was pissed off... The web platform triggers this sort of 
reactions sometimes :-)

Constructive proposal:
* a special value for the hidden attribute that forces the element to be 
hidden regardless of what the CSS or style attribute says for the 
display value.
Maybe `hidden="force"`?

This might break existing website which would use the "force" value, but 
since it had no special meaning currently and there is no good reason to 
use this value, I'd say the odds are very low.

Any implementor interested?

David

Le 29/04/2014 23:32, David Bruant a écrit :
> Hi,
>
> // CSS:
> div{
>   display: flex;
> }
>
> // HTML:
> <div hidden></div>
>
> Per spec, the div should be shown right? I imagine there is no way 
> back on that?
> Does it mean hidden only works when the default (UA stylesheet) 
> display value is kept? Does it mean hidden is completely useless when 
> trying to combine it with display:flex?
>
> What I'm trying to do is just that an element have display:flex and to 
> hide it with the hidden attribute when I don't need the element to be 
> shown. I guess my only option is changing style.display?
>
> Thanks,
>
> David

Received on Wednesday, 30 April 2014 09:42:11 UTC