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

Not setting animation speed results in broken animations #57

Open
mikolajpp opened this issue Apr 6, 2018 · 0 comments
Open

Not setting animation speed results in broken animations #57

mikolajpp opened this issue Apr 6, 2018 · 0 comments

Comments

@mikolajpp
Copy link

I had this code:

Animation.interrupt
                [ Animation.loop
                    [ Animation.to
                        [ Animation.rotate (Animation.turn 1) ]
                    , Animation.set [ Animation.rotate <| Animation.turn 0 ]
                    ]
                ]
                model.style

For a little spinner. The above results in one correct animation, and afterwards animations
spinner only abruptly resets itself to 0 in jumps.

Using this:

  Animation.interrupt
                [ Animation.loop
                    [ Animation.toWith (Animation.speed { perSecond = 1 })
                        [ Animation.rotate (Animation.turn 1) ]
                    , Animation.set [ Animation.rotate <| Animation.turn 0 ]
                    ]
                ]
                model.style

(Note we set animation speed)
fixes the problem.

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

No branches or pull requests

1 participant