11<template >
22 <div class =" relative w-full p-6" >
3- <div class =" flex items-center w-full" >
4- <AutoComplete
5- v-model.lazy =" searchQuery"
6- :suggestions =" suggestions || []"
7- :placeholder =" $t('manager.searchPlaceholder')"
8- :complete-on-focus =" false"
9- :delay =" 8"
10- option-label =" query"
11- class =" w-full"
12- :pt =" {
13- pcInputText: {
14- root: {
15- autofocus: true,
16- class: 'w-5/12 rounded-2xl'
3+ <div class =" h-12 flex items-center gap-1 justify-between" >
4+ <div class =" flex items-center w-5/12" >
5+ <AutoComplete
6+ v-model.lazy =" searchQuery"
7+ :suggestions =" suggestions || []"
8+ :placeholder =" $t('manager.searchPlaceholder')"
9+ :complete-on-focus =" false"
10+ :delay =" 8"
11+ option-label =" query"
12+ class =" w-full"
13+ :pt =" {
14+ pcInputText: {
15+ root: {
16+ autofocus: true,
17+ class: 'w-full rounded-2xl'
18+ }
19+ },
20+ loader: {
21+ style: 'display: none'
1722 }
18- },
19- loader: {
20- style: 'display: none'
21- }
22- }"
23- :show-empty-message =" false"
24- @complete =" stubTrue"
25- @option-select =" onOptionSelect"
23+ }"
24+ :show-empty-message =" false"
25+ @complete =" stubTrue"
26+ @option-select =" onOptionSelect"
27+ />
28+ </div >
29+ <PackInstallButton
30+ v-if =" isMissingTab && missingNodePacks.length > 0"
31+ variant =" black"
32+ :disabled =" isLoading || !!error"
33+ :node-packs =" missingNodePacks"
34+ :label =" $t('manager.installAllMissingNodes')"
2635 />
2736 </div >
2837 <div class =" flex mt-3 text-sm" >
@@ -55,7 +64,9 @@ import AutoComplete, {
5564import { computed } from ' vue'
5665import { useI18n } from ' vue-i18n'
5766
67+ import PackInstallButton from ' @/components/dialog/content/manager/button/PackInstallButton.vue'
5868import SearchFilterDropdown from ' @/components/dialog/content/manager/registrySearchBar/SearchFilterDropdown.vue'
69+ import { useMissingNodes } from ' @/composables/nodePack/useMissingNodes'
5970import {
6071 type SearchOption ,
6172 SortableAlgoliaField
@@ -71,6 +82,7 @@ const { searchResults, sortOptions } = defineProps<{
7182 searchResults? : components [' schemas' ][' Node' ][]
7283 suggestions? : QuerySuggestion []
7384 sortOptions? : SortableField []
85+ isMissingTab? : boolean
7486}>()
7587
7688const searchQuery = defineModel <string >(' searchQuery' )
@@ -81,6 +93,9 @@ const sortField = defineModel<string>('sortField', {
8193
8294const { t } = useI18n ()
8395
96+ // Get missing node packs from workflow with loading and error states
97+ const { missingNodePacks, isLoading, error } = useMissingNodes ()
98+
8499const hasResults = computed (
85100 () => searchQuery .value ?.trim () && searchResults ?.length
86101)
0 commit comments