保证pnpmdev不会因为包链接的错误而报错;将library的前端进行分块。#86
Conversation
There was a problem hiding this comment.
Pull request overview
该 PR 聚焦于提升本地开发体验(避免 pnpm dev 因 workspace 包未预构建而失败),并重构 Library 详情页为更清晰的分块卡片布局,同时保留 split view、annotation、excerpt、timestamp footer 等现有交互能力。
Changes:
- 为
frontend增加predev(启动 dev 前先 build@vesti/content-package)与dev:verbose脚本。 - 重构
LibraryTab详情页结构,引入分块卡片(Overview / Original Conversation / Related Notes / Related Conversations)与更清晰的折叠预览。 - 调整会话展开逻辑(非 split 默认折叠)并补充预览文本计算。
Reviewed changes
Copilot reviewed 1 out of 2 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| packages/vesti-ui/src/tabs/library-tab.tsx | Library 详情页 UI 分块重构、预览/折叠交互与相关内容展示调整 |
| frontend/package.json | 增加 predev 与 dev:verbose 以提升本地启动稳定性与可观测性 |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| const originalConversationPreview = useMemo(() => { | ||
| if (messagesLoading) { | ||
| return "Loading messages..."; | ||
| } | ||
| if (messages.length === 0) { | ||
| return "No messages captured yet."; | ||
| } |
There was a problem hiding this comment.
originalConversationPreview does not consider messagesError. If the fetch fails, messages is cleared and the preview currently falls back to “No messages captured yet.” which is misleading. Consider returning an error-specific preview when messagesError is set.
| <button | ||
| key={note.id} | ||
| onClick={() => void openNotesView(note.id)} | ||
| className="w-full flex items-center justify-between p-3 rounded-lg hover:bg-bg-surface-card transition-colors group" | ||
| onClick={() => | ||
| console.log("[dashboard] Link a conversation") | ||
| } | ||
| className="text-xs font-sans text-accent-primary" | ||
| > | ||
| <span className="text-[13px] font-sans text-text-primary"> | ||
| {note.title} | ||
| </span> | ||
| <span className="text-[13px] font-sans text-accent-primary"> | ||
| Open → | ||
| </span> | ||
| + Link a conversation |
There was a problem hiding this comment.
There’s a user-facing “+ Link a conversation” button here that only logs to console. This looks like leftover placeholder/debug behavior; it should either be implemented, removed, or disabled/hidden until linking is supported.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: d538c8e3b3
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| const isReaderConversationExpanded = isSplitActive || isConversationExpanded; | ||
| const canToggleConversationExpanded = !isSplitActive && messageCount > 0; |
There was a problem hiding this comment.
Surface message-load errors when conversation view is collapsed
In single-pane mode, the conversation section now starts collapsed and this toggle is only enabled when messageCount > 0. When getMessages fails, messages is cleared and messagesError is set, so users cannot expand the section to see the existing "Unable to load messages." state; the collapsed preview path instead presents it like an empty conversation. This makes backend/network failures look like missing data and removes the only visible error path for that case.
Useful? React with 👍 / 👎.
概述
这个 PR 主要做了两件事:
pnpm dev的稳定性,避免因为本地 workspace 包未预构建而启动失败改动内容
frontend增加predev,在启动plasmo dev前先构建@vesti/content-packagedev:verbose脚本,方便本地排查 Plasmo 启动问题Original Conversation的折叠预览排版,减少拥挤感,保留展开查看完整消息的能力验证
pnpm -C frontend exec tsc --noEmitpnpm -C packages/vesti-ui buildpnpm -C frontend build备注