feat(onboarding): no hint toast after the first-chart star convergence
Independent Staging Quality Gate / validate (push) Failing after 10m40s
Independent Staging Quality Gate / publish (push) Skipped

Product 2026-09-29: drop 「这片天空在星盘页可以保存。」. The chart page entry is now replay + share.
Verified: tsc 0, lint 0 errors, npm test 4335/4280/24 (same 24 Docker/DB/deploy names),
quick gate (gate params) passed, / Static, first-screen JS gzip 651,512 -> 651,143.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01N4f2nya58RoRu4yEmJgRGE
This commit is contained in:
Jesse_Chen
2026-09-29 09:24:00 +08:00
co-authored by Claude Opus 5.5
parent f51c830b52
commit 9686dfb945
6 changed files with 24 additions and 29 deletions
@@ -105,8 +105,10 @@ test("failure: no overlay, no retry, no error surfaced", async () => {
assert.equal(calls, 2);
assert.deepEqual(shown, []);
assert.doesNotMatch(revealHook, /setError|console\.(error|warn)/);
// The only toast is the hint in `close`, which runs after the overlay has played.
assert.equal(revealHook.match(/toast\(/g)?.length, 1);
// 原值:hook 里恰好 1 处 `toast(`(过场结束后的提示)
// 新值:0 处
// 原因:产品 2026-09-29 去掉过场后的提示句
assert.equal(revealHook.match(/toast\(/g)?.length ?? 0, 0);
});
test("only the reader's own onboarding place save triggers it, after the flow has moved on", () => {
@@ -250,14 +252,14 @@ test("overlay: full screen, no buttons; tap, click or Esc ends it at once; rAF s
assert.match(revealHook, /import\("@\/components\/birth-sky\/birth-sky-converge"\)/);
});
test("the hint is the VOICE line, shown once after the overlay ends", () => {
assert.match(revealHook, /export const BIRTH_SKY_REVEAL_HINT = "这片天空在星盘页可以保存。";/);
assert.match(voice, /这片天空在星盘页可以保存。/);
const close = revealHook.slice(revealHook.indexOf("const close"));
const body = close.slice(0, close.indexOf("}, []);"));
assert.match(body, /if \(!playing\.current\) return;\s*playing\.current = false;/);
assert.match(body, /toast\(BIRTH_SKY_REVEAL_HINT\)/);
assert.match(revealHook, /from "sonner"/, "reuses the app's Toaster, no new component");
// 原值(测试名与断言):the hint is the VOICE line, shown once after the overlay ends——常量「这片天空在星盘页可以保存。」、VOICE 收录、close 里 toast 一次
// 新值:nothing follows the overlay——无常量、无 sonner 引用、close 只清状态、VOICE 不再收录这句
// 原因:产品 2026-09-29「把这个提示去掉」(星盘页入口已改为重放 + 分享,原句也不再准确)
test("nothing follows the overlay: no hint toast after it ends", () => {
assert.doesNotMatch(revealHook, /BIRTH_SKY_REVEAL_HINT|这片天空在星盘页可以保存/);
assert.doesNotMatch(revealHook, /from "sonner"/);
assert.doesNotMatch(voice, /这片天空在星盘页可以保存。/);
assert.match(revealHook, /const close = useCallback\(\(\) => setCover\(null\), \[\]\);/);
});
// 原值(测试名与断言):the chart page dialog no longer has a reveal variant——读 `birth-sky-dialog.tsx` / `birth-sky.css`,不得有「继续」/ is-reveal