From cea67404ed47b097cf98080813d70645ceb63ca7 Mon Sep 17 00:00:00 2001 From: R2m1liA <15258427350@163.com> Date: Thu, 30 Oct 2025 14:06:43 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BF=AE=E6=AD=A3=E6=90=9C=E7=B4=A2?= =?UTF-8?q?=E9=A1=B5=E9=9D=A2=E7=9B=B8=E5=85=B3=E9=97=AE=E9=A2=98=E8=B7=AF?= =?UTF-8?q?=E7=94=B1=E8=B7=B3=E8=BD=AC=E9=80=BB=E8=BE=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 当用户点击问题条目时,生成一个带有query的url: faq?focus=[slug]自动展开faq页面中的对应词条 --- app/components/pages/search/SearchResults.vue | 4 +++ app/components/shared/QuestionList.vue | 31 +++++++++++++++++-- 2 files changed, 33 insertions(+), 2 deletions(-) diff --git a/app/components/pages/search/SearchResults.vue b/app/components/pages/search/SearchResults.vue index 5c01635..fd62149 100644 --- a/app/components/pages/search/SearchResults.vue +++ b/app/components/pages/search/SearchResults.vue @@ -128,6 +128,10 @@ return localePath({ path: `/download/${slug}` }); } + if (item.type === 'question') { + return localePath({ path: `/support/faq`, query: { focus: slug } }); + } + return null; }; diff --git a/app/components/shared/QuestionList.vue b/app/components/shared/QuestionList.vue index 58f8ef0..cb64b07 100644 --- a/app/components/shared/QuestionList.vue +++ b/app/components/shared/QuestionList.vue @@ -1,8 +1,9 @@