From c28d1e153707d81ee35eaa3cf3149bc98cc6b09a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=B8=89=E5=92=B2=E6=99=BA=E5=AD=90?= Date: Mon, 9 Jan 2023 16:36:24 +0800 Subject: [PATCH] fix: trim spaces for search keyword --- components/command/CommandPanel.vue | 2 +- components/search/SearchWidget.vue | 20 +++++++++++--------- composables/masto/search.ts | 14 ++++++++------ 3 files changed, 20 insertions(+), 16 deletions(-) diff --git a/components/command/CommandPanel.vue b/components/command/CommandPanel.vue index a94cc201..9dce81a0 100644 --- a/components/command/CommandPanel.vue +++ b/components/command/CommandPanel.vue @@ -221,7 +221,7 @@ const onKeyDown = (e: KeyboardEvent) => {
{{ - input.length + input.trim().length ? $t('common.not_found') : $t('search.search_desc') }} diff --git a/components/search/SearchWidget.vue b/components/search/SearchWidget.vue index 80796ea7..e9db61b2 100644 --- a/components/search/SearchWidget.vue +++ b/components/search/SearchWidget.vue @@ -77,17 +77,19 @@ const activate = () => {
- + {{ t('search.search_desc') }} -