[Bug 19277] Relationship and precedence of hidden="" and display:none should be clarified/defined

https://www.w3.org/Bugs/Public/show_bug.cgi?id=19277

--- Comment #31 from James Craig <jcraig@apple.com> ---
(In reply to Leif Halvard Silli from comment #29)
> I think that one option could as well be to say that it is *not* an author
> error to make hidden visible.
> 
> Perhaps @hidden should only relly mean that the element *defaults* to be
> hidden? That would be an unambiguous thing/statement, would it not?

But as currently specified/implemented, it's too easy to accidentally override
this default with an author style that provides a higher specificity. For
example:

main ul.searchresults > li {
  display: table-row;
}

Would prevent [hidden] from working on those list items. Adding !important to
the default UA style sheet does not prevent authors from overriding the
display, it just makes it so that they are less likely to do so accidentally.

*[hidden] {
  display: none !important;
}

-- 
You are receiving this mail because:
You are on the CC list for the bug.

Received on Wednesday, 11 December 2013 01:47:59 UTC