A JavaScript-based admin dashboard for the Codesapiens platform. Manage users, projects, roles, and resources with a modern, responsive UI powered by React 19, Tailwind CSS v4, Supabase, and Cloudinary.
- Introduction
- Key Features
- Tech Stack
- Project Structure
- Prerequisites
- Installation & Local Setup
- Environment Variables
- Usage & Commands
- Authentication & Security
- Testing
- Deployment
- Contributing
- Troubleshooting
- License
- Contact
Welcome to the Codesapiens Management Website — the central admin interface for the Codesapiens ecosystem.
This frontend application provides a secure, intuitive, and real-time admin panel to manage:
- Users & roles
- Projects & tasks
- Media assets
- System analytics
Built with modern tooling and best practices, it integrates seamlessly with Supabase (auth, DB, realtime) and Cloudinary (media), and supports deployment on Vercel, Netlify, or GitHub Pages.
- Admin Dashboard - Real-time analytics, widgets, notifications
- User Management - CRUD operations, role assignment, bulk actions, avatar upload
- Project Management - Full lifecycle management, milestones, file attachments
- RBAC (Role-Based Access) - Granular permissions (Admin, Moderator, Editor)
- Real-Time Updates - Live sync via Supabase Realtime
- Media Handling - Upload & optimize via Cloudinary
- Secure Auth - Supabase Auth + Turnstile CAPTCHA
- Responsive UI - Mobile-first, accessible
- Audit Logs - Track all admin actions
- Export/Import - JSON Export
Language: JavaScript (ES6+)
Framework: React 19.1.1
Styling: Tailwind CSS v4
Build Tool: Vite
Backend: Supabase (Auth, DB, Realtime, Storage)
Media: Cloudinary
CAPTCHA: Cloudflare Turnstile
State Management: React Context / Zustand
Icons: Lucide React
Full dependency list available in
package.json
Codesapiens_management_website/
├── .deepsource.toml (115 bytes)
├── .flowbite-react/
│ ├── class-list.json (2 bytes)
│ ├── config.json (189 bytes)
│ └── init.tsx (490 bytes)
├── .github/
│ └── workflows/
│ └── node.js.yml (844 bytes)
├── .gitignore (259 bytes)
├── ENVEXAMPLE (50 bytes)
├── README.md (3808 bytes)
├── eslint.config.js (763 bytes)
├── index.html (360 bytes)
├── package-lock.json (210603 bytes)
├── package.json (1372 bytes)
├── public/
│ ├── logo.jpg (25536 bytes)
│ └── vite.svg (1497 bytes)
├── src/
│ ├── App.jsx (4658 bytes)
│ ├── admin/
│ │ ├── AdminMeetup.jsx (9505 bytes)
│ │ ├── AdminMeetupEdit.jsx (6720 bytes)
│ │ ├── AdminMeetupList.jsx (10654 bytes)
│ │ ├── AdminMentorshipSubmission.jsx (22416 bytes)
│ │ ├── AdminScannerMeetup.jsx (7117 bytes)
│ │ ├── AllUserList.jsx (37582 bytes)
│ │ ├── AnalyticsPage.jsx (34761 bytes)
│ │ └── Dashboard.jsx (19458 bytes)
│ ├── assets/
│ │ ├── academic.json (2608 bytes)
│ │ ├── react.svg (4126 bytes)
│ │ └── skills.json (4265 bytes)
│ ├── components/
│ │ ├── AuthForm.jsx (22858 bytes)
│ │ ├── CodesapiensHero.jsx (35197 bytes)
│ │ ├── LumaEmbed.jsx (503 bytes)
│ │ ├── Navbar.jsx (23541 bytes)
│ │ ├── PublicProfile.jsx (14214 bytes)
│ │ ├── ResetPassword.jsx (3422 bytes)
│ │ ├── ResetPasswordConfirm.jsx (2013 bytes)
│ │ └── ui/
│ │ └── NotFoundPage.jsx (1511 bytes)
│ ├── index.css (114 bytes)
│ ├── lib/
│ │ ├── authContext.jsx (292 bytes)
│ │ ├── authFetch.js (960 bytes)
│ │ ├── supabaseClient.jsx (202 bytes)
│ │ └── useAuth.js (960 bytes)
│ ├── main.jsx (255 bytes)
│ └── user/
│ ├── UserCodingPlatform.jsx (7828 bytes)
│ ├── UserDashboard.jsx (18401 bytes)
│ ├── UserEvents.jsx (214 bytes)
│ ├── UserMeetup.jsx (10358 bytes)
│ ├── UserMeetupsList.jsx (11133 bytes)
│ ├── UserMentorshipForm.jsx (18732 bytes)
│ ├── UserMentorshipFormList.jsx (10321 bytes)
│ ├── UserPlayGround.jsx (2564 bytes)
│ ├── UserProfile.jsx (60884 bytes)
│ ├── UserResource.jsx (299 bytes)
│ └── UserResumeBuilder.jsx (307 bytes)
├── tailwind.config.js (961 bytes)
├── test-results/
│ └── .last-run.json (45 bytes)
├── vercel.json (70 bytes)
└── vite.config.js (529 bytes)
---
Before you begin, ensure you have the following installed:
- Node.js (LTS recommended: v20.x+)
- npm (v10+)
- Git
You'll also need accounts and API keys for:
Verify your installations:
node --version # Should be >= 20
npm --version # Should be >= 10Note: For a detailed step-by-step setup guide, including database initialization, please see SETUP.md.
git clone https://github.com/jayasurya261/Codesapiens_management_website.git
cd Codesapiens_management_websitenpm installcp .env.example .env.localEdit .env.local with your actual API keys (see Environment Variables section below).
npm run devOpen http://localhost:5173 in your browser.
The app uses Vite HMR — changes will reflect instantly!
Create a .env.local file in the root directory (never commit this file!):
# Supabase Configuration
VITE_SUPABASE_URL=https://your-project.supabase.co
VITE_SUPABASE_ANON_KEY=your-anon-key
# Cloudinary Configuration
CLOUDINARY_CLOUD_NAME=your-cloud-name
CLOUDINARY_API_KEY=123456789
CLOUDINARY_API_SECRET=your-secret
# Cloudflare Turnstile
REACT_APP_TURNSTILE_SITE_KEY=0x4AAAAAA...
# Environment
NODE_ENV=developmentImportant:
- Add
.env.localto your.gitignore - See
EXAMPLEENVfor a complete template - Never commit sensitive keys to version control
| Command | Description |
|---|---|
npm run dev |
Start development server with HMR |
npm run build |
Build production bundle to dist/ |
npm run preview |
Preview production build locally |
- Login Page:
/login→ Uses Supabase Auth (email/password) - Protected Routes: All pages except login require authentication
- Role-Based Access Control (RBAC): User roles checked via
user.metadata.role - Session Management: Automatic token refresh, logout on timeout
- CAPTCHA Protection: Turnstile verification on registration/login
import { useAuth } from './hooks/useAuth';
function AdminPage() {
const { user, loading } = useAuth();
if (loading) return <Spinner />;
if (!user || user.role !== 'admin') {
return <Navigate to="/login" />;
}
return <Dashboard />;
}-
Build the project:
npm run build
-
Connect your repository to Vercel:
- Import your GitHub repository
- Vercel auto-detects Vite configuration
- Deployment happens automatically
-
Set environment variables:
- Go to Vercel Dashboard → Project Settings → Environment Variables
- Add all variables from
.env.local
| Platform | Build Command | Output Directory |
|---|---|---|
| Netlify | npm run build |
dist |
| GitHub Pages | npm run build |
dist (use gh-pages branch) |
| AWS Amplify | npm run build |
dist |
Important: Ensure all environment variables are configured in your deployment platform.
We welcome contributions from the community!
-
Fork the repository
-
Create a feature branch:
git checkout -b feat/your-feature-name
-
Make your changes
-
Commit your changes:
git commit -m "feat: add user export functionality" -
Push to your fork:
git push origin feat/your-feature-name
-
Open a Pull Request to the
mainbranch
- Follow Conventional Commits for commit messages
- Update documentation as needed
- Important: If you modify the database schema, you MUST update
seed.sql. - Be respectful and constructive in discussions
npm install fails:
rm -rf node_modules package-lock.json
npm installPort already in use:
Edit vite.config.js:
export default {
server: { port: 3000 }
}Supabase authentication errors:
- Verify your Supabase URL and anon key in
.env - Check Row Level Security (RLS) policies in Supabase dashboard
Images not uploading:
- Verify Cloudinary API keys are correct
- Check browser console for CORS errors
Tailwind styles not working:
- Restart the dev server:
npm run dev - Clear Vite cache:
rm -rf node_modules/.vite
Build fails:
rm -rf node_modules/.vite dist
npm install
npm run buildThis project is licensed under the MIT License – free to use, modify, and distribute.
See LICENSE for details.
Maintainer: jayasurya261
Issues: GitHub Issues
Discussions: GitHub Discussions
Made with ❤️ for the Codesapiens community