Skip to content

About

Frontend for Karma

Resources

Contributing

Security policy

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

224 Commits

Folders and files

Repository files navigation

Stability Nexus Karma Protocol bull and bear logo

 

Static Badge

Telegram Badge    X (formerly Twitter) Badge    Discord Badge    Medium Badge    LinkedIn Badge    Youtube Badge


Karma Protocol

Karma Protocol is a permissionless on-chain oracle and perpetual prediction market platform. It weights submitted price observations by participants' opposing Bull and Bear exposure.

Built with cutting-edge Web3 technologies, Karma Protocol delivers high-performance trading experiences with gas-optimized smart contracts and real-time community price discovery.

✨ Key Features

  • Neutrality-Weighted Consensus: Voting power is determined on-chain by min(Bull, Bear) holdings—one-sided speculators have zero influence
  • Exponential Time Decay: Price observations decay smoothly over time, keeping the oracle responsive to fresh market conditions
  • Perpetual Market: Continuous trading without expiration dates; enter and exit positions at any time
  • Mainnet Wallet Support: Ethereum Mainnet is available in wallet and explorer configuration
  • Chainlink-Compatible Interface: Seamless drop-in replacement for standard AggregatorV3Interface consumers
  • Client-Side IndexedDB Caching: Fast and responsive offline-first portfolio and pool browsing

Launch Configuration

Ethereum Mainnet has no verified Karma oracle factory or pool factory configured in this repository. Pool creation is disabled when a required factory or supported price feed is missing. Add verified deployment addresses and feed configuration before enabling customer transactions on Mainnet.


Technical Architecture

Frontend

  • Next.js 15 (App Router): Server-side rendering, dynamic routes, and fast static delivery
  • TypeScript & React 19: Strictly typed components and state management
  • Tailwind CSS: Custom Amber/Gold/Emerald theme with glassmorphic aesthetics
  • Wagmi & Viem: EVM interactions, multicalls, event log indexing, and wallet connectivity
  • IndexedDB: Persistent local storage for user trade history and cached pool details

Getting Started

Prerequisites

  • Node.js 18+
  • npm / pnpm / yarn
  • Web3 wallet extension (e.g. MetaMask, Coinbase Wallet, Rabby)

Installation

1. Clone the Repository

git clone https://github.com/StabilityNexus/Karma-EVM-Frontend.git
cd Karma-EVM-Frontend

2. Install Dependencies

npm install

3. Run the Development Server

npm run dev

4. Open your Browser

Navigate to http://localhost:3000 to view the application.


Project Structure

src/
├── app/
│   ├── [pool]/            # Pool interactions & Karma Consensus Power
│   ├── createPool/        # Karma pool creation
│   ├── explorePools/      # Pool discovery & filtering
│   ├── portfolio/         # User portfolio & trade history
│   ├── settings/          # Cache management & backup export/import
│   ├── submitPrice/       # Price observation submissions & consensus
│   ├── globals.css        # Theme styles & animations (standard smooth cursor)
│   ├── layout.tsx         # Root layout with Navbar and providers
│   └── page.tsx           # Home landing page with dynamic Hero & About
├── components/            # Reusable UI components
│   ├── Explore/           # Pool exploration & table/grid views
│   ├── Forms/             # CreateKarmaPool and multi-step configuration
│   ├── Home/              # Hero, protocol architecture, and feature cards
│   ├── KarmaPoolCard/     # PredictionCard & RangeSlider
│   ├── Portfolio/         # TradeHistoryCard & position analytics
│   ├── layout/            # Navbar, Footer, and Navigation
│   └── ui/                # Base UI components (buttons, dialogs, inputs)
├── hooks/                 # React hooks (useIndexedDB)
├── lib/                   # Utilities (karmaPoolHook, scanLogs, estimateBuy/Sell)
└── utils/                 # Configuration (addresses, chainConfig, ABIs)

Building and Testing

# Run unit and validation test suites
npm test

# Build production bundle
npm run build

Contributing

We welcome contributions of all kinds. Questions and ideas are welcome in our Discord channel.

© 2026 The Stable Order.

About

Frontend for Karma

Resources

Contributing

Security policy

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages