[csswg-drafts] [css-shadow-parts-1] Does @keyframes rule match in ::parts()?

TakayoshiKochi has just created a new issue for https://github.com/w3c/csswg-drafts:

== [css-shadow-parts-1] Does @keyframes rule match in ::parts()? ==
Context: https://crbug.com/724975
Spec: https://tabatkins.github.io/specs/css-shadow-parts/

Suppose we have the following style in document:
```css
@keyframes test {
  to { transform: rotate(360deg); }
}

#host::part(label) {
  animation: test infinite 1s;
}
```

Does this work, or this should not work?
Specifically, will `animation: test` apply to the `::part(label)`?

In today's Blink implementation, it does not.
For pseudo elements implemented inside UA shadow (e.g. `::-webkit-slider-thumb`, or `input::placeholder`), as the keyframe rule name lookup is scoped, and the selector and the element are in the different trees, `test` keyframe rule name lookup fails and thus the animation will not be applied.

For these elements, which are implemented within UA shadow DOM, it is just an implementation detail and maybe Blink should apply the `test` keyframe rule to those, but for `::part()`, the actual element would be in shadow DOM, and clarification is needed.

Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/1516 using your GitHub account

Received on Friday, 9 June 2017 09:11:41 UTC