✨ app: surface funding banner#1149
Conversation
🦋 Changeset detectedLatest commit: 9352f77 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
|
Warning Review limit reached
Next review available in: 59 minutes Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Pro Run ID: 📒 Files selected for processing (10)
WalkthroughCard activation now uses account bytecode checks, while a shared funding banner guides users to add funds or swap supported assets. The banner is rendered on home and card screens, with new translations, swap preset access, spell-check entries, and mobile patch changesets. ChangesFunding and card activation flow
Estimated code review effort: 3 (Moderate) | ~20 minutes Sequence Diagram(s)sequenceDiagram
participant User
participant FundingAlert
participant Portfolio
participant ReactQuery
participant Router
User->>FundingAlert: view home or card screen
FundingAlert->>Portfolio: read portfolio and external assets
FundingAlert->>ReactQuery: query KYC status and account bytecode
alt swappable assets exist
User->>FundingAlert: select swap action
FundingAlert->>ReactQuery: seed swap preset data
ReactQuery-->>FundingAlert: return swap data
FundingAlert->>Router: navigate to /swaps
else no swappable assets
User->>FundingAlert: select add-funds action
FundingAlert->>Router: navigate to /add-funds
end
Suggested reviewers: 🚥 Pre-merge checks | ✅ 4✅ Passed checks (4 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
✨ Simplify code
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 |
There was a problem hiding this comment.
Code Review
This pull request introduces a new FundingAlert component to display a funding banner on the home and card screens, and updates the card activation logic to allow activation without deposits by checking for bytecode instead of a USD balance. The review feedback highlights two key improvements: first, refining the banner visibility check to account for supported assets already in the user's wallet (not just deposited in the protocol) to prevent incorrect 'Add funds' prompts; second, ensuring the swap mutation throws an error on missing preconditions and only redirects to the swaps screen upon a successful mutation.
Important
The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.
There was a problem hiding this comment.
Actionable comments posted: 3
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: ASSERTIVE
Plan: Pro
Run ID: c483001f-4f79-4241-a657-d6cadeec10ae
📒 Files selected for processing (9)
.changeset/odd-clubs-carry.md.changeset/witty-crabs-arrive.mdsrc/components/card/Card.tsxsrc/components/home/Home.tsxsrc/components/shared/FundingAlert.tsxsrc/components/swaps/Swaps.tsxsrc/i18n/es-AR.jsonsrc/i18n/es.jsonsrc/i18n/pt.json
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 808508a60f
ℹ️ About Codex in GitHub
Codex has been enabled to automatically 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 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #1149 +/- ##
==========================================
- Coverage 73.27% 70.65% -2.62%
==========================================
Files 254 262 +8
Lines 10839 11267 +428
Branches 3598 3779 +181
==========================================
+ Hits 7942 7961 +19
- Misses 2613 3022 +409
Partials 284 284
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
a45bff6 to
7ecc3d2
Compare
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 7ecc3d2403
ℹ️ About Codex in GitHub
Codex has been enabled to automatically 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 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
There was a problem hiding this comment.
Actionable comments posted: 1
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: ASSERTIVE
Plan: Pro
Run ID: 3f7e69e7-bd01-4c2e-9487-162cc7e8f07f
📒 Files selected for processing (10)
.changeset/odd-clubs-carry.md.changeset/witty-crabs-arrive.mdcspell.jsonsrc/components/card/Card.tsxsrc/components/home/Home.tsxsrc/components/shared/FundingAlert.tsxsrc/components/swaps/Swaps.tsxsrc/i18n/es-AR.jsonsrc/i18n/es.jsonsrc/i18n/pt.json
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 33d547fba4
ℹ️ About Codex in GitHub
Codex has been enabled to automatically 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 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
| const [bridgeable] = [...crossChainAssets].sort((a, b) => b.usdValue - a.usdValue); | ||
| if (bridgeable) { | ||
| router.push({ | ||
| pathname: "/(main)/add-funds/bridge", | ||
| params: { sender: "exa", sourceChain: String(bridgeable.chainId), sourceToken: bridgeable.address }, |
There was a problem hiding this comment.
Filter unsupported cross-chain sources before bridging
When the only cross-chain balance is on a chain that the existing external-assets flow treats as unsupported (not in alchemyChainById, or the Exa account is undeployed on that chain), this branch can still select it and push directly into the Exa-sender bridge route. I checked ExternalAssets.tsx, which gates the same bridge route with isUnsupported(...) and shows the unsupported-network sheet instead, so this banner bypasses that guard and can send users to a bridge flow their account cannot execute.
Useful? React with 👍 / 👎.
closes #1133
Summary by CodeRabbit