From 98d5bdd2d1c8606638e8423738425cfde8adf999 Mon Sep 17 00:00:00 2001 From: sh0go07 Date: Mon, 20 May 2024 18:21:23 +0900 Subject: [PATCH] =?UTF-8?q?=E6=A4=9C=E7=B4=A2=E3=83=9C=E3=83=83=E3=82=AF?= =?UTF-8?q?=E3=82=B9=E3=81=8C=E7=A9=BA=E6=AC=84=E3=81=AE=E6=99=82=E3=81=AB?= =?UTF-8?q?Enter=E3=82=92=E6=8A=BC=E3=81=97=E3=81=A6=E3=82=82=E9=A3=9B?= =?UTF-8?q?=E3=81=B0=E3=81=AA=E3=81=84=E3=82=88=E3=81=86=E3=81=AB=E3=81=97?= =?UTF-8?q?=E3=81=9F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/UI/SearchInput.vue | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/components/UI/SearchInput.vue b/src/components/UI/SearchInput.vue index 9996147..f796454 100644 --- a/src/components/UI/SearchInput.vue +++ b/src/components/UI/SearchInput.vue @@ -18,7 +18,9 @@ const router = useRouter() const input = ref('') const submit = () => { // 検索結果ページへ遷移 - router.push({ name: 'UserSearch', query: { q: input.value } }) + if (input.value !== '') { + router.push({ name: 'UserSearch', query: { q: input.value } }) + } } const iconSize = computed(() => { if (props.size === 'large') return 36