This commit is contained in:
salam committed 2026-06-15 11:16:05 +02:00
1 parent 208a27266a
commit 5a7e118f80
1 file changed
+9 -7
+9 -7
View File
@@ -21,13 +21,15 @@ function animate(element, end, duration = 500, fixtotwo) {
// Calculate current value and round to integer // Calculate current value and round to integer
const currentCount = Math.round(end * easedProgress * 100) / 100; const currentCount = Math.round(end * easedProgress * 100) / 100;
if (fixtotwo) { element.innerHTML = currentCount.toFixed(2);
console.log("fix2");
element.innerHTML = currentCount.toFixed(2); // if (fixtotwo) {
} else { // console.log("fix2");
console.log("fixNone"); // element.innerHTML = currentCount.toFixed(2);
element.innerHTML = currentCount; // } else {
} // console.log("fixNone");
// element.innerHTML = currentCount;
// }
if (progress < 1) { if (progress < 1) {
requestAnimationFrame(updateCount); requestAnimationFrame(updateCount);