antvis / antvis/G

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

Open
#1,732 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
1.2k
Forks
230
PR merge metrics
No merged PRs in 30d

Description

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

```ts
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()` 后图形重置为红色,而非蓝色

Contributor guide

Open the contributing guide

Research direction

Start by reproducing the Circle.animate example and trace the animation.cancel() entry point in the animation subsystem. Confirm the behavior after cancellation and adjust the relevant handling so the circle returns to its original red fill instead of remaining blue.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
computer-graphics
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.