Skip to content

chore: back-merge main → dev (manicero badge, pre SP-151 release)#2434

Merged
jjramirezn merged 7 commits into
devfrom
chore/backmerge-main-into-dev-20260716
Jul 16, 2026
Merged

chore: back-merge main → dev (manicero badge, pre SP-151 release)#2434
jjramirezn merged 7 commits into
devfrom
chore/backmerge-main-into-dev-20260716

Conversation

@jjramirezn

Copy link
Copy Markdown
Contributor

Clean back-merge (merge-tree probe: no conflicts) of the manicero-badge hotfixes (#2431) that landed on main after #2429. Keeps dev a superset of main before the SP-151 release PR merges. Release page: https://app.notion.com/p/peanutprotocol/prod-release-sp-151-39f83811757980f6bcc5c118239d4758

🤖 Generated with Claude Code

abalinda and others added 7 commits July 16, 2026 14:57
FE half of the Manicero badge (Argentine superfan in-joke, IYKYK).
Claimable by existing users via bare ?campaign=manicero link (vanity,
no waitlist skip) and by new users via ?code=manicero invite flow.
Art + copy from Konrad's pick in mono inbox/manicero-badge/.
Review finding: every sibling event badge has a UTM_CAMPAIGN_TO_BADGE_MAP
alias; without it a ?utm_campaign=manicero link silently grants nothing.
Also feeds PostHog's utm_* auto-capture for the campaign funnel.
feat(badges): add MANICERO badge asset + claim maps
The shared withdraw amount step applied getMinimumAmount() to every
method; crypto has no country so it fell into the $1 default — blocking
sub-$1 on-chain sends that send-via-link already allows. The minimum
was introduced for bank offramps (295c8ec, Bridge's $1 floor) and
crypto only inherited it by sharing the page. Bank rails keep their
country minimums.
…m Rhino deposits

Review findings on the initial cut:

- The exemption keyed off the URL param independently of routing: a stale
  bank selectedMethod (app-wide context) entering via /withdraw?method=crypto
  got min=$0 while Continue still routed to the bank flow. The predicate now
  follows selectedMethod when set; the URL only covers the pre-effect frame.
- Removing the blanket $1 floor exposed the cross-chain path to sub-minimum
  Rhino SDA deposits, which are accepted on-chain but never bridged (stranded,
  uncredited — known incident class). The confirm CTA now blocks below the
  route's minDepositLimitUsd, which the page previously discarded.
- Consolidated the two other inline is-crypto checks onto the same predicate,
  stopped the exchange-rate poll when crypto is selected, dropped a vacuous
  test assertion.
…iat-min

fix: exempt crypto withdrawals from the fiat $1 minimum
@vercel

vercel Bot commented Jul 16, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
peanut-wallet Ready Ready Preview, Comment Jul 16, 2026 4:47pm

Request Review

@coderabbitai

coderabbitai Bot commented Jul 16, 2026

Copy link
Copy Markdown
Contributor

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: bdf33686-4eb9-4c34-832d-072f43e2f2e8

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch chore/backmerge-main-into-dev-20260716

Comment @coderabbitai help to get the list of available commands.

@github-actions

Copy link
Copy Markdown
Contributor

Code-analysis diff

Painscore total: 6205.21 → 6206.68 (+1.47)
Findings: 0 net (+31 new, -31 resolved)

🆕 New findings (31)

  • critical complexity — src/app/(mobile-ui)/withdraw/page.tsx — CC 125, MI 53.75, SLOC 339
  • critical complexity — src/app/(mobile-ui)/withdraw/crypto/page.tsx — CC 78, MI 53.1, SLOC 335
  • critical complexity — src/utils/withdraw.utils.ts — CC 70, MI 53.78, SLOC 250
  • high complexity — src/components/Withdraw/views/Confirm.withdraw.view.tsx — CC 44, MI 62.05, SLOC 42
  • high hotspot — src/components/Badges/badge.utils.ts — 36 commits, +375/-110 lines since 6 months ago
  • high complexity — src/components/Badges/badge.utils.ts — CC 10, MI 46.25, SLOC 157
  • medium react-long-component — src/app/(mobile-ui)/withdraw/crypto/page.tsx:43 — WithdrawCryptoPage is 528 lines — split it
  • medium react-long-component — src/app/(mobile-ui)/withdraw/page.tsx:28 — WithdrawPage is 449 lines — split it
  • medium high-mdd — src/app/(mobile-ui)/withdraw/page.tsx:28 — WithdrawPage: MDD 104.5 (uses across many lines from declarations)
  • medium high-mdd — src/app/(mobile-ui)/withdraw/crypto/page.tsx:43 — WithdrawCryptoPage: MDD 92.3 (uses across many lines from declarations)
  • medium high-dlt — src/app/(mobile-ui)/withdraw/crypto/page.tsx:43 — WithdrawCryptoPage: DLT 52 (calls 52 distinct functions — high context load)
  • medium high-mdd — src/components/Withdraw/views/Confirm.withdraw.view.tsx:67 — ConfirmWithdrawView: MDD 51.2 (uses across many lines from declarations)
  • medium method-complexity — src/app/(mobile-ui)/withdraw/page.tsx:28 — WithdrawPage CC 28 SLOC 111
  • medium method-complexity — src/components/Withdraw/views/Confirm.withdraw.view.tsx:67 — ConfirmWithdrawView CC 28 SLOC 21
  • medium high-mdd — src/app/(mobile-ui)/withdraw/crypto/page.tsx:278 — : MDD 23.6 (uses across many lines from declarations)
  • medium hotspot — src/app/(mobile-ui)/withdraw/crypto/page.tsx — 24 commits, +253/-158 lines since 6 months ago
  • medium method-complexity — src/app/(mobile-ui)/withdraw/page.tsx:274 — CC 17 SLOC 55
  • medium method-complexity — src/app/(mobile-ui)/withdraw/crypto/page.tsx:278 — CC 16 SLOC 82
  • medium complexity — src/components/Invites/campaign-maps.ts — CC 14, MI 56.93, SLOC 42
  • medium react-effect-derives-state — src/app/(mobile-ui)/withdraw/crypto/page.tsx:123 — small useEffect that only sets state from deps

…and 11 more.

✅ Resolved (31)

  • src/app/(mobile-ui)/withdraw/page.tsx — CC 122, MI 53.88, SLOC 336
  • src/app/(mobile-ui)/withdraw/crypto/page.tsx — CC 75, MI 52.78, SLOC 329
  • src/utils/withdraw.utils.ts — CC 66, MI 53.52, SLOC 242
  • src/components/Withdraw/views/Confirm.withdraw.view.tsx — CC 40, MI 62.27, SLOC 42
  • src/components/Badges/badge.utils.ts — 35 commits, +369/-110 lines since 6 months ago
  • src/components/Badges/badge.utils.ts — CC 10, MI 46.55, SLOC 153
  • src/app/(mobile-ui)/withdraw/crypto/page.tsx:42 — WithdrawCryptoPage is 515 lines — split it
  • src/app/(mobile-ui)/withdraw/page.tsx:28 — WithdrawPage is 443 lines — split it
  • src/app/(mobile-ui)/withdraw/page.tsx:28 — WithdrawPage: MDD 102.0 (uses across many lines from declarations)
  • src/app/(mobile-ui)/withdraw/crypto/page.tsx:42 — WithdrawCryptoPage: MDD 89.6 (uses across many lines from declarations)
  • src/app/(mobile-ui)/withdraw/crypto/page.tsx:42 — WithdrawCryptoPage: DLT 51 (calls 51 distinct functions — high context load)
  • src/components/Withdraw/views/Confirm.withdraw.view.tsx:61 — ConfirmWithdrawView: MDD 51.2 (uses across many lines from declarations)
  • src/app/(mobile-ui)/withdraw/page.tsx:28 — WithdrawPage CC 26 SLOC 110
  • src/app/(mobile-ui)/withdraw/crypto/page.tsx:276 — : MDD 23.6 (uses across many lines from declarations)
  • src/components/Withdraw/views/Confirm.withdraw.view.tsx:61 — ConfirmWithdrawView CC 24 SLOC 21
  • src/utils/general.utils.ts — 24 commits, +134/-152 lines since 6 months ago
  • src/app/(mobile-ui)/withdraw/page.tsx:266 — CC 17 SLOC 55
  • src/app/(mobile-ui)/withdraw/crypto/page.tsx:276 — CC 16 SLOC 82
  • src/components/Invites/campaign-maps.ts — CC 14, MI 57.49, SLOC 40
  • src/app/(mobile-ui)/withdraw/crypto/page.tsx:121 — small useEffect that only sets state from deps

…and 11 more.

@github-actions

Copy link
Copy Markdown
Contributor

🧪 UI test report — ✅ all green

Suites

  • unit: 1992 ran, 0 failed, 0 skipped, 25.3s

📊 Coverage (unit)

metric %
statements 59.6%
branches 43.2%
functions 48.5%
lines 59.9%
⏱ 10 slowest test cases
time test
2.5s src/components/Card/share-asset/__tests__/shareAssetLayout.test.ts › never places two stickers in heavy overlap (broad seed sweep)
0.9s src/utils/__tests__/demo-api.test.ts › isDemoMode() is false when not running under Capacitor
0.3s src/components/Card/share-asset/__tests__/shareAssetLayout.test.ts › every sticker stays within canvas at any count
0.3s src/app/actions/__tests__/api-headers.test.ts › should include Content-Type in validateInviteCode
0.3s src/app/(mobile-ui)/withdraw/__tests__/withdraw-states.test.tsx › Bank withdrawal keeps the $1 minimum for sub-$1 amounts
0.2s src/app/actions/__tests__/api-headers-extended.test.ts › should not include apiKey in validateInviteCode body
0.2s src/components/Card/share-asset/__tests__/shareAssetLayout.test.ts › keeps stickers off the username pill (final pass respects the keep-out)
0.1s src/components/Global/GeneralRecipientInput/__tests__/GeneralRecipientInput.test.tsx › should handle valid 9-digit US account
0.1s src/components/Global/GeneralRecipientInput/__tests__/GeneralRecipientInput.test.tsx › should handle invalid ETH address (missing 0x prefix)
0.1s src/utils/__tests__/demo-balance.test.ts › starts at the full balance on a fresh install and stamps a timestamp
📍 Inline annotations are in the **Unit test report** check above. Coverage artifact: `coverage-unit`. Generated by `.github/workflows/tests.yml`.

@jjramirezn jjramirezn merged commit 679905f into dev Jul 16, 2026
18 of 20 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants