Skip to content

Commit cf724bd

Browse files
committed
fix: use static i18n keys in DownloadButton for static analysis
1 parent b8c7570 commit cf724bd

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

app/components/Package/DownloadButton.vue

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,10 @@ const dropdownPosition = shallowRef<{ top: number; left: number } | null>(null)
2222
2323
const menuId = 'download-menu'
2424
const menuItems = computed(() => {
25-
const items = [{ id: 'package', labelKey: 'package.download.package', icon: 'i-lucide:package' }]
25+
const items = [{ id: 'package', icon: 'i-lucide:package' }]
2626
if (props.dependencies?.length) {
2727
items.push({
2828
id: 'dependencies',
29-
labelKey: 'package.download.dependencies',
3029
icon: 'i-lucide:list-tree',
3130
})
3231
}
@@ -244,7 +243,7 @@ defineOptions({
244243
@mouseenter="highlightedIndex = index"
245244
>
246245
<span :class="item.icon" class="w-4 h-4" aria-hidden="true" />
247-
{{ $t(item.labelKey) }}
246+
{{ item.id === 'package' ? $t('package.download.package') : $t('package.download.dependencies') }}
248247
</li>
249248
</ul>
250249
</Transition>

0 commit comments

Comments
 (0)