RESOLVED DUPLICATE of bug 102344 105404
[Shadow DOM]: Wrong type of CSSRule when @Host rule is used
https://bugs.webkit.org/show_bug.cgi?id=105404
Summary [Shadow DOM]: Wrong type of CSSRule when @Host rule is used
Sergey G. Grekhov
Reported 2012-12-19 01:36:32 PST
When @Host rule is used not in shadow root then CSSRule object returned by cssRules property, not CSSHostRule Chrome 25.0.1364.0 canary. Test: <html> <head> <script type="text/javascript"> function test() { var d = document; var host = d.createElement('div'); d.body.appendChild(host); var style = d.createElement('style'); style.innerHTML = '' + 'span { color: blue; }' + '@host {' + 'div { color: red; }' + '}'; d.head.appendChild(style); alert('Expected 1001, actual ' + d.styleSheets[0].cssRules[1].type); } </script> </head> <body onload="test()"> </body> </html>
Attachments
Takashi Sakamoto
Comment 2 2012-12-19 03:07:26 PST
Hello, Since CSSHostRule has not been implemented yet, currently CSSUnknownRule is used instead. I'm now trying to fix this issue on bug 102344. Best regards, Takashi Sakamoto *** This bug has been marked as a duplicate of bug 102344 ***
Note You need to log in before you can comment on or make changes to this bug.