Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Missing '@' in Shadow DOM @keyframes CSS #840

Closed
mattdsteele opened this issue Sep 12, 2017 · 1 comment · Fixed by #845
Closed

Missing '@' in Shadow DOM @keyframes CSS #840

mattdsteele opened this issue Sep 12, 2017 · 1 comment · Fixed by #845
Labels

Comments

@mattdsteele
Copy link

mattdsteele commented Sep 12, 2017

Hi! Thanks for your help with #821. I have an issue in the same repo; I'm noticing the CSS keyframe animation isn't working - it appears the CSS is stripping off the @ in @keyframes, at least when I compile it to a custom element.

Authored CSS:

@keyframes creepy {
    0% { 
      transform: translateX(20px) translateY(20px); 
    }
    25% { 
      transform: translateX(20px) translateY(0); 
    }
    50% { 
      transform: translateX(10px) translateY(10px); 
    }
    100% {
      transform: translateX(0) translateY(0); 
    }
}

Output:

_this.shadowRoot.innerHTML = "<style>img{max-height:100%;max-width:50%;position:fixed;bottom:0;right:0;animation:creepy 3s infinite alternate ease-in-out}:host{display:block}keyframes creepy{0%{transform:translateX(20px) translateY(20px)}25%{transform:translateX(20px) translateY(0)}50%{transform:translateX(10px) translateY(10px)}100%{transform:translateX(0) translateY(0)}}</style>";

I'm wondering if it's related to #712?

Rich-Harris added a commit that referenced this issue Sep 12, 2017
Rich-Harris added a commit that referenced this issue Sep 13, 2017
@Rich-Harris
Copy link
Member

Thanks — this is fixed in 1.39.2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants