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

雷达图重新执行render()无法触发动画效果 #3695

Closed
1 task
dushiying opened this issue Oct 26, 2021 · 1 comment
Closed
1 task

雷达图重新执行render()无法触发动画效果 #3695

dushiying opened this issue Oct 26, 2021 · 1 comment

Comments

@dushiying
Copy link

  • I have searched the issues of this repository and believe that this is not a duplicate.

Reproduction link

https://g2.antv.vision/zh/examples/radar/radar#basic

Steps to reproduce


chart
  .line()
  .position('item*score')
  .color('user')
  .size(2)
  .animate({
  appear: {
    animation: 'path-In', // 动画名称
    easing: 'easeQuadIn', // 动画缓动效果
    duration: 3000 // 动画执行时间
  }
});
  
chart
  .point()
  .position('item*score')
  .color('user')
  .shape('circle')
  .size(4)
  .style({
    stroke: '#fff',
    lineWidth: 1,
    fillOpacity: 1,
  })
chart
  .area()
  .position('item*score')
  .color('user')
  .animate({
  appear: {
    animation: 'zoom-in', // 动画名称
    easing: 'easeQuadIn', // 动画缓动效果
    duration: 6000 // 动画执行时间
  }
});

// 通过定时器定时重新触发动画效果但是无效果
chart.render();
      const welcomeTimer = setInterval(() => {
            chart.render();
}, 10000)
Environment Info
g2 4.1.32
System windows10
Browser chrome
@hustcc
Copy link
Member

hustcc commented Jun 22, 2022

我这里是 ok 的,是不是你设置的 timer 是 10s,你以为是 1s?


Jun-22-2022 13-42-57

@hustcc hustcc closed this as completed Jun 22, 2022
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

2 participants