The front-end interface for Hakata Finance's perpetual trading protocol on Solana.
This UI provides traders with a seamless interface to interact with the Hakata Perpetuals protocol. Built with Next.js and modern web technologies, it offers a responsive and intuitive trading experience.
- Next.js - React framework with App Router
- TypeScript - Type-safe JavaScript
- TailwindCSS - Utility-first CSS framework
- Solana Web3.js - Solana JavaScript API
- Geist Font - Modern typeface by Vercel
packages/ui/
├─ src/ # Source code
│ ├─ app/ # Next.js App Router structure
│ │ ├─ api/ # API routes
│ │ ├─ trade/ # Trading pages
│ │ ├─ vault/ # Vault pages
│ │ ├─ leaderboard/ # Leaderboard pages
│ │ ├─ faucet/ # Faucet page
│ │ ├─ page.tsx # Homepage
│ │ ├─ layout.tsx # Root layout component
│ │ └─ globals.css # Global styles
│ ├─ components/ # Shared UI components
│ ├─ hooks/ # Custom React hooks
│ ├─ lib/ # Library code and API wrappers
│ ├─ actions/ # Server actions
│ ├─ stores/ # State management
│ └─ context/ # React context providers
├─ public/ # Static assets
├─ tailwind.config.ts # Tailwind configuration
├─ next.config.ts # Next.js configuration
└─ package.json # Dependencies and scripts
- Node.js 18.x or higher
- npm, yarn, or pnpm
# Install dependencies
npm install
# or
yarn install
# or
pnpm install# Start development server
npm run dev
# or
yarn dev
# or
pnpm devOpen http://localhost:3000 with your browser to see the result.
# Build the application
npm run build
# or
yarn build
# or
pnpm build
# Start production server
npm run start
# or
yarn start
# or
pnpm startThe UI can be configured to connect to different environments:
- Local development (default)
- Devnet
- Mainnet
Environment variables can be set in .env file:
NEXT_PUBLIC_SOLANA_NETWORK=mainnet-beta
NEXT_PUBLIC_RPC_ENDPOINT=https://your-rpc-endpoint.com
We welcome contributions to improve the UI:
- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'feat: Add some amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
- Next.js Documentation - Learn about Next.js features
- Hakata Perpetuals Documentation - Learn about the protocol