From 5ac6edd073adfe89fc4435bc1bea985d1377bd6d Mon Sep 17 00:00:00 2001 From: rzzf Date: Wed, 11 Feb 2026 16:58:04 +0800 Subject: [PATCH] fix: filter search cannot be typed --- app/components/Filter/Panel.vue | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/app/components/Filter/Panel.vue b/app/components/Filter/Panel.vue index 52b6c6338..34f2fb0f2 100644 --- a/app/components/Filter/Panel.vue +++ b/app/components/Filter/Panel.vue @@ -32,6 +32,11 @@ const { t } = useI18n() const isExpanded = shallowRef(false) const showAllKeywords = shallowRef(false) +const filterText = computed({ + get: () => props.filters.text, + set: value => emit('update:text', value), +}) + const displayedKeywords = computed(() => { const keywords = props.availableKeywords ?? [] return showAllKeywords.value ? keywords : keywords.slice(0, 20) @@ -130,11 +135,6 @@ function getSecurityLabelKey(value: SecurityFilter): string { return securityLabelKeys.value[value] } -function handleTextInput(event: Event) { - const target = event.target as HTMLInputElement - emit('update:text', target.value) -} - // Compact summary of active filters for collapsed header using operator syntax const filterSummary = computed(() => { const parts: string[] = [] @@ -242,13 +242,12 @@ const hasActiveFilters = computed(() => !!filterSummary.value)