Files
MooTool/next-compose/docs/diff/365-quicknote-vault-context-module.md
RememBerBerandCursor c834db2a83 feat(next-compose): 对照 Electron 落地 F00–F25 与 A01–A03 主体能力
将 Vault/Git/MCP/AI、壳层主题密度、25 工具真实闭环与 desktopTest 638 项及 DIFF-065–471 文档/证据一并纳入仓库,便于持续对齐验收;产品窗 IME/冲突与三平台发行仍待验。

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-17 06:51:45 +08:00

17 lines
941 B
Markdown
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# DIFF-365:随手记 Vault 上下文模块与 prepare 单测
## 背景
JSON Vault 已在 [DIFF-364](364-json-vault-prepare-context-extract-test.md) 将 `prepareJsonVaultContext` 提取到 `JsonVaultSession.kt` 并加冲突单测。随手记 `prepareQuickNoteVaultContext` 与 `saveIfNeeded` / `saveCurrent` / `openFile` 仍堆在 `QuickNoteScreen.kt`,不便回归且与 JSON 不对称。
## 变更
- 新增 `QuickNoteVaultContext.kt`:`prepareQuickNoteVaultContext`、`quickNoteVaultSaveIfNeeded`、`quickNoteSaveCurrent`、`quickNoteOpenVaultFile`、`quickNoteOnEdt`。
- `prepare` 开头同步 `vaultSelectedPath`(对齐 JSON `prepareJsonVaultContext`)。
- `QuickNoteScreen.kt` 改为调用上述 internal API,删除重复实现。
- 新增 `QuickNoteVaultPrepareContextTest`:脏笔记 + 磁盘正文冲突时 prepare 失败、`error`/`vaultConflict` 非空。
## 验证
- `./gradlew :composeApp:desktopTest --offline`