Skip to content

TakaSmart is a revolutionary smart recycling platform that gamifies waste management and promotes environmental sustainability! ๐ŸŒŸ Built with cutting-edge technology, our platform makes recycling fun, rewarding, and socially engaging.

Notifications You must be signed in to change notification settings

mwakidenis/TakaSmart-Reward-System

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

๐ŸŒฑ TakaSmart - Smart Recycling Platform ๐ŸŒ

React TypeScript Tailwind CSS Supabase

๐Ÿš€ Welcome to TakaSmart!

TakaSmart is a revolutionary smart recycling platform that gamifies waste management and promotes environmental sustainability! ๐ŸŒŸ Built with cutting-edge technology, our platform makes recycling fun, rewarding, and socially engaging.

๐Ÿ“ฑ Live Demo

URL:

โœจ Key Features

๐ŸŽฏ Core Functionality

  • ๐Ÿ—บ๏ธ Smart Bin Locator: Find recycling bins near you with real-time location data
  • ๐Ÿ“ฑ QR Code Scanning: Scan bins to record recycling activities
  • ๐Ÿ† Gamification System: Earn points for every recycling action
  • ๐ŸŽ Rewards Program: Redeem points for exciting rewards and discounts
  • ๐Ÿ‘ฅ Community Feed: Share your eco-achievements with the community
  • ๐Ÿค– AI Assistant: Get personalized recycling tips and guidance

๐Ÿ› ๏ธ Advanced Features

  • ๐Ÿ“Š Environmental Impact Calculator: Track your real environmental impact with COโ‚‚ savings, water conservation, energy savings, and tree equivalents
  • ๐Ÿ… Achievement Badges: Unlock special badges for milestones
  • ๐Ÿ“ˆ Leaderboards: Compete with friends and community
  • ๐Ÿ’ฌ Social Features: Like, comment, and share recycling activities
  • ๐Ÿ“ฑ Mobile-First Design: Optimized for all devices
  • ๐Ÿ” Secure Authentication: User accounts with profile management

๐Ÿง  Smart Features

  • ๐Ÿšš Waste Pickup Reminders: Smart notifications for optimal recycling times based on bin capacity and collection schedules
  • ๐Ÿ—บ๏ธ Route Optimization: AI-powered suggestions for efficient routes to multiple recycling points
  • ๐ŸŒค๏ธ Weather Integration: Contextual recycling tips that adapt to weather conditions
  • ๐Ÿ’ก Daily Eco Tips: Rotating educational content with actionable sustainability advice
  • ๐Ÿ“ฐ Sustainability News: Curated environmental news and updates
  • ๐Ÿ“Š Predictive Analytics: Machine learning algorithms for optimal waste management

๐Ÿ—๏ธ Tech Stack

Frontend ๐ŸŽจ

  • โš›๏ธ React 18.3.1 - Modern UI library
  • ๐Ÿ”ท TypeScript - Type-safe JavaScript
  • ๐ŸŽจ Tailwind CSS - Utility-first CSS framework
  • ๐Ÿงฉ Shadcn/UI - Beautiful, accessible components
  • ๐Ÿ”€ React Router - Client-side routing
  • ๐Ÿ”„ TanStack Query - Powerful data fetching

Backend & Database ๐Ÿ—ƒ๏ธ

  • ๐ŸŸข Supabase - Backend-as-a-Service
  • ๐Ÿ˜ PostgreSQL - Robust relational database
  • ๐Ÿ” Row Level Security - Secure data access
  • ๐Ÿ”‘ Authentication - User management
  • ๐Ÿ“ก Real-time Updates - Live data synchronization

Development Tools ๐Ÿ› ๏ธ

  • โšก Vite - Lightning-fast build tool
  • ๐Ÿ“ฆ npm - Package management
  • ๐ŸŽฏ ESLint - Code linting
  • ๐Ÿ”ง PostCSS - CSS processing

๐Ÿ—‚๏ธ Project Structure

src/
โ”œโ”€โ”€ ๐Ÿ“ components/          # Reusable UI components
โ”‚   โ”œโ”€โ”€ ๐Ÿงฉ ui/             # Shadcn/UI components
โ”‚   โ”œโ”€โ”€ ๐Ÿ—บ๏ธ Navigation.tsx   # Bottom navigation
โ”‚   โ”œโ”€โ”€ ๐Ÿ‘ฅ SocialFeed.tsx   # Community feed
โ”‚   โ”œโ”€โ”€ ๐Ÿ† Leaderboard.tsx  # Competition rankings
โ”‚   โ”œโ”€โ”€ ๐Ÿ’ก EcoTips.tsx      # Daily sustainability tips
โ”‚   โ”œโ”€โ”€ ๐Ÿ“Š ImpactCalculator.tsx # Environmental impact tracking
โ”‚   โ”œโ”€โ”€ ๐Ÿšš WastePickupReminders.tsx # Smart pickup notifications
โ”‚   โ”œโ”€โ”€ ๐Ÿ—บ๏ธ RouteOptimization.tsx # Efficient route planning
โ”‚   โ”œโ”€โ”€ ๐ŸŒค๏ธ WeatherIntegration.tsx # Weather-based recycling tips
โ”‚   โ”œโ”€โ”€ ๐Ÿ“ฐ SustainabilityNews.tsx # Environmental news feed
โ”‚   โ””โ”€โ”€ ๐Ÿ›ก๏ธ ProtectedRoute.tsx # Auth protection
โ”œโ”€โ”€ ๐Ÿ“ pages/              # Application pages
โ”‚   โ”œโ”€โ”€ ๐Ÿ  Index.tsx        # Dashboard/Home with tabbed interface
โ”‚   โ”œโ”€โ”€ ๐Ÿ—บ๏ธ BinLocator.tsx   # Find recycling bins
โ”‚   โ”œโ”€โ”€ ๐Ÿ“ฑ ScanBin.tsx      # QR code scanning
โ”‚   โ”œโ”€โ”€ ๐Ÿ‘ฅ Community.tsx    # Social features
โ”‚   โ”œโ”€โ”€ ๐ŸŽ Rewards.tsx      # Rewards marketplace
โ”‚   โ”œโ”€โ”€ ๐Ÿ‘ค Profile.tsx      # User profile
โ”‚   โ”œโ”€โ”€ ๐Ÿค– AIAssistant.tsx  # AI helper
โ”‚   โ”œโ”€โ”€ ๐Ÿ” Auth.tsx         # Authentication
โ”‚   โ””โ”€โ”€ ๐ŸŒŸ LandingPage.tsx  # Welcome page
โ”œโ”€โ”€ ๐Ÿ“ contexts/           # React contexts
โ”‚   โ””โ”€โ”€ ๐Ÿ” AuthContext.tsx  # Authentication state
โ”œโ”€โ”€ ๐Ÿ“ integrations/       # External services
โ”‚   โ””โ”€โ”€ ๐ŸŸข supabase/       # Supabase client & types
โ””โ”€โ”€ ๐Ÿ“ hooks/              # Custom React hooks

๐Ÿš€ Getting Started

Prerequisites ๐Ÿ“‹

  • Node.js (v18 or higher) ๐Ÿ“ฆ
  • npm or yarn ๐Ÿงถ
  • Supabase account ๐ŸŸข

Installation Steps ๐Ÿ’ป

  1. ๐Ÿ“ฅ Clone the repository

    git clone <YOUR_GIT_URL>
    cd <YOUR_PROJECT_NAME>
  2. ๐Ÿ“ฆ Install dependencies

    npm install
  3. ๐Ÿ”ง Set up environment variables

    # Create .env.local file with your Supabase credentials
    VITE_SUPABASE_URL=your_supabase_url
    VITE_SUPABASE_ANON_KEY=your_supabase_anon_key
  4. ๐Ÿš€ Start development server

    npm run dev
  5. ๐ŸŒ Open your browser Navigate to http://localhost:5173

๐Ÿ—„๏ธ Database Schema

๐Ÿ“Š Tables Overview

Table Description Key Features
๐Ÿ‘ค profiles User profiles Personal info, points, achievements
๐Ÿ—‘๏ธ bins Recycling bins Location, capacity, waste types
โ™ป๏ธ recycling_sessions User activities Points, waste type, verification
๐ŸŽ rewards Available rewards Points required, validity
๐Ÿ† user_rewards Redeemed rewards Redemption codes, status
๐Ÿ‘ฅ user_roles User permissions Admin/user roles

๐Ÿ” Security Features

  • Row Level Security (RLS) on all tables
  • User-specific data access
  • Admin role management
  • Secure authentication flows

๐ŸŽฎ How to Use TakaSmart

๐ŸŒŸ For New Users

  1. ๐Ÿ“ Sign Up: Create your account on the landing page
  2. ๐Ÿ  Explore Dashboard: Check your stats and recent activities across four tabs:
    • Overview: Personal stats, recent activity, and impact calculator
    • Eco Tips: Daily sustainability tips and weather integration
    • Smart: Waste pickup reminders and route optimization
    • News: Latest sustainability news and updates
  3. ๐Ÿ—บ๏ธ Find Bins: Use the bin locator to find nearby recycling points
  4. ๐Ÿ“ฑ Start Recycling: Scan QR codes to record your activities
  5. ๐Ÿ† Earn Points: Accumulate points for each recycling session

๐ŸŽฏ Advanced Usage

  1. ๐Ÿ‘ฅ Join Community: Share your achievements and engage with others
  2. ๐ŸŽ Redeem Rewards: Use points for discounts and prizes
  3. ๐Ÿค– Get AI Help: Ask our assistant for recycling tips
  4. ๐Ÿ“Š Track Impact: Monitor your environmental contribution with detailed metrics
  5. ๐Ÿ… Unlock Badges: Complete challenges and earn achievements
  6. ๐Ÿ“ฑ Smart Notifications: Get reminders for optimal recycling times

๐ŸŒ Environmental Impact Features

๐Ÿ“Š Real-Time Impact Tracking

  • ๐ŸŒฑ COโ‚‚ Prevention: Track carbon emissions prevented through recycling
  • ๐Ÿ’ง Water Conservation: Monitor water resources saved
  • โšก Energy Savings: Calculate energy consumption reduced
  • ๐ŸŒณ Tree Equivalency: See impact in terms of trees planted

๐Ÿ“ˆ Personalized Insights

  • ๐Ÿ“Š Waste Breakdown: Detailed analysis by material type
  • ๐ŸŽฏ Impact Goals: Set and track environmental targets
  • ๐Ÿ“… Progress Timeline: Historical impact data visualization
  • ๐Ÿ† Milestone Celebrations: Recognition for significant achievements

๐Ÿ”ง Development

๐Ÿ› ๏ธ Available Scripts

# ๐Ÿš€ Start development server
npm run dev

# ๐Ÿ—๏ธ Build for production
npm run build

# ๐Ÿ‘€ Preview production build
npm run preview

# ๐Ÿ” Run linter
npm run lint

๐ŸŽจ Styling Guidelines

  • Use Tailwind CSS for all styling
  • Follow mobile-first responsive design
  • Maintain consistent spacing and colors
  • Use Shadcn/UI components when possible

๐Ÿ“ Code Standards

  • Write TypeScript for type safety
  • Use React hooks for state management
  • Follow component composition patterns
  • Implement proper error handling

๐Ÿš€ Deployment

๐Ÿค Contributing

We welcome contributions! ๐ŸŽ‰

๐Ÿ“‹ Contribution Guidelines

  1. ๐Ÿด Fork the repository
  2. ๐ŸŒฟ Create a feature branch
  3. โœจ Make your changes
  4. ๐Ÿงช Test thoroughly
  5. ๐Ÿ“ Submit a pull request

๐Ÿ› Bug Reports

  • Use GitHub Issues
  • Provide detailed reproduction steps
  • Include screenshots if applicable

๐Ÿ’ก Feature Requests

  • Describe the feature clearly
  • Explain the use case
  • Consider implementation complexity

๐Ÿ“ˆ Roadmap

๐Ÿ”ฎ Upcoming Features

  • ๐Ÿ“ฑ Mobile App (React Native)
  • ๐ŸŒ Multi-language Support
  • ๐Ÿ“Š Advanced Analytics Dashboard
  • ๐Ÿข Corporate Partnerships
  • ๐ŸŽฏ Personalized Recommendations
  • ๐ŸŒฑ Carbon Footprint Tracking
  • ๐Ÿ“ฑ Offline Mode Support
  • ๐Ÿ”” Push Notifications

๐ŸŽฏ Long-term Goals

  • ๐ŸŒ Global Expansion
  • ๐Ÿค Government Partnerships
  • ๐Ÿ“š Educational Programs
  • ๐Ÿญ Industry Integration

๐Ÿ”ง Troubleshooting

  • Check console for errors
  • Verify Supabase connection
  • Review authentication setup
  • Test database permissions

๐Ÿ“„ License

๐Ÿ™ Acknowledgments

  • ๐ŸŽจ Shadcn - For beautiful UI components
  • ๐ŸŸข Supabase - For powerful backend services
  • ๐ŸŒ Environmental Community - For inspiration and support

๐Ÿ“Š Project Stats

  • ๐Ÿ“ฑ Responsive Design: โœ… Mobile-first
  • ๐Ÿ”’ Security: โœ… RLS + Authentication
  • โšก Performance: โœ… Optimized builds
  • ๐ŸŽจ Accessibility: โœ… WCAG compliant
  • ๐Ÿ”ง Maintainability: โœ… TypeScript + Clean code

๐ŸŒŸ Made with โค๏ธ for a Greener Planet ๐ŸŒ

TakaSmart - Making recycling rewarding, one scan at a time!

๐Ÿš€ Ready to make a difference?

Start your recycling journey today!

---Developed with โค๏ธโค๏ธ by Mwaki Denis Buy Me a Coffee---

About

TakaSmart is a revolutionary smart recycling platform that gamifies waste management and promotes environmental sustainability! ๐ŸŒŸ Built with cutting-edge technology, our platform makes recycling fun, rewarding, and socially engaging.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •