@@ -4,8 +4,6 @@ import type { VueUiXyDatasetItem } from 'vue-data-ui'
44import { VueUiXy } from ' vue-data-ui/vue-ui-xy'
55import { useDebounceFn } from ' @vueuse/core'
66
7- const { t } = useI18n ()
8-
97const {
108 weeklyDownloads,
119 inModal = false ,
@@ -398,7 +396,7 @@ const config = computed(() => ({
398396 grid: {
399397 labels: {
400398 axis: {
401- yLabel: t (' package.downloads.y_axis_label' , { granularity: selectedGranularity .value }),
399+ yLabel: $ t (' package.downloads.y_axis_label' , { granularity: selectedGranularity .value }),
402400 xLabel: packageName ,
403401 yLabelOffsetX: 12 ,
404402 fontSize: 24 ,
@@ -469,7 +467,7 @@ const config = computed(() => ({
469467 for =" granularity"
470468 class =" text-[10px] font-mono text-fg-subtle tracking-wide uppercase"
471469 >
472- {{ t('package.downloads.granularity') }}
470+ {{ $ t('package.downloads.granularity') }}
473471 </label >
474472
475473 <div
@@ -480,10 +478,10 @@ const config = computed(() => ({
480478 v-model =" selectedGranularity"
481479 class =" w-full bg-transparent font-mono text-sm text-fg outline-none"
482480 >
483- <option value =" daily" >{{ t('package.downloads.granularity_daily') }}</option >
484- <option value =" weekly" >{{ t('package.downloads.granularity_weekly') }}</option >
485- <option value =" monthly" >{{ t('package.downloads.granularity_monthly') }}</option >
486- <option value =" yearly" >{{ t('package.downloads.granularity_yearly') }}</option >
481+ <option value =" daily" >{{ $ t('package.downloads.granularity_daily') }}</option >
482+ <option value =" weekly" >{{ $ t('package.downloads.granularity_weekly') }}</option >
483+ <option value =" monthly" >{{ $ t('package.downloads.granularity_monthly') }}</option >
484+ <option value =" yearly" >{{ $ t('package.downloads.granularity_yearly') }}</option >
487485 </select >
488486 </div >
489487 </div >
@@ -495,7 +493,7 @@ const config = computed(() => ({
495493 for =" startDate"
496494 class =" text-[10px] font-mono text-fg-subtle tracking-wide uppercase"
497495 >
498- {{ t('package.downloads.start_date') }}
496+ {{ $ t('package.downloads.start_date') }}
499497 </label >
500498 <div
501499 class =" flex items-center gap-2 px-2.5 py-1.75 bg-bg-subtle border border-border rounded-md focus-within:(border-border-hover ring-2 ring-fg/50)"
@@ -515,7 +513,7 @@ const config = computed(() => ({
515513 for =" endDate"
516514 class =" text-[10px] font-mono text-fg-subtle tracking-wide uppercase"
517515 >
518- {{ t('package.downloads.end_date') }}
516+ {{ $ t('package.downloads.end_date') }}
519517 </label >
520518 <div
521519 class =" flex items-center gap-2 px-2.5 py-1.75 bg-bg-subtle border border-border rounded-md focus-within:(border-border-hover ring-2 ring-fg/50)"
@@ -636,7 +634,7 @@ const config = computed(() => ({
636634 v-if =" inModal && !chartData.dataset && !pending"
637635 class =" min-h-[260px] flex items-center justify-center text-fg-subtle font-mono text-sm"
638636 >
639- {{ t('package.downloads.no_data') }}
637+ {{ $ t('package.downloads.no_data') }}
640638 </div >
641639
642640 <div
@@ -645,7 +643,7 @@ const config = computed(() => ({
645643 aria-live =" polite"
646644 class =" absolute top-1/2 left-1/2 -translate-x-1/2 -translate-y-1/2 text-xs text-fg-subtle font-mono bg-bg/70 backdrop-blur px-3 py-2 rounded-md border border-border"
647645 >
648- {{ t('package.downloads.loading') }}
646+ {{ $ t('package.downloads.loading') }}
649647 </div >
650648 </div >
651649</template >
0 commit comments