Re: [csswg-drafts] [css-scoping-1] Clarify exactly what :host(<sel>) can use as argument (#7953)

They're related, but not exactly the same.

Consider a case like:

```css
:host(:not(:has(input:checked))) {
  border: solid 4px red;
}
```

meant to be used with markup like:

```html
<my-element>
  <section>
    <label>One: <input type="checkbox" name="one"></label>
    <label>Two: <input type="checkbox" name="two"></label>
    <label>Three: <input type="checkbox" name="three"></label>
  </section
</my-element>
```

`:has-slotted()` (which is great and needed! I've been asking for it [here](https://github.com/WICG/webcomponents/issues/936)) can match a slot, but we'd still need two things: 1) a way to match a host that has a slot with assigned nodes, and 2) for `:has()` to work inside `:has-slotted()`, like `:not(:has-slotted(:has(input:checked)))`.

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


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

Received on Wednesday, 28 December 2022 20:54:15 UTC