Skip to content

Commit 71f6988

Browse files
committed
Modification - VueUiDonut - Remove commented code
1 parent 1cc4553 commit 71f6988

File tree

1 file changed

+14
-21
lines changed

1 file changed

+14
-21
lines changed

src/components/vue-ui-donut.vue

Lines changed: 14 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -183,13 +183,6 @@ const resizeAndReflow = () => {
183183
sizeRef.value = final;
184184
});
185185
});
186-
187-
// if (FINAL_CONFIG.value.autoSize && G_hollow.value && circle_hollow.value) {
188-
// setOpacityIfWithinBBox({
189-
// el: G_hollow.value,
190-
// container: circle_hollow.value,
191-
// });
192-
// }
193186
});
194187
}
195188
@@ -450,13 +443,13 @@ function animateWithGhost(finalValues, duration = 1000, stagger = 50) {
450443
animatedValues.value = [...animatedValues.value];
451444
if (p < 1) {
452445
requestAnimationFrame(animate);
453-
requestAnimationFrame(resizeAndReflow)
446+
requestAnimationFrame(resizeAndReflow);
454447
} else {
455448
animatedValues.value[i] = target;
456449
animatedValues.value = [...animatedValues.value];
457450
completed += 1;
458451
if (completed === N) resolve();
459-
requestAnimationFrame(resizeAndReflow)
452+
requestAnimationFrame(resizeAndReflow);
460453
}
461454
}
462455
requestAnimationFrame(animate);
@@ -477,17 +470,17 @@ watch(
477470
const startAnimation = FINAL_CONFIG.value.startAnimation?.show;
478471
479472
if (!isSkeleton && startAnimation) {
480-
hasAnimated.value = true;
473+
hasAnimated.value = true;
481474
482-
const finalValues = FINAL_DATASET.value.map(ds =>
483-
ds.values.reduce((a, b) => a + b, 0)
484-
);
475+
const finalValues = FINAL_DATASET.value.map(ds =>
476+
ds.values.reduce((a, b) => a + b, 0)
477+
);
485478
486-
await animateWithGhost(
487-
finalValues,
488-
FINAL_CONFIG.value.startAnimation.durationMs,
489-
FINAL_CONFIG.value.startAnimation.staggerMs
490-
);
479+
await animateWithGhost(
480+
finalValues,
481+
FINAL_CONFIG.value.startAnimation.durationMs,
482+
FINAL_CONFIG.value.startAnimation.staggerMs
483+
);
491484
}
492485
493486
isFirstLoad.value = false;
@@ -601,7 +594,7 @@ const immutableSet = computed(() => {
601594
ghost: false,
602595
pattern: `pattern_${uid.value}_${i}`
603596
}
604-
})
597+
});
605598
});
606599
607600
// v3 - Stop skeleton loader when props.dataset becomes valid
@@ -611,12 +604,12 @@ watch(() => props.dataset, (newVal) => {
611604
}
612605
}, { immediate: true });
613606
614-
const mutableSet = shallowRef(immutableSet.value)
607+
const mutableSet = shallowRef(immutableSet.value);
615608
616609
watch(() => immutableSet.value, (val) => {
617610
mutableSet.value = val;
618611
requestAnimationFrame(resizeAndReflow);
619-
})
612+
});
620613
621614
function getData() {
622615
return immutableSet.value.map(ds => {

0 commit comments

Comments
 (0)