makecindy / makecindy/cindy

维护者确认:#4519 文件树右键「添加到对话」产品 UI

Open
#4,525 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
2.7k
Forks
395
Avg merge
21h 48m
Merged PRs (30d)
776

Description

PR https://github.com/makecindy/cindy/pull/4519 需要维护者确认后再继续自动审查与合并。

## 这次改了什么
在 Desktop 右侧文件树的文件右键菜单增加「添加到对话 / Add to chat」。点击后把被右键的文件作为现有文件引用标签插入当前任务输入框,保留草稿并聚焦输入框,由用户自行发送。独立侧栏没有输入框,该入口被隐藏;主窗口和带输入框的副窗口保留入口。输入框未挂载或锁定时提示稍后重试,不缓存请求。

主要代码:
- `FileTreeView.tsx`:文件右键菜单首项,复用 `chat.quote.addToChat` 与 `MessageSquarePlus`
- `FileBrowserBody.tsx`:按当前侧栏 sessionId 定向插入;独立侧栏不提供入口
- `composerActionsBus.ts` + `ChatInput.tsx`:按 session 订阅、首个接受者写入、输入锁拒绝

另改 `docs/design-rules/design-inventory.md`:由 `pnpm design:inventory` 刷新生成台账(快照日期与 `desktop.chat.files` 计数),不是审查规则正文。

## 为何需要维护者确认
1. **产品 / UI**:`feat` + 生产 UI 路径(ChatInput / FileTreeView / FileBrowserBody / composerActionsBus)。这是用户可见新入口,改变从文件树引用文件的交互,不是 bugfix 或纯技术改动。
2. **规则文档路径**:命中 `docs/design-rules/design-inventory.md`。内容是生成台账机械刷新,不改变审查判据含义;当前阻塞类别仍是产品门。

## 请维护者怎么做
请直接在 PR 上 **Approve**。若认为需要作者修改,请 **Request Changes**。普通评论、讨论 issue 留言或摘标签都不构成通过。

---
关联 PR:#4519(作者 @lxd930808);本 issue 由 review-pr 流程自动创建,用于先讨论该 PR 涉及的产品 / UI 变更,维护者确认后 PR 会恢复推进。

Contributor guide

Open the contributing guide

Research direction

Review PR #4519 and the affected entry points: FileTreeView.tsx, FileBrowserBody.tsx, composerActionsBus.ts, and ChatInput.tsx. Check that the described file-to-chat behavior and the generated docs/design-rules/design-inventory.md update match the product and UI expectations, then approve the PR or request changes.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
desktop, frontend
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
15/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.