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

Animations in scoped style blocks are broken #3304

Closed
mvsde opened this issue Feb 25, 2021 · 2 comments · Fixed by #3308
Closed

Animations in scoped style blocks are broken #3304

mvsde opened this issue Feb 25, 2021 · 2 comments · Fixed by #3308
Labels
🔨 p3-minor-bug Priority 3: this fixes a bug, but is an edge case that only affects very specific usage. 🐞 bug Something isn't working scope: compiler

Comments

@mvsde
Copy link

mvsde commented Feb 25, 2021

Version

3.0.6

Reproduction link

https://github.com/mvsde/vue-3.0.6-scoped-animations

Steps to reproduce

  1. Run the test project with npm run serve.
  2. Open the dev server URL in a browser.
  3. Observe the two colored boxes.

What is expected?

Both colored boxes rotate (works in 3.0.5).

What is actually happening?

Only the box with unscoped styles rotates.


The generated CSS looks like this. Note the "scoped" keyframe:

@keyframes rotate-scoped-341d6b1f {
  to[data-v-341d6b1f] {
    transform: rotate(1turn)
  }
}
@CarterLi
Copy link
Contributor

CarterLi commented Mar 2, 2021

This issue broke my code. Could you please fix it ASAP?

@mika76
Copy link

mika76 commented Mar 2, 2021

@CarterLi watch #3308 - but in the meantime put the keyframes definitions in their own non-scoped <style> tag. Should solve your issue for the moment.

yyx990803 pushed a commit that referenced this issue Mar 19, 2021
@github-actions github-actions bot locked and limited conversation to collaborators Oct 24, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
🔨 p3-minor-bug Priority 3: this fixes a bug, but is an edge case that only affects very specific usage. 🐞 bug Something isn't working scope: compiler
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants