Re: [csswg-drafts] [selectors] Shouldn't there be a pseudo selector for `:unchecked` inputs? (#10746)

I won't be around for this discussion, so just commenting here: sounds fine to me? The point that we have a bunch of boolean pseudo pairs does suggest a pattern we should maintain for author convenience. We *can* target the same set of elements using `:not()`, since the set of elements `:checked` can apply to are very limited in the first place; `input[type="checkbox"]:not(:checked)` (or `[type="radio"]`), but granted that's pretty long. ^_^

I was going to say something about `ElementInternals` and form-associated custom elements, but it seems that that API doesn't currently have a way to associate an element with `:checked` anyway. That might be something we should think about in the future; if we do add such an API, it will need to be able to distinguish between checked/unchecked and not checkable. (It'll already need to be a multi-state concept anyway, to handle `:indeterminate`.) Anyway, that's a tangent and not germane to this issue.

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


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

Received on Monday, 23 September 2024 16:36:05 UTC