feat(skills): add skill deletion and improve UI/UX

- Add skill deletion functionality with confirmation dialog
- Protect builtin skills from deletion
- Optimize skill card layout (badge and enable button near menu)
- Change enable button to icon-only with theme color
- Improve card selection and hover states
- Fix skill hub installation state tracking (per-skill)
- Add proper i18n for delete feature (en/zh)
- Add loading states to delete confirmation dialog
- Remove manual refetch calls (use query invalidation)
This commit is contained in:
catlog22
2026-02-24 21:06:34 +08:00
parent 6c9ad9a9f3
commit 33e12a31ac
6 changed files with 219 additions and 24 deletions

View File

@@ -8,6 +8,14 @@
"title": "Disable Skill?",
"message": "Are you sure you want to disable \"{name}\"?"
},
"deleteConfirm": {
"title": "Delete Skill?",
"message": "Are you sure you want to delete \"{name}\"? This action cannot be undone."
},
"delete": {
"success": "Skill \"{name}\" has been deleted",
"error": "Failed to delete skill: {error}"
},
"location": {
"project": "Project",
"user": "Global",
@@ -25,8 +33,10 @@
"disable": "Disable",
"toggle": "Toggle",
"install": "Install Skill",
"delete": "Delete",
"cancel": "Cancel",
"confirmDisable": "Disable"
"confirmDisable": "Disable",
"confirmDelete": "Delete"
},
"state": {
"enabled": "Enabled",

View File

@@ -8,6 +8,14 @@
"title": "禁用技能?",
"message": "确定要禁用 \"{name}\" 吗?"
},
"deleteConfirm": {
"title": "删除技能?",
"message": "确定要删除 \"{name}\" 吗? 此操作无法撤销。"
},
"delete": {
"success": "技能 \"{name}\" 已删除",
"error": "删除技能失败: {error}"
},
"location": {
"project": "项目",
"user": "全局",
@@ -25,8 +33,10 @@
"disable": "禁用",
"toggle": "切换",
"install": "安装技能",
"delete": "删除",
"cancel": "取消",
"confirmDisable": "禁用"
"confirmDisable": "禁用",
"confirmDelete": "删除"
},
"state": {
"enabled": "已启用",