]> _ Git - fluidbook-html5.git/commitdiff
wait #6423 @0.25
authorVincent Vanwaelscappel <vincent@cubedesigners.com>
Wed, 8 Nov 2023 07:16:21 +0000 (08:16 +0100)
committerVincent Vanwaelscappel <vincent@cubedesigners.com>
Wed, 8 Nov 2023 07:16:21 +0000 (08:16 +0100)
js/libs/fluidbook/fluidbook.links.js

index 7e562b184a324b181ca8ec4911eb3ef99e25a9b4..e175bf4a5504e4a0a1e9d0b0d40707e4a17fc49a 100644 (file)
@@ -1053,7 +1053,13 @@ FluidbookLinks.prototype = {
 
             css['opacity'] = 0;
 
-            var value = parseFloat(link.text().replace(/,/, '.'));
+            let value;
+            if ($(link).data('anim-numeric-value') === null || $(link).data('anim-numeric-value')===undefined) {
+                value = parseFloat(link.text().replace(/,/, '.'));
+                $(link).data('anim-numeric-value', value);
+            } else {
+                value = $(link).data('anim-numeric-value');
+            }
             link.text('');
             var countup = new CountUp(link.attr('id'), value, options);
             setTimeout(function () {