A Vite-powered React 18 + TypeScript desktop application with Tauri backend for tracking cryptocurrency markets, connecting to Solana wallets, and analyzing market data.
- Phantom Wallet Integration: First-class Phantom wallet connectivity with persistent sessions
- Ledger Hardware Wallet Support: Secure Solana transaction signing via Ledger devices using WebHID
- Real-time Market Data: Live price tickers, charts, and order book data
- Trading Tools: Swap form, automation rules, and risk indicators
- Multi-Module Dashboard: Navigate between Coins, Stocks, Insiders, Trading, and Settings
- Sentiment Analysis: AI-powered text sentiment and risk assessment
- Tauri Backend: Rust-based commands for wallet management, market data, and API integrations
- Node.js (v18 or higher)
- Rust (latest stable)
- Tauri CLI
- Phantom Wallet browser extension (for wallet connectivity)
-
Clone the repository:
git clone <repository-url> cd eclipse-market-pro
-
Install dependencies:
npm install
-
Configure environment variables (optional): Create a
.envfile in the project root:VITE_SOLANA_NETWORK=mainnet-beta VITE_SOLANA_RPC_ENDPOINT=https://api.mainnet-beta.solana.com SOLANA_RPC_ENDPOINT=https://api.mainnet-beta.solana.com
Run the app in development mode:
npm run tauri devThe project uses Prettier and ESLint to maintain a consistent code style.
- Format code automatically:
npm run format
- Check formatting without modifying files:
npm run format:check
- Run ESLint:
npm run lint
Build the application for production:
npm run tauri buildThe application provides seamless Phantom wallet integration with the following features:
- Auto-Reconnect: Automatically reconnects to your previously connected wallet on app launch
- Persistent Sessions: Wallet state is persisted across app restarts using both localStorage and Tauri backend storage
- Network Support: Supports Mainnet, Devnet, and Testnet
- Balance Tracking: Real-time SOL balance updates every 15 seconds
- Error Handling: Graceful handling of user rejections, network errors, and missing wallet providers
- Connect Wallet: Click the "Connect Wallet" button in the top-right corner
- Approve Connection: Approve the connection request in your Phantom wallet
- View Balance: Your wallet address and SOL balance will be displayed
- Disconnect: Click the "Disconnect" button to end the session
The Phantom integration consists of:
- Frontend Store (
src/store/walletStore.ts): Zustand store managing wallet state with persistence - UI Component (
src/components/wallet/PhantomConnect.tsx): React component for wallet connection UI - Wallet Provider (
src/providers/SolanaWalletProvider.tsx): Solana wallet adapter context provider - Backend Commands (
src-tauri/src/wallet/phantom.rs): Rust Tauri commands for session management and balance queries
The following Tauri commands are available:
phantom_connect: Connect and persist a wallet sessionphantom_disconnect: Disconnect and clear the sessionphantom_session: Retrieve the current sessionphantom_balance: Fetch the SOL balance for an addressphantom_sign_message: Verify a signed message (client-side signing via adapter)phantom_sign_transaction: Verify a signed transaction (client-side signing via adapter)
| Variable | Description | Default |
|---|---|---|
VITE_SOLANA_NETWORK |
Solana network (mainnet-beta, devnet, testnet) | devnet |
VITE_SOLANA_RPC_ENDPOINT |
Custom RPC endpoint URL | Network default |
SOLANA_RPC_ENDPOINT |
Backend RPC endpoint URL | Network default |
- Chrome/Chromium, Edge, or Opera with WebHID support
- Ledger firmware 2.1.0+
- Solana app installed and opened on the device
- Secure transaction signing through Ledger hardware wallets using WebHID
- Address derivation with on-device verification
- Transaction validation and error handling
- Tauri backend state management for connected devices
- Open the Hardware Wallet Manager from Settings
- Connect the Ledger device via USB and unlock it
- Open the Solana app on the Ledger device
- Use the "Connect Ledger" flow to pair the device
- Derive and verify addresses on the device screen
- Sign transactions through the Ledger device during trading
- Service (
src/utils/ledger.ts): Wraps Ledger WebHID and Solana app APIs - Hook (
src/hooks/useLedger.ts): React hook for managing connection state - UI (
src/components/wallet/LedgerConnect.tsx): Guided connection and signing UI - Backend (
src-tauri/src/wallet/ledger.rs): Device registry and validation commands
For implementation details see LEDGER_INTEGRATION.md.
Eclipse Market Pro features a comprehensive animation system with lunar/eclipse-inspired motion primitives built on Framer Motion. The system includes:
- Reusable Animation Primitives: Orbital transitions, constellation effects, corona glows
- Shared Components: Eclipse loaders, moon phase indicators, progress bars, constellation backgrounds
- Parallax Effects: Scroll-based depth and ambient motion
- Accessibility First: Full support for reduced motion preferences
- Performance Optimized: Memoized components and GPU-accelerated transforms
See the Animation Guide for detailed documentation on:
- Animation tokens (durations, easings)
- Component usage examples
- Accessibility implementation
- Performance guidelines
- Testing strategies
eclipse-market-pro/
├── src/
│ ├── components/
│ │ ├── wallet/
│ │ │ ├── PhantomConnect.tsx
│ │ │ ├── LedgerConnect.tsx
│ │ │ └── HardwareWalletManager.tsx
│ │ ├── ApiSettings.tsx
│ │ ├── LiveChart.tsx
│ │ └── ...
│ ├── hooks/
│ │ ├── useWallet.ts
│ │ ├── useLedger.ts
│ │ └── ...
│ ├── utils/
│ │ ├── ledger.ts
│ │ └── ...
│ ├── pages/
│ │ ├── Dashboard.tsx
│ │ └── ...
│ ├── providers/
│ │ └── SolanaWalletProvider.tsx
│ ├── store/
│ │ └── walletStore.ts
│ ├── App.tsx
│ └── main.tsx
├── src-tauri/
│ ├── src/
│ │ ├── wallet/
│ │ │ ├── mod.rs
│ │ │ ├── phantom.rs
│ │ │ ├── ledger.rs
│ │ │ └── hardware_wallet.rs
│ │ ├── lib.rs
│ │ └── ...
│ └── Cargo.toml
├── package.json
├── LEDGER_INTEGRATION.md
└── README.md
- React 18
- TypeScript
- Vite
- Tailwind CSS
- Framer Motion
- Lucide React (icons)
- @solana/wallet-adapter-react
- @solana/wallet-adapter-phantom
- @solana/web3.js
- @ledgerhq/hw-transport-webhid
- @ledgerhq/hw-app-solana
- Zustand (state management)
- Recharts / Lightweight Charts
- Tauri
- solana-client
- solana-sdk
- serde / serde_json
- tokio
- reqwest
- base64
- bincode
- chrono
[Your License Here]
Contributions are welcome! Please open an issue or submit a pull request.