Open josepharhar opened 1 month ago
Note in particular that the justification for :closed
is no longer valid with the current HTML PR. We did not want to make :closed
only match things that can be closed as this set of items might change over time.
Okay, if you purposely don't want to hook :closed to the "openability" of an element, then yeah, it's completely redundant with :not(:open)
and we probably shouldn't add it.
I am in favor of removing :closed
The CSS Working Group just discussed [selectors-4] Should we have :open and :closed?
.
I didn't type the RESOLVED fast enough before the topic was switched, but we resolved on removing :closed for now and keeping :open
It was resolved here to have both :open and :closed pseudo-classes: https://github.com/w3c/csswg-drafts/issues/7319#issuecomment-1276473056
@annevk mentioned here that :closed is redundant with :not(:open): https://github.com/WebKit/standards-positions/issues/413#issuecomment-2406663870
Here is the justification for having both of them: https://github.com/w3c/csswg-drafts/issues/7319#issuecomment-1242377579
The HTML spec has not been merged yet: https://github.com/whatwg/html/pull/10126