Skip to content

mumair738/core-oracle

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

40 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

CoreOracle - Decentralized Prediction Market

A modern, full-featured decentralized prediction market built on Core Blockchain where users can make predictions on various future events and earn CORE tokens for accurate predictions.

CoreOracle Banner

🌟 Features

Core Functionality

  • πŸ“Š Prediction Markets - Create and participate in prediction markets for crypto, sports, finance, and politics
  • πŸ’° CORE Token Rewards - Earn CORE tokens for accurate predictions
  • πŸ”’ Secure Smart Contracts - Built on Core Blockchain for transparency and security
  • πŸ“± Responsive Design - Works seamlessly on desktop, tablet, and mobile devices

User Experience

  • 🎯 Intuitive Betting Interface - Easy-to-use betting system with real-time odds
  • πŸ“ˆ Live Market Data - Real-time market updates and price movements
  • πŸ† Leaderboards - Compete with other users and track your ranking
  • πŸ“Š Personal Dashboard - Track your bets, earnings, and performance
  • πŸŽ–οΈ Achievement System - Unlock badges and achievements for milestones

Market Features

  • πŸ” Advanced Filtering - Search and filter markets by category, volume, and time
  • ⏰ Real-time Odds - Dynamic odds that update based on market activity
  • πŸ“‹ Market Details - Comprehensive market information and resolution criteria
  • πŸ”„ Market Categories - Crypto, Sports, Finance, Politics, and more
  • πŸ“… Time-based Markets - Markets with clear resolution dates and criteria

πŸš€ Getting Started

Prerequisites

Before running this project, make sure you have the following installed:

  • Node.js (v18 or higher)
  • npm or yarn package manager
  • Git for version control

Installation

  1. Clone the repository ```bash git clone https://github.com/your-username/CoreOracle.git cd CoreOracle ```

  2. Install dependencies ```bash npm install

    or

    yarn install ```

  3. Run the development server ```bash npm run dev

    or

    yarn dev ```

  4. Open your browser Navigate to http://localhost:3000 to see the application.

πŸ—οΈ Project Structure

``` CoreOracle/ β”œβ”€β”€ app/ # Next.js App Router β”‚ β”œβ”€β”€ dashboard/ # User dashboard pages β”‚ β”œβ”€β”€ leaderboard/ # Leaderboard pages β”‚ β”œβ”€β”€ markets/ # Market listing and detail pages β”‚ β”œβ”€β”€ globals.css # Global styles β”‚ β”œβ”€β”€ layout.tsx # Root layout β”‚ └── page.tsx # Home page β”œβ”€β”€ components/ # Reusable components β”‚ └── ui/ # shadcn/ui components β”‚ β”œβ”€β”€ avatar.tsx β”‚ β”œβ”€β”€ badge.tsx β”‚ β”œβ”€β”€ button.tsx β”‚ β”œβ”€β”€ card.tsx β”‚ β”œβ”€β”€ input.tsx β”‚ β”œβ”€β”€ label.tsx β”‚ β”œβ”€β”€ progress.tsx β”‚ β”œβ”€β”€ select.tsx β”‚ β”œβ”€β”€ separator.tsx β”‚ └── tabs.tsx β”œβ”€β”€ lib/ # Utility functions β”‚ └── utils.ts # Class name utilities β”œβ”€β”€ public/ # Static assets β”œβ”€β”€ README.md # Project documentation β”œβ”€β”€ next.config.mjs # Next.js configuration β”œβ”€β”€ package.json # Dependencies and scripts β”œβ”€β”€ tailwind.config.ts # Tailwind CSS configuration └── tsconfig.json # TypeScript configuration ```

🎨 Design System

Color Palette

  • Primary: Purple gradient (#8B5CF6 to #EC4899)
  • Background: Dark slate (#0F172A, #1E293B)
  • Success: Green (#10B981)
  • Error: Red (#EF4444)
  • Warning: Yellow (#F59E0B)

Typography

  • Font Family: Inter (system font fallback)
  • Headings: Bold weights (600-700)
  • Body: Regular weight (400)
  • Code: Monospace font family

Components

  • Cards: Rounded corners with subtle shadows
  • Buttons: Multiple variants (primary, secondary, outline)
  • Badges: Rounded pills for categories and status
  • Forms: Clean inputs with focus states

πŸ“± Pages Overview

🏠 Home Page (/)

  • Hero section with platform introduction
  • Featured markets showcase
  • Platform statistics
  • Call-to-action buttons

πŸ“Š Markets Page (/markets)

  • Browse all available prediction markets
  • Search and filter functionality
  • Market categories and sorting options
  • Quick betting interface

🎯 Market Detail Page (/markets/[id])

  • Detailed market information
  • Interactive betting interface
  • Recent activity feed
  • Market rules and resolution criteria

πŸ“ˆ Dashboard Page (/dashboard)

  • Personal statistics and performance
  • Active bets tracking
  • Recent activity history
  • Achievement system

πŸ† Leaderboard Page (/leaderboard)

  • Top predictors by accuracy
  • Top earners by volume
  • Monthly rewards information
  • User rankings and badges

πŸ”§ Technology Stack

Frontend

  • Next.js 14 - React framework with App Router
  • TypeScript - Type-safe JavaScript
  • Tailwind CSS - Utility-first CSS framework
  • shadcn/ui - Modern UI component library
  • Radix UI - Accessible component primitives
  • Lucide React - Beautiful icon library

Styling

  • Tailwind CSS - For responsive design and utilities
  • CSS Variables - For theme customization
  • Dark Mode - Built-in dark theme support

🌐 Blockchain Integration

Core Blockchain Features

  • Smart Contracts - Secure bet placement and resolution
  • CORE Token - Native token for betting and rewards
  • Wallet Integration - MetaMask and Core wallet support
  • Transaction History - On-chain transaction tracking

Smart Contract Functions

  • `placeBet(marketId, outcome, amount)` - Place a prediction bet
  • `resolveMarket(marketId, outcome)` - Resolve market outcome
  • `claimRewards(marketId)` - Claim winnings from resolved markets
  • `createMarket(details)` - Create new prediction markets

🎯 User Roles

πŸ‘€ Regular Users

  • Browse and search prediction markets
  • Place bets on market outcomes
  • Track personal performance
  • Earn rewards for accurate predictions
  • Participate in leaderboards

πŸ—οΈ Market Creators

  • Create new prediction markets
  • Set market parameters and resolution criteria
  • Earn fees from market activity
  • Manage market lifecycle

βš–οΈ Resolvers

  • Resolve market outcomes based on real-world data
  • Verify resolution criteria
  • Handle dispute resolution
  • Maintain platform integrity

πŸ“Š Market Categories

πŸ’° Cryptocurrency

  • Bitcoin and altcoin price predictions
  • DeFi protocol performance
  • NFT market trends
  • Blockchain adoption metrics

⚽ Sports

  • Football, basketball, soccer matches
  • Tournament winners and outcomes
  • Player performance metrics
  • Season-long predictions

πŸ’Ό Finance

  • market movements
  • Economic indicators
  • Interest rate changes
  • Company earnings

πŸ—³οΈ Politics

  • Election outcomes
  • Policy decisions
  • Approval ratings
  • Legislative votes

Build Commands

```bash

Build for production

npm run build

Start production server

npm start

🀝 Contributing

We welcome contributions to CoreOracle! Please follow these steps:

  1. Fork the repository
  2. Create a feature branch (`git checkout -b feature/amazing-feature`)
  3. Commit your changes (`git commit -m 'Add amazing feature'`)
  4. Push to the branch (`git push origin feature/amazing-feature`)
  5. Open a Pull Request

πŸ†˜ Support

Documentation

About

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors