Add board wipe and deal-in animations for fresh games - #83
Conversation
|
Bugbot is not enabled for your account, so this pull request was not reviewed. Enable Bugbot in the Cursor dashboard to get automatic reviews on future PRs. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 7e7ce9634a
ℹ️ 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".
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 80c351daf9
ℹ️ 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".
redeal reuses the outgoing game's card ids, so leftover frames from the played-out layout satisfied the deal flight's readiness check and could land cards at their old positions before popping to the redealt spread
…th/ComputerSolitaire into fresh-deal-animations
|
@codex review |
|
Codex Review: Didn't find any major issues. 👍 Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
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". |
What Changed
Every fresh board — New Game, Redeal, Golf's next hole, and game switches that deal fresh — now animates instead of snapping into place:
GeometryEffect) because endpoint animation cannot produce accumulation.Supporting changes:
SolitaireViewModelpublishes an explicitBoardDealEventfrom fresh deals; restores never set it, so a hydrated board can never replay a deal. The wipe only runs when a mutation actually dealt (Golf's final-hole advance stays on the finished board untouched).CardViewseeds its resting tilt at init so overlay stand-ins render pixel-identical to the board from their first frame.MotionPolicy(Animation Speed setting and Reduce Motion collapse to instant).withIsolatedStatsStore,makeViewModel) hoisted intoTestSupport, replacing three per-file copies.Why
Starting a new game was the least animated moment in the app: the old board vanished and the new deal appeared in a single frame, while ordinary draws, undos, and wins all have choreographed flights. The deal ceremony is the moment players see most often.
Validation
UI Changes
Two new animations on every fresh deal: the old board sweeps off the table under a palm stroke, then the new board deals in card by card from the stock (or from above the board for stockless variants), with sound and haptic at takeoff. Both respect the Animation Speed setting and Reduce Motion.