Repository navigation
fix(ui): remove double loading animation on app startup - #386
Conversation
The loading screen was playing a forward slide transition on startup (SVG slides left, new one enters from right) because two independent mechanisms were both trying to show the Loading page: 1. Inline render guard (line 172) — shows Loading when init conditions aren't met 2. useEffect navigate (line 112) — called navigate(Pages.Loading), which redundantly set direction to 'forward' and triggered AnimatePresence to re-animate the already-visible Loading page Removed the navigate(Pages.Loading) call and replaced with a plain early return. The inline guard already handles rendering Loading; the useEffect guard only needs to prevent premature navigation to Onboard/Unlock before wallet data is loaded.
Deploying wallet-bitcoin with
|
| Latest commit: |
8bc6740
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://93302809.wallet-bitcoin.pages.dev |
| Branch Preview URL: | https://wt-fix-loading-double-flash.wallet-bitcoin.pages.dev |
Deploying wallet-mutinynet with
|
| Latest commit: |
8bc6740
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://da081bdb.arkade-wallet.pages.dev |
| Branch Preview URL: | https://wt-fix-loading-double-flash.arkade-wallet.pages.dev |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
WalkthroughModified wallet-loading redirect logic in Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Suggested reviewers
🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
tACK |
|
This seems a nobrainer cc/ @Kukks |
Summary
navigate(Pages.Loading)call in a useEffect (line 112). The navigate call redundantly setdirection: 'forward', triggering AnimatePresence to re-animate the already-visible Loading page.navigate(Pages.Loading)with a plain earlyreturn. The inline guard already renders Loading; the useEffect only needs to prevent premature navigation before wallet data loads.Changes
src/App.tsx— one line:if (!walletLoaded) return navigate(Pages.Loading)→if (!walletLoaded) returnTest plan
Summary by CodeRabbit