How artxds/solana-wallet-hub works
Solana Wallet Hub is a browser wallet for connecting a Solana account, viewing its balance and recent activity, switching Devnet/Mainnet, sending SOL, and requesting Devnet faucet funds. Users enter through the Next.js pages into WalletHub; its balance and history hooks read chain data, while the send form and confirmation flow lead to a wallet-signed transfer. The faucet is a separate API route. Evidence is limited to the README, SOURCE INDEX relationships, and the excerpts shown; unsampled implementation details are not inferred.
Main entry points: WalletHub.tsx Wallet hub · app Wallet pages · SendForm.tsx Send form · SolanaProvider.tsx Solana provider
Components 18
Application UI
- Wallet pages
app - Wallet hub
src/components/layout/WalletHub.tsx - History list
src/components/history/HistoryList.tsx - Send form
src/components/send/SendForm.tsx - Transfer review
src/components/send/ConfirmationModal.tsx - Balance card
src/components/wallet/BalanceCard.tsx
Wallet and network
- Solana provider
src/components/providers/SolanaProvider.tsx - Network settings
src/components/layout/NetworkSettings.tsx - Network switcher
src/components/layout/NetworkSwitcher.tsx
Wallet activity
- Balance query
src/hooks/useSolanaBalance.ts - History query
src/hooks/useTransactionHistory.ts - SOL price query
src/hooks/useSolPrice.ts - Transfer builder
src/lib/solana/transactions.ts - Devnet faucet API
app/api/faucet/route.ts
External services
- Wallet adapter
- Solana RPC
- Jupiter price API
Other components
- Wallet user
Connections 22
- Wallet user → Wallet pages: opens app
app/page.tsx - Wallet pages → Wallet hub: routes views
app/balance/page.tsx - Wallet pages → Wallet hub: opens home
app/page.tsx - Wallet user → Wallet adapter: connects wallet
README.md - Wallet hub → Solana provider: reads network
src/components/layout/WalletHub.tsx - Solana provider → Wallet adapter: provides connection
- Network settings → Network switcher: offers switching
- Wallet hub → Balance query: loads balance
src/components/layout/WalletHub.tsx - Wallet hub → History query: loads activity
src/components/layout/WalletHub.tsx - Wallet hub → SOL price query: loads price
src/components/layout/WalletHub.tsx - Balance query → Solana RPC: queries balance
src/hooks/useSolanaBalance.ts - History query → Solana RPC: queries transactions
src/hooks/useTransactionHistory.ts - SOL price query → Jupiter price API: fetches price
src/hooks/useSolPrice.ts - Wallet hub → Balance card: renders balance
src/components/layout/WalletHub.tsx - Wallet hub → History list: renders history
src/components/layout/WalletHub.tsx - Wallet hub → Send form: renders form
src/components/layout/WalletHub.tsx - Send form → Wallet hub: requests review
src/components/layout/WalletHub.tsx - Wallet hub → Transfer review: opens review
src/components/layout/WalletHub.tsx - Wallet hub → Transfer builder: builds transfer
src/components/layout/WalletHub.tsx - Wallet hub → Wallet adapter: submits transfer
src/components/layout/WalletHub.tsx - Wallet hub → Devnet faucet API: requests airdrop
src/components/layout/WalletHub.tsx - Wallet user → Devnet faucet API: requests funds
README.md