Re: [WICG/webcomponents] CSS Shadow Parts Selector ::part() does not work in combination with :disabled pseudo-class in Chrome (#918)

Documenting this here because most searches end up here.

There is more to this. ``:disabled`` also breaks **grouped CSS** in Chromium. 

Have added this to the Chromium bug report: https://issues.chromium.org/issues/40623497

````
<button-hover>
  <template shadowrootmode="open">
    <button part="button_hover">:hover</button>
  </template>
</button-hover>
<style>
  button-hover::part(button_hover):hover {
    outline: 5px dashed green;
  }
  button-hover::part(button_hover):disabled,
  button-hover::part(button_hover):hover {
    background: lightgreen; /* not applied in Chromium, works fine in FireFox
  }
</style>
````

-- 
Reply to this email directly or view it on GitHub:
https://github.com/WICG/webcomponents/issues/918#issuecomment-2254096191
You are receiving this because you are subscribed to this thread.

Message ID: <WICG/webcomponents/issues/918/2254096191@github.com>

Received on Saturday, 27 July 2024 09:48:17 UTC