Repository navigation
feat(completion): full-height glass panel + liveSolve/review variants + streak/haptics wiring - #1048
Conversation
…#1023 Phase A) Rebuilds the shared game-completion overlay (CompletionOverlayScaffold) as a full-height Liquid-Glass panel per docs/designs/v3/design.md §3.5/§4.3/§4.4: the finished board now stays visible behind the panel instead of an opaque warm-paper background, with an accent glow painted behind the glass so it naturally picks up the tint. New value types in GameShellUI: CompletionVariant (liveSolve vs review), CompletionMotionPlan (pure M1/M2/M3/M4/M10 animation table incl. Reduce Motion fallbacks per §6), and CompletionContext (the §3.5 4-row CTA hierarchy: dailyMoreToday / dailyAllDone / practice / loss). All 4 production completion paths in both apps now pass the correct variant — only the live overlay plays the win ritual + haptic; the 3 review paths (pushed re-view route, Sudoku's completedRedirect, MS's resolved(.completed)) never do, matching the "no false report of a fresh accomplishment" contract. Haptic authority is unchanged (still fires only at the VM's terminal-transition edge); the review-variant surfaces hold no SoundPlaying/HapticPlaying reference at all. Wires real Daily "more today?" resolution (dailyMoreToday vs dailyAllDone) at every Daily call site in both apps, via a new fetchDailyProgress closure mirroring the existing makeDailyReminderPrimer injection shape. Adds a streak token group (StreakTokens.pipOff) to the Theme protocol + both apps' palettes + NeutralTheme, ahead of Phase B's streak view. New/refreshed localized strings (7 locales): "Done", "Next:", "See you tomorrow", "Try Again". Co-Authored-By: Claude Fable 5 <[email protected]>
…#1023) Adds the M3/M4 streak-ritual consumers (design.md §6) Phase A left unconsumed: a shared CompletionStreakView (pips row + count caption) in GameShellUI, gated exclusively to (variant == .liveSolve, outcome success, Daily context) so review/practice/loss paths never show a false "streak advanced" report. Both apps resolve pre/post streak state via a new makeFetchStreakAdvance factory that reuses the existing DailyStripLogic/MinesweeperDailyStripLogic.computeStreak — no second streak algorithm — and is race-free against the just-finished solve's async persist by explicitly excluding/including the current puzzleId from today's completed set rather than depending on write-then-read timing. Co-Authored-By: Claude Fable 5 <[email protected]>
…1023 Re-anchors both live completion-overlay screen contracts to the #1023 as-built shape: Liquid-Glass full-height panel (board visible behind), CompletionContext 4-row CTA hierarchy, streak section, liveSolve/review state variants, and the #1038 hoisted-presentation seam #1022's G4 must observe. Element inventories previously documented the pre-#1023 Play-Again/Close-only layout. Co-Authored-By: Claude Fable 5 <[email protected]>
idb interactive acceptance evidence (#1023 criterion: board visible behind the glass)Fresh builds of both apps from head 1. liveSolve — Sudoku (the acceptance money shot): PASS. A real practice-Easy board was grid-extracted and solved via 39 correct taps (0 mistakes). Burst capture on the final digit ( 2. liveSolve loss — Minesweeper: PASS. Beginner practice, mine hit ( → This settles the CR MAJOR / sonnet's doubt directly: the flat opaque rectangle in the MS terminal-overlay snapshot is an offline-renderer artifact (headless NSHostingView does not composite Liquid Glass); on a live simulator the real refraction/translucency lands in both apps. 3. review path (seeded 4. iPad regular-width review push: works, layout polish filed as #1049. The push mechanism is correct (detail push, back/Close pop to hub — Not live-verified (covered by tests instead): the daily-win streak pip advance animation (M3/M4) — exercised by 🤖 Generated with Claude Code |
|
T6 ACCEPT — fresh-context acceptance of #1023's criteria against PR head 1. Issue #1023 acceptance criteria — mechanically checked, all pass:
2. idb evidence comment (id 5503492706) — confirmed present, content matches:
3. Follow-up issue #1049 — exists, OPEN, scope matches exactly: pre-existing iPad/macOS regular-width centered-card composition for the pushed review route, correctly scoped as unruled by design.md §3.5/§4.4, 4. PR body — 5. Diff sanity — No new blockers found. Recommend merge. |
Rebuilds the shared completion overlay as the G6 full-height Liquid-Glass panel per
docs/designs/v3/design.md§3.5/§4.3/§4.4/§6/§6.1.closes #1023
part of #1014
What changed
Phase A (ea231be):
CompletionOverlayScaffold→ full-height glass panel (GlassEffectContainer+.glassEffect(.regular)); opaque background deleted — the finished board stays visible behind the glass; accent glow painted BEHIND the glass (§3.5).GameShellUI:CompletionVariant(liveSolve/review),CompletionMotionPlan(M1/M2/M3/M4/M10 table incl. §6 Reduce-Motion fade fallbacks — RM is replace-with-fade, not off),CompletionContext(§3.5's exact 4-row CTA hierarchy incl. the one value-toned"See you tomorrow").liveSolve; pushed re-view route, Sudoku.completedRedirect, MS.resolved(.completed)=review(no ritual, no rise, no haptic — the "谎报" prohibition)..sudokuWin/.minesweeperWin/.minesweeperExplosionevents); the panel never fires haptics; review paths are structurally silent. Existing Sound-section haptics toggle is the only switch (no second setting).fetchDailyProgress/onDailyNextclosures resolved in each app's composition root).StreakTokenstheme group + colorsets (design.md §5.2/§5.3 values); 4 new CTA strings localized ×7 locales.Phase B (a783d4f):
CompletionStreakAdvance(pre→post) + sharedCompletionStreakViewpips row consuming M3 (0.35s fill + scale bounce) / M4 (numeric slide-replace); visibility gated toliveSolve+ success + daily + provider wired — review/practice/loss never show it.makeFetchStreakAdvanceproviders in both composition roots, computed via the existingDailyStripLogic/week-window machinery (no second streak algorithm).Docs (131f7b5 + in-B):
docs/screen-contracts.mdSUD/MS completion-overlay contracts re-anchored to the as-built shape (element inventory, covering behavior, state variants, the #1038 presentation seam #1022's G4 must observe per §4.3).Design rulings honored
.sheet(review variant is a detail-column push on macOS/iPad).BoardModalPresentation→HoistedOverlayHost); no preference keys, no.disabled().modalOverlayPresentation == .completionkey is documented (code + contract doc) as the seam G4 must observe to unmount.Verification
swift testGameShellKit 75/75 · MinesweeperKit 377/377 (full) · SudokuKit green across full + filtered batches (the two documented pre-existing local flakes —swiftpm-testing-helpersegfault and theBoardLeaveOrPauseStateTestswall-clock assertion — reproduce on main and pass in isolation)..review; haptics asserted both directions viaFakeSoundPlaying(win = exactly one.success, MS loss = exactly one.error, review = zero events).swiftlint --strictclean on changed files;mise run scan:l10ngate passes (7 locales, fixture in sync).playAgainbaseline replaced by 4 CTA-context baselines + 1 streak baseline; MS terminal-overlay baselines re-recorded for the background removal (investigated first — includes one test-harness-onlycompletionHeroSkipsRevealfix).Outstanding
🤖 Generated with Claude Code