chore: comprehensive code review fixes — security, perf, leaks, quality, docs

- security: XSS sanitization with DOMPurify in Markdown/Mermaid/PermissionDialog;
  path whitelist in filesystem API; fake keys in test/config files
- perf: fine-grained Zustand selectors in Sidebar/StatusBar/ContentRouter;
  50ms throttle on streaming deltas; React.memo + useMemo in MessageList;
  useRef for frequent keyboard shortcut state; AbortController 30s timeout
- leaks: WS session TTL timers (5-min cleanup on close); batch splice for
  sdkMessages/stderrLines; folderPath validation in cronScheduler
- quality: optimistic update rollback in settingsStore; error state in
  providerStore/teamStore; i18n for all hardcoded English strings
- docs: desktop architecture and features docs updated; VitePress nav fixed

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
程序员阿江(Relakkes)
2026-04-13 22:27:17 +08:00
parent a0fa8751b3
commit 8888e1c3fb
41 changed files with 385 additions and 132 deletions
+22
View File
@@ -78,6 +78,17 @@ const zhSidebar = [
{ text: '架构解析', link: '/features/computer-use-architecture' },
],
},
{
text: '桌面端',
collapsed: false,
items: [
{ text: '概览', link: '/desktop/' },
{ text: '快速上手', link: '/desktop/01-quick-start' },
{ text: '架构设计', link: '/desktop/02-architecture' },
{ text: '功能详解', link: '/desktop/03-features' },
{ text: '安装与构建', link: '/desktop/04-installation' },
],
},
{
text: '参考',
collapsed: true,
@@ -143,6 +154,17 @@ const enSidebar = [
{ text: 'Architecture', link: '/en/features/computer-use-architecture' },
],
},
{
text: 'Desktop',
collapsed: false,
items: [
{ text: 'Overview', link: '/en/desktop/' },
{ text: 'Quick Start', link: '/en/desktop/01-quick-start' },
{ text: 'Architecture', link: '/en/desktop/02-architecture' },
{ text: 'Features', link: '/en/desktop/03-features' },
{ text: 'Installation & Build', link: '/en/desktop/04-installation' },
],
},
{
text: 'Reference',
collapsed: true,