polyfills
polyfills copied to clipboard
[ShadyCSS] Selectors for slot element does not work
Selectors like .foo .classy-slot::slotted(*) does not work.
Steps to reproduce
-
Define custom element as Shadow DOM per element is not supported,
-
Create Shadow Root.
-
Add
<slot>element with a class on it, -
Add
<style>element that (according to the README)have a selector to the left of the ::slotted pseudo-element.
Precisely have a selector for the
slotelement itself, like.foo slot.bar::slotted(*) -
Create an instance of this element (shadow host), add a child element inside.
Expected behavior
The selector should match child element, and apply rules to it.
Actualbehavior
The rules are not applied
Live example
https://jsbin.com/yayoyaw/edit?html,output