Skip to content

Loading…

Style shim only converts a single ::shadow or /deep/ in a selector #1809

Closed
jyasskin opened this Issue · 1 comment

2 participants

@jyasskin

See http://plnkr.co/edit/DCLtFWbGN0RrIDVSikrB?p=preview for an example. Only the first ::shadow or /deep/ is getting removed from the style rules. On Chrome (with native support for /deep/, that means the background color gets stuck after the first nesting level. On Firefox, both the foreground and background colors get stuck there.

    li { color: red; }
    li ol::shadow li { color: blue; }
    li ol::shadow li ol::shadow li { color: green; }
    li { background-color: lightblue; }
    li /deep/ li { background-color: lightgreen; }
    li /deep/ li /deep/ li { background-color: pink; }

in the custom element stylesheet becomes the following in the document stylesheet:

li.dom-recurse {  color: red;}
li.dom-recurse ol.dom-recurse  li {  color: blue;}
li.dom-recurse ol.dom-recurse  li ol::shadow li {  color: green;}
li.dom-recurse {  background-color: lightblue;}
li.dom-recurse   li {  background-color: lightgreen;}
li.dom-recurse   li /deep/ li {  background-color: pink;}
@sorvell sorvell added the p2 label
@sorvell sorvell self-assigned this
@sorvell sorvell added p1 and removed p2 labels
@sorvell sorvell referenced this issue from a commit
@sorvell sorvell Fixes #1668
Fixes #1807
Fixes #1809
c339c4d
@sorvell
Owner

Please note that ::shadow and /deep/ are being removed from the cross scope styling spec. They may become deprecated in Chrome soon.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.