@@ -9,8 +9,6 @@ import type { RepoRef } from '#shared/utils/git-providers'
99import type { VueUiSparklineConfig , VueUiSparklineDatasetItem } from ' vue-data-ui'
1010import { onKeyDown } from ' @vueuse/core'
1111
12- import (' vue-data-ui/style.css' )
13-
1412const props = defineProps <{
1513 packageName: string
1614 createdIso: string | null
@@ -20,6 +18,7 @@ const props = defineProps<{
2018const router = useRouter ()
2119const route = useRoute ()
2220const { settings } = useSettings ()
21+ const { stylesLoaded } = useVueDataUiStyles ()
2322
2423const chartModal = useModal (' chart-modal' )
2524const hasChartModalTransitioned = shallowRef (false )
@@ -424,7 +423,7 @@ const config = computed<VueUiSparklineConfig>(() => {
424423 <div class =" w-full h-[76px] egg-pulse-target" :class =" { 'egg-pulse': eggPulse }" >
425424 <template v-if =" isLoadingWeeklyDownloads || hasWeeklyDownloads " >
426425 <ClientOnly >
427- <VueUiSparkline class =" w-full max-w-xs" :dataset :config >
426+ <VueUiSparkline v-if = " stylesLoaded " class =" w-full max-w-xs" :dataset :config >
428427 <!-- Keyboard navigation hint -->
429428 <template #hint =" { isVisible } " >
430429 <p v-if =" isVisible" class =" text-accent text-xs text-center mt-2" aria-hidden =" true" >
@@ -437,6 +436,21 @@ const config = computed<VueUiSparklineConfig>(() => {
437436 <div />
438437 </template >
439438 </VueUiSparkline >
439+ <template v-else >
440+ <div class =" max-w-xs" >
441+ <div class =" h-6 flex items-center ps-3" >
442+ <SkeletonInline class =" h-3 w-36" />
443+ </div >
444+ <div class =" aspect-[500/80] flex items-center" >
445+ <div class =" w-[42%] flex items-center ps-0.5" >
446+ <SkeletonInline class =" h-7 w-24" />
447+ </div >
448+ <div class =" flex-1 flex items-end pe-3" >
449+ <SkeletonInline class =" h-px w-full" />
450+ </div >
451+ </div >
452+ </div >
453+ </template >
440454 <template #fallback >
441455 <!-- Skeleton matching VueUiSparkline layout (title 24px + SVG aspect 500:80) -->
442456 <div class =" max-w-xs" >
0 commit comments