question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Animation numsteps wrong value

See original GitHub issue

Expected Behavior

The numsteps should be the duration of that animation and not the global one

Current Behavior

the short tooltip animation works but the onProgress callback in the animation block for the options reports back the main long duration.

V2 (correct behaviour): https://www.chartjs.org/samples/latest/advanced/progress-bar.html V3 (wrong behaviour): https://www.chartjs.org/samples/master/advanced/progress-bar.html

Context

Found this through another issue

Environment

  • Chart.js version: 3.0.0-beta.13 master
  • Browser name and version: Chrome Versie 88.0.4324.190 (Officiële build) (64-bits)
  • Link to your project:

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:6 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
etimbergcommented, Mar 10, 2021

Good question as to what the most correct behaviour is here. For example, what happens if the tooltip is configured such that the duration of the position change is 400ms, but the background color changes in 800ms. That’s essentially the case that I am seeing happen while debugging this sample. I see 15 different animations, 7 of which are active. Durations range from 2000ms to 200ms.

Active Duration Property From To
true 2000 'borderColor' 'rgb(255, 99, 132)' '#FF4069'
true 2000 'backgroundColor' 'rgb(255, 99, 132)' '#FF4069'
true 2000 'radius' 3 4
false 2000 'borderWidth' 1 1
true 2000 'borderColor' 'rgb(54, 162, 235)' #059BFF'
true 2000 'backgroundColor' 'rgb(54, 162, 235)' '#059BFF'
true 2000 'radius' 3 4
false 2000 'borderWidth' 1 1
false 400 'caretY' 348.107 348.107
false 400 'caretX' `40.76 40.76
false 400 'height' 56 56
false 400 'width' 168 168
false 400 'x' 320.107 320.107
false 400 'y' 47.76 47.76
true 200 'opacity' 0 1
0reactions
kurklecommented, Mar 11, 2021

I think there is actually some other issue here, the duration might be wrong on those 2000ms animations when hovered.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Animation numsteps wrong value · Issue #8613 · chartjs/Chart.js
Expected Behavior. The numsteps should be the duration of that animation and not the global one. Current Behavior.
Read more >
Animations | Chart.js
Disabling animation. To disable an animation configuration, the animation node must be set to false , with the exception for animation modes ...
Read more >
Chart.js - How to show loading animation before plotting chart
I want to display loading before plotting chart. I have tried following but nothing is happening. Here it is showing jQuery error: Uncaught...
Read more >
animation - CSS: Cascading Style Sheets - MDN Web Docs
Determines whether the animation is playing or not. The value must be one of those available in animation-play-state .
Read more >
Animations – amCharts 4 Documentation
This will automatically enable all animations in all the places that matter. Here's a basic chart with Animated theme enabled: HTML; CSS; JS....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found