Skip to content

feat(review): 评审页增加总评并优化可读性 / add review verdict and improve readability - #41

Merged
Qiuner merged 5 commits into
mainfrom
feat/review-verdict
Nov 14, 2026
Merged

Qiuner merged 5 commits into
mainfrom
feat/review-verdict

Conversation

@Qiuner

@Qiuner Qiuner commented Nov 12, 2026 •

Copy link
Copy Markdown
Owner

Pull Request ## Change / 改动 评审页之前只有“建议先做”,没有直接回答“这个项目现在好不好”。本 PR 增加必填总评,并优化评审页的可读性。 The review page answered "what to fix first" but not "is this in good shape". This adds a required verdict and makes the page easier to read. 1. 必填总评 / Required verdict (aeb3419) - 评审契约 schemaVersion 升至 "3",新增必填 verdict { grade: healthy | needs-work | at-risk, headline, reasons[] };不再接受 "2"(破坏性变更)。 - 校验总评与候选一致:存在 strong 且有 observed 批注的候选时不能判 healthy;at-risk 至少一条理由引用候选;引用的候选必须存在。 - 页面最上方显示总评印章、一句话结论、可跳转到图纸的理由;“建议先做”并入总评卡片。 - 更新 examples/review.json、中英文 review-contract / review-architecture 文档。 2. 依据折叠与红笔避让 / Folded evidence, clear red-pencil notes (e55f602) - 源码依据默认折叠为一行(文件 · 行号 · 批注),点开看原文;誊清稿在桌面端滚动吸附。示例页高度 6428px → 约 4480px。 - 批注文字避开节点、红笔标记、连线标签和其他批注,优先选不压连线的位置,并加纸色描边。 - 缺接缝虚线改走节点外侧,选穿过节点最少的一侧;上下排列的重复项改用外侧括号连接。 3. 代码折行与论证区 / Wrapped code and argument layout (4dccc54) - 代码每行独立成块,折行悬挂在本行缩进之下。 - 论证区先突出“方案”,收益 / 迁移代价 / 不改变 / 删除测试收成卡片;红笔楷体只保留给评审批注。 ## Verification / 验证 - npm run check:pr:全部通过(typecheck、check:build、103 项单元测试、浏览器测试、演示重新生成与 diff、示例校验、文档检查)。 - npm run check:install:通过。注:在 Windows Git Bash 下,GNU tar 会把 E:\… 临时路径当成远程主机而失败,与本 PR 无关;改用 Windows 自带 bsdtar 后通过。 - 新增回归测试:总评缺失 / 旧版本 / 与候选矛盾时拒绝;批注不覆盖节点且互不重叠;依据默认折叠;代码行带缩进;方案在卡片之前。 - 截图检查:1440×1000 深色 / 浅色、390×900 手机,示例页两张图纸。 Reviewer notes - 破坏性契约变更:旧评审 JSON 需补 verdict 并改 schemaVersion: "3",建议在下个版本的发布说明中提醒。 - 批注避让只针对节点、标记和连线标签;极密的图找不到空位时批注往下排、图纸变高,不会重叠。 ## Checklist - [x] Changes are scoped to the stated problem. - [x] Relevant checks passed; remaining limitations are described. - [x] Changed documentation is synchronized in English and Chinese, with the documentation check passing. - [x] No secrets, private project data or unrelated generated files are included.

Integration review

Synchronized with main after #40 and resolved the browser runner comment conflict. Added real-browser checks for verdict reason links switching to the correct sheet and evidence expanding/collapsing, in both interface languages.

The integrated snapshot passes npm run check:pr (103 unit tests and all browser suites) and the committed archive passes npm run check:install. Desktop dark and mobile light layouts were inspected. The first local run hit a 0.11-pixel position assertion in the existing constraint-view browser test; the full rerun passed without changing that test or its implementation.

- 契约 schemaVersion 升至 "3",新增 verdict { grade, headline, reasons };不再接受 "2"
- 校验总评与候选一致:有 observed 批注的 strong 候选时不能判 healthy;at-risk 至少一条理由引用候选
- 评审页顶部先显示总评印章、一句话结论和可跳转理由,「建议先做」并入总评卡片
- 更新示例、回归测试与中英文评审契约文档

- Bump schemaVersion to "3" with a required verdict; "2" is rejected
- Validate that the verdict agrees with the candidates it summarizes
- Show grade seal, headline and linked reasons before any drawing; fold the recommendation into the card
- Update example, regression tests and bilingual review docs
… clear

- 源码依据默认折叠为「文件 · 行号 · 批注」一行,点开看原文;誊清稿在桌面端随滚动吸附,单张图纸页高约减三成
- 红笔批注文字避开节点、红笔连线、连线标签和其他批注,优先选择不压连线的位置,并加纸色描边
- 缺接缝虚线改走节点外侧通道,选穿过节点最少的一侧;上下排列的重复项改用外侧括号连接
- 新增回归测试:批注不覆盖节点、互不重叠,依据默认折叠

- Fold evidence slips to one line (file, lines, note) and keep the redraw sticky on desktop
- Place notes clear of nodes, marks, edge labels and other notes, preferring spots off wires, with a paper halo
- Route missing-seam lines through the gutter with fewest node crossings; bracket stacked duplicates on the outside
- Add regression tests for note placement and folded evidence
…solution

- 源码依据每行独立成块,折行文字悬挂在本行代码缩进之下,不再顶到行号下;悬停高亮整行
- 论证区先用醒目条带给出方案,收益、迁移代价、不改变、删除测试收成卡片,与既有决策冲突时整行红色提示
- 删除测试改用普通正文,红笔楷体只留给评审批注
- 新增回归测试:每行代码带缩进、方案在卡片之前

- Render each quoted line as its own block so wrapped text hangs under its code indent
- Lead the argument with a prominent solution and move wins, cost, boundaries and deletion test into cards
- Keep the hand font for review marks only
- Add regression tests for line blocks and solution order
ubuntu-latest 已切到 26.04,锁定的 Playwright 1.56.1 不支持,安装 chromium 失败。
ubuntu-latest now maps to 26.04, which the pinned Playwright 1.56.1 cannot install chromium on.
@Qiuner
Qiuner merged commit 4c49a83 into main Nov 14, 2026
10 checks passed
@Qiuner
Qiuner deleted the feat/review-verdict branch November 14, 2026 10:36
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