Skip to content

Add BNB Chain support to bridge and balance breakdown#2117

Merged
MusabShakeel576 merged 1 commit into
qafrom
claude/relaxed-darwin-urPFW
Jun 3, 2026
Merged

Add BNB Chain support to bridge and balance breakdown#2117
MusabShakeel576 merged 1 commit into
qafrom
claude/relaxed-darwin-urPFW

Conversation

@MusabShakeel576
Copy link
Copy Markdown
Contributor

Summary

This PR adds support for BNB Chain (BSC) to the bridge functionality and balance breakdown components. It includes configuration for USDC bridging on BSC and integrates BSC with the Alchemy data provider.

Key Changes

  • Bridge Configuration: Added BNB Chain to BRIDGE_TOKENS with Binance-Peg USDC (18 decimals) support
  • Token Decimals: Enhanced BridgeToken type with optional decimals field and updated deposit logic to dynamically derive token decimals from bridge config instead of hardcoding to 6
  • Alchemy Integration: Added BSC to Alchemy-supported chains with appropriate RPC endpoint configuration
  • UI Updates: Added BSC chain icon and name to balance breakdown component
  • Thirdweb Support: Imported and registered BSC in the Thirdweb chain configuration
  • Assets: Added BSC chain icon asset (bsc.png)

Notable Implementation Details

  • The useDepositFromEOA hook now dynamically determines source token decimals from the bridge configuration, accommodating chains like BSC where USDC uses 18 decimals instead of the standard 6
  • BSC is configured as Alchemy-only (no Blockscout fallback) due to Blockscout's lack of BSC support
  • Fuse's sort order was adjusted from 5 to 6 to accommodate BSC at sort order 5

https://claude.ai/code/session_013JRn2tvDbZssJGAx4b6gJX

Add Binance-Peg USD Coin (USDC, 0x8AC76a51cc950d9822D68b83fE1Ad97B32Cd580d)
on BNB Chain as a new bridge deposit source in the Add Funds ("send from
your crypto wallet" + "share your deposit address") and Deposit-to-Savings
(USDC vault) flows, alongside Polygon/Arbitrum.

- constants/bridge.ts: BSC entry (USDC, 18 decimals, isPermit false) + gold
  circular BNB icon; add optional decimals to BridgeToken type
- lib/thirdweb.ts: register bsc chain so switchChain works in the
  connected-wallet deposit flow
- hooks/useDepositFromEOA.ts: derive source-token decimals from the bridge
  config instead of hardcoding 6 (BSC USDC is 18 decimals)
- constants/alchemy.ts: enable BSC token-balance fetching via Alchemy
- components/Coin/BalanceBreakdown.tsx: map the BSC chain icon + name in the
  coin detail network breakdown
- assets/images/bsc.png + lib/assets.ts: circular gold BNB Chain icon

https://claude.ai/code/session_013JRn2tvDbZssJGAx4b6gJX
@vercel
Copy link
Copy Markdown

vercel Bot commented Jun 3, 2026

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

2 Skipped Deployments
Project Deployment Actions Updated (UTC)
solid-app Ignored Ignored Jun 3, 2026 1:09pm
solid-app-staging Ignored Ignored Jun 3, 2026 1:09pm

Request Review

@MusabShakeel576 MusabShakeel576 merged commit d34a912 into qa Jun 3, 2026
4 of 5 checks passed
@MusabShakeel576 MusabShakeel576 deleted the claude/relaxed-darwin-urPFW branch June 3, 2026 13:11
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.

2 participants