From 688b31002163a28bff33a7e84b6fbaf765da04f5 Mon Sep 17 00:00:00 2001 From: YoVinchen Date: Sat, 14 Feb 2026 11:14:04 +0800 Subject: [PATCH] fix(skill): change search to match name and repo instead of description --- src/components/skills/SkillsPage.tsx | 11 ++++------- src/i18n/locales/en.json | 2 +- src/i18n/locales/ja.json | 2 +- src/i18n/locales/zh.json | 2 +- 4 files changed, 7 insertions(+), 10 deletions(-) diff --git a/src/components/skills/SkillsPage.tsx b/src/components/skills/SkillsPage.tsx index 1968d7793..caa073867 100644 --- a/src/components/skills/SkillsPage.tsx +++ b/src/components/skills/SkillsPage.tsx @@ -213,14 +213,11 @@ export const SkillsPage = forwardRef( const query = searchQuery.toLowerCase(); return byStatus.filter((skill) => { const name = skill.name?.toLowerCase() || ""; - const description = skill.description?.toLowerCase() || ""; - const directory = skill.directory?.toLowerCase() || ""; + const repo = skill.repoOwner && skill.repoName + ? `${skill.repoOwner}/${skill.repoName}`.toLowerCase() + : ""; - return ( - name.includes(query) || - description.includes(query) || - directory.includes(query) - ); + return name.includes(query) || repo.includes(query); }); }, [skills, searchQuery, filterRepo, filterStatus]); diff --git a/src/i18n/locales/en.json b/src/i18n/locales/en.json index 7c65a6857..6de6e1a38 100644 --- a/src/i18n/locales/en.json +++ b/src/i18n/locales/en.json @@ -1143,7 +1143,7 @@ "skillCount": "{{count}} skills detected" }, "search": "Search Skills", - "searchPlaceholder": "Search skill name or description...", + "searchPlaceholder": "Search skill name or repo...", "filter": { "placeholder": "Filter by status", "all": "All", diff --git a/src/i18n/locales/ja.json b/src/i18n/locales/ja.json index f8c9243fe..87047b29b 100644 --- a/src/i18n/locales/ja.json +++ b/src/i18n/locales/ja.json @@ -1141,7 +1141,7 @@ "skillCount": "{{count}} 件のスキルを検出" }, "search": "スキルを検索", - "searchPlaceholder": "スキル名または説明で検索...", + "searchPlaceholder": "スキル名またはリポジトリで検索...", "filter": { "placeholder": "状態で絞り込み", "all": "すべて", diff --git a/src/i18n/locales/zh.json b/src/i18n/locales/zh.json index a5f54bd4e..731b1c558 100644 --- a/src/i18n/locales/zh.json +++ b/src/i18n/locales/zh.json @@ -1143,7 +1143,7 @@ "skillCount": "识别到 {{count}} 个技能" }, "search": "搜索技能", - "searchPlaceholder": "搜索技能名称或描述...", + "searchPlaceholder": "搜索技能名称或仓库名称...", "filter": { "placeholder": "状态筛选", "all": "全部",