This commit is contained in:
jxxghp
2024-04-28 21:45:16 +08:00
parent 14a825093a
commit 1846ee0ffe
+6 -6
View File
@@ -165,7 +165,8 @@ const filterPlugins = computed(() => {
// 需要忽略大小写 // 需要忽略大小写
return ( return (
item.plugin_name?.toLowerCase().includes(keyword.value.toLowerCase()) || item.plugin_name?.toLowerCase().includes(keyword.value.toLowerCase()) ||
item.plugin_desc?.toLowerCase().includes(keyword.value.toLowerCase()) item.plugin_desc?.toLowerCase().includes(keyword.value.toLowerCase()) ||
!keyword
) )
}) })
}) })
@@ -205,7 +206,6 @@ async function fetchUninstalledPlugins() {
data.has_update = true data.has_update = true
data.repo_url = uninstalled.repo_url data.repo_url = uninstalled.repo_url
data.history = uninstalled.history data.history = uninstalled.history
data.plugin_label = uninstalled.plugin_label
} }
} }
} }
@@ -430,8 +430,9 @@ onBeforeMount(async () => {
/> />
</VToolbar> </VToolbar>
<DialogCloseBtn @click="closeSearchDialog" /> <DialogCloseBtn @click="closeSearchDialog" />
<VList v-if="filterPlugins.length > 0" lines="two"> <VList v-if="filterPlugins.length > 0" lines="three">
<template v-for="(item, i) in filterPlugins" :key="i"> <VVirtualScroll :items="filterPlugins">
<template #default="{ item }">
<VListItem @click="openPlugin(item)"> <VListItem @click="openPlugin(item)">
<template #prepend> <template #prepend>
<VAvatar> <VAvatar>
@@ -459,12 +460,11 @@ onBeforeMount(async () => {
> >
{{ label }} {{ label }}
</VChip> </VChip>
<span>
{{ item.plugin_desc }} {{ item.plugin_desc }}
</span>
</VListItemSubtitle> </VListItemSubtitle>
</VListItem> </VListItem>
</template> </template>
</VVirtualScroll>
</VList> </VList>
</VCard> </VCard>
</VDialog> </VDialog>