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

取消动画后无法恢复到初始状态 #1732

Open
Aarebecca opened this issue Jul 12, 2024 · 0 comments
Open

取消动画后无法恢复到初始状态 #1732

Aarebecca opened this issue Jul 12, 2024 · 0 comments

Comments

@Aarebecca
Copy link
Contributor

例如一个圆形,默认为红色,对该圆形执行动画:

const circle = new Circle({
  style: {
    cx: 300,
    cy: 200,
    r: 100,
    fill: 'red',
  },
});

const animation = circle.animate(
  [{ fill: 'blue' }, { fill: 'green' }],
  1000
);

animation.cancel();

期望调用 animation.cancel() 后图形重置为红色,而非蓝色

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