Re: [csswg-drafts] [selectors-4] :valid-within / :invalid-within pseudo-classes

The validity pseudoselectors are already [spec'd to apply to `<fieldset>`](https://html.spec.whatwg.org/multipage/semantics-other.html#selector-valid), which can be used as a generic grouping element within a form. That seems to be supported everywhere that [supports the selectors on `<form>`](https://developer.mozilla.org/en-US/docs/Web/CSS/:invalid#Browser_compatibility) (confirmed in Firefox & Chrome). ([Codepen test case](https://codepen.io/AmeliaBR/pen/wYjKEL))

Beyond that, I'd much rather see [the generic `:has()` selector](https://www.w3.org/TR/selectors-4/#relational) get adopted rather than an ever-growing set of `:something-within` selectors.

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

Received on Thursday, 18 October 2018 21:43:50 UTC