Merge pull request 'does it even matter?' (!286) from number-omit into main
Reviewed-on: #286 Reviewed-by: Jan K9f <jan@kjan.email>
This commit is contained in:
commit
4644e5cecc
1 changed files with 3 additions and 0 deletions
|
@ -61,6 +61,9 @@ export class AnimatedNumberComponent implements OnChanges, AfterViewInit {
|
||||||
this.countUp = new CountUp(this.numberElement.nativeElement, this.value, {
|
this.countUp = new CountUp(this.numberElement.nativeElement, this.value, {
|
||||||
startVal: this.previousValue,
|
startVal: this.previousValue,
|
||||||
duration: this.duration,
|
duration: this.duration,
|
||||||
|
decimalPlaces: 2,
|
||||||
|
useEasing: true,
|
||||||
|
useGrouping: false,
|
||||||
easingFn: (t, b, c, d) => {
|
easingFn: (t, b, c, d) => {
|
||||||
if (this.ease === 'power1.out') {
|
if (this.ease === 'power1.out') {
|
||||||
return c * (1 - Math.pow(1 - t / d, 1)) + b;
|
return c * (1 - Math.pow(1 - t / d, 1)) + b;
|
||||||
|
|
Reference in a new issue