Skip to content

feat(search): 适配 v0.56 全局搜索面板 UI/UX#636

Open
KevinYoung-Kw wants to merge 2 commits into
op7418:mainfrom
KevinYoung-Kw:feat/search-panel-v056-refresh
Open

feat(search): 适配 v0.56 全局搜索面板 UI/UX#636
KevinYoung-Kw wants to merge 2 commits into
op7418:mainfrom
KevinYoung-Kw:feat/search-panel-v056-refresh

Conversation

@KevinYoung-Kw

Copy link
Copy Markdown
Contributor

Summary

CodePilot v0.56 global search panel refresh

这个 PR 基于当前 v0.56 的设计语言,重新打磨全局搜索面板 UI/UX。重点不是扩展搜索后端能力,而是让现有搜索入口更像 CodePilot 当前的 command palette:更简洁、更稳定、更少视觉噪音。

主要改动

  • 重做 GlobalSearchDialog 前端结构:移除上一版偏重的卡片墙、分栏结果和重复说明,改为单输入 + scope pills + 单列结果 stack。
  • 会话 / 消息 / 文件 三类搜索范围补充轻量 icon,icon 只出现在范围选择器,不再在结果列表里重复堆叠。
  • 固定搜索弹层的 top 与高度,结果区内部滚动,避免空态、输入态、加载态、结果态切换时上下抖动。
  • 结果区继续保留原有能力:会话、消息、文件三类分组展示,关键词高亮,点击后跳转到对应 session/message/file。
  • 更新搜索 E2E,补充弹层几何稳定性断言,防止后续再次引入位置抖动。

验证

本地已执行:

  • npm run typecheck
  • npx eslint src/components/layout/GlobalSearchDialog.tsx src/__tests__/e2e/global-search-modes.spec.ts
  • NO_PROXY=127.0.0.1,localhost PLAYWRIGHT_BASE_URL=http://127.0.0.1:3237 npx playwright test src/__tests__/e2e/global-search-modes.spec.ts --reporter=line
  • git diff --check

浏览器验收:

  • 使用本地预览 http://127.0.0.1:3237/chat 验证搜索面板空态、输入态、结果态。
  • 弹层几何采样稳定:空态 / 输入后 / 结果态均为 top=276 height=560
  • PR 截图采用空查询裁剪弹层,不包含任何搜索结果,也不包含 wps / 笔记 相关内容。

Notes

  • 这个 PR 只调整搜索面板前端呈现与 E2E 断言,不改 /api/search 后端语义。
  • targeted ESLint 仍有一个既有 max-lines warning:GlobalSearchDialog.tsx 超过 500 行;本 PR 未进一步拆文件,避免扩大评审范围。

@vercel

vercel Bot commented Jun 14, 2026

Copy link
Copy Markdown

@KevinYoung-Kw is attempting to deploy a commit to the op7418's projects Team on Vercel.

A member of the Team first needs to authorize it.

@KevinYoung-Kw KevinYoung-Kw marked this pull request as ready for review June 14, 2026 09:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant