fix: center trick pile; add error boundary (surface post-buy crash)
- Trick area: smaller offsets (±50/52) + retuned scale so the played pile sits centered in the felt instead of flung out to the side seats. - ErrorBoundary around screens + overlays: a render error now shows a recoverable in-app message with the cause (and logs componentStack) instead of the browser's blank "page couldn't load" — helps pinpoint the post-purchase crash. Verified: tsc + next build clean; web rebuilt on :1500. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
+10
-7
@@ -21,6 +21,7 @@ import { NotificationToaster } from "@/components/online/NotificationToaster";
|
||||
import { ResumeGameBar } from "@/components/online/ResumeGameBar";
|
||||
import { CelebrationOverlay } from "@/components/online/CelebrationOverlay";
|
||||
import { MusicToggle } from "@/components/online/MusicToggle";
|
||||
import { ErrorBoundary } from "@/components/ErrorBoundary";
|
||||
import { PublicProfileModal } from "@/components/online/PublicProfileModal";
|
||||
import { CapacitorBack } from "@/components/CapacitorBack";
|
||||
import { useSessionStore } from "@/lib/session-store";
|
||||
@@ -193,13 +194,15 @@ export default function Page() {
|
||||
// reducedMotion="user" makes every Framer Motion animation honor the OS
|
||||
// "reduce motion" accessibility setting (coin rain, confetti, count-ups…).
|
||||
<MotionConfig reducedMotion="user">
|
||||
{renderScreen(screen)}
|
||||
<DailyRewardModal />
|
||||
<NotificationToaster />
|
||||
<ResumeGameBar />
|
||||
<CelebrationOverlay />
|
||||
<MusicToggle />
|
||||
<PublicProfileModal />
|
||||
<ErrorBoundary>
|
||||
{renderScreen(screen)}
|
||||
<DailyRewardModal />
|
||||
<NotificationToaster />
|
||||
<ResumeGameBar />
|
||||
<CelebrationOverlay />
|
||||
<MusicToggle />
|
||||
<PublicProfileModal />
|
||||
</ErrorBoundary>
|
||||
<CapacitorBack />
|
||||
{loading && null}
|
||||
</MotionConfig>
|
||||
|
||||
Reference in New Issue
Block a user