Files
novalon-website/docs/acceptance/2026-12-02-baselines/attribution.md
T
zhangxiang 8431d15956 test(visual): 首页基线重写 9 张(hero 右栏 E 案像素变化)+ 归因记录
- 只读比对 214/11:9 例归因 a8a012b0(右栏双 V + 网格),页脚 2 例为抖动不写入
- -g 首页 + changed 模式写入,git status 恰 9 M 零外溢;9/9 逐张读图追认
- 只读复验 223/2:首页全绿;页脚抖动单跑 3/3 过,列遗留 ticket 候选
- D 项裁定:持久态底部锚定不转译(无副图支撑,沉底失衡),理由入 attribution §5
2026-12-02 08:50:04 +08:00

43 lines
2.9 KiB
Markdown
Raw 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.
# 2026-12-02 视觉基线写入归因(首页 hero 右栏 E 案)
- 授权:用户裁定「剩余项全按推荐」—— 授权重写首页相关基线(C 项);持久态剩余语法(D 项)裁定**不转译**,理由见下。
- 基线所属提交:`a8a012b0`(feat/home hero 右栏双 V + 工程网格层),见 `head.txt`。
- 写入清单:**9 张,全部为首页相关**,`git status` 全文见 `write-list.txt`:
`home-fullpage` × 3 project(chromium/firefox/webkit desktop)+ `theme-light-main` / `theme-dark-main` × 3 project。
无 tablet/mobile 写入(该两档 hero 变化在 0.3 阈值内,只读比对本就通过),**零外溢**。
## 1. 只读比对(写入前)
`npm run test:visual:all -- --update-snapshots=none` → **214 passed / 11 failed**。11 例归因:
| 组 | 例数 | 归因 | 处置 |
|---|---|---|---|
| 首页全页 + 首页主题视觉 | 9 | `a8a012b0` 新增右栏双 V(diff 图红标)+ 网格层;diff 其余区域全白 | 本轮重写 |
| 页脚区域视觉一致性(chromium/firefox) | 2 | **抖动**:diff 呈粘性导航/入场动画错位重影;单跑 `-g "页脚区域"` 复跑 **3/3 过** | 不写基线 |
## 2. 写入
`cd e2e && playwright test visual-regression.spec.ts -g "首页" --update-snapshots`(裸旗标 = `changed`,
`node_modules/playwright/lib/program.js:202`,只写缺失/不符,不重写通过项)→ **25 passed / 1.5m**。
`git status` 恰为 9 ` M`(`write-list.txt`),与失败清单逐一吻合,无「通过但被顺手改写」。
## 3. 逐张读图追认(9/9)
- 直接读图 7 张:chromium/firefox/webkit 的 `home-fullpage` 与 `theme-dark`(6 张)+ firefox `theme-light`——
hero 右侧双 V 与网格在位、各段与页脚完整、无错位遮挡。
- chromium `theme-light` 与 `home-fullpage` **md5 字节相同**(默认渲染即浅色;工具判重与哈希互证),追认同成立。
- firefox/webkit `theme-light` 为独立图像(与各自 fullpage 哈希不同),已单独读图追认。
## 4. 只读复验(写入后)
`npm run test:visual:all -- --update-snapshots=none` → **223 passed / 2 failed / 9.1m**。
2 个失败即 §1 页脚抖动(本轮全量下两次复现、单跑稳定过),首页/主题 9 例全绿 ⇒ **写入闭环**。
## 5. 遗留(新开 ticket 候选)
- **页脚视觉测试抖动**:全量并行下偶发粘性导航入镜/内容重影(10-08 基线轮未记录此象,本轮首次观察)。
疑滚动到位时机 + whileInView 入场状态不稳;与本次功能改动无关(单跑过、且 diff 形态为瞬态错位)。
建议:footer 测试加 `scroll into view + 等待动画 settle` 或对 sticky header 区 mask。
- **持久态剩余语法裁定不转译**:Porsche 底部锚定为其「错位副图从下方升起」服务,本仓无副图,
单独沉底会在上方挖出空洞并与中部双 V 失衡;E 案已解决核心问题(右侧兜底)。