@@ -97,12 +97,6 @@ const { colors } = useCssVariables(
9797 },
9898)
9999
100- function toggleSparklineAnimation() {
101- settings .value .sidebar .animateSparkline = ! settings .value .sidebar .animateSparkline
102- }
103-
104- const hasSparklineAnimation = computed (() => settings .value .sidebar .animateSparkline )
105-
106100const isDarkMode = computed (() => resolvedMode .value === ' dark' )
107101
108102const accentColorValueById = computed <Record <string , string >>(() => {
@@ -254,8 +248,8 @@ const config = computed<VueUiSparklineConfig>(() => {
254248 line: {
255249 color: colors .value .borderHover ,
256250 pulse: {
257- show: hasSparklineAnimation . value , // the pulse will not show if prefers-reduced-motion (enforced by vue-data-ui)
258- loop: true , // runs only once if false
251+ show: true , // the pulse will not show if prefers-reduced-motion (enforced by vue-data-ui)
252+ loop: false ,
259253 radius: 1.5 ,
260254 color: pulseColor .value ! ,
261255 easing: ' ease-in-out' ,
@@ -333,23 +327,9 @@ const config = computed<VueUiSparklineConfig>(() => {
333327 <SkeletonInline class =" h-px w-full" />
334328 </div >
335329 </div >
336- <!-- Animation toggle placeholder -->
337- <div class =" w-full hidden motion-safe:flex flex-1 items-end justify-end" >
338- <SkeletonInline class =" h-[20px] w-30" />
339- </div >
340330 </div >
341331 </template >
342332 </ClientOnly >
343-
344- <div v-if =" hasWeeklyDownloads" class =" hidden motion-safe:flex justify-end p-1" >
345- <ButtonBase size =" small" @click =" toggleSparklineAnimation" >
346- {{
347- hasSparklineAnimation
348- ? $t('package.trends.pause_animation')
349- : $t('package.trends.play_animation')
350- }}
351- </ButtonBase >
352- </div >
353333 </template >
354334 <p v-else class =" py-2 text-sm font-mono text-fg-subtle" >
355335 {{ $t('package.trends.no_data') }}
0 commit comments