A production-ready, accessible and lightning-fast case management system.
One-liner: Import → Validate → Fix → Submit → Track
CaseFlow/
├── frontend/ # React + Vite + TypeScript
│ ├── src/
│ │ ├── components/ # Reusable UI components
│ │ ├── features/ # Redux slices (auth, cases, upload)
│ │ ├── layouts/ # Page layouts (Auth, Dashboard)
│ │ ├── pages/ # Route pages
│ │ ├── services/ # API client
│ │ ├── types/ # TypeScript definitions
│ │ └── lib/ # Utility functions
│ └── ...
├── backend/ # Express + TypeScript
│ ├── src/
│ │ ├── routes/ # API routes (auth, cases)
│ │ └── server.ts # Express server setup
│ └── ...
└── sample-cases.csv # Sample data for testing
- Framework: React with TypeScript
- Build Tool: Vite (lightning fast)
- State Management: Redux Toolkit + Zustand
- Styling: Tailwind CSS with custom design system
- Animations: Framer Motion
- UI Components: Radix UI (headless, accessible)
- Data Grid: TanStack Table with virtualization
- Form Handling: React Hook Form + Zod validation
- CSV Parsing: PapaParse
- File Upload: React Dropzone
- Notifications: Sonner (beautiful toasts)
- Lucide React
- Runtime: Node.js with TypeScript
- Framework: Express
- Authentication: JWT + bcryptjs
- Database: In-memory (for testing) - easily replaceable with PostgreSQL/MongoDB
- Validation: Zod schemas
- Security: CORS, helmet-ready
- Testing: Vitest + Supertest
- Clone the repository
git clone https://github.com/Rajput-xv/CaseFlow.git
cd CaseFlow- Setup Frontend
cd frontend
npm install- Setup Backend
cd ../backend
npm install- Run the application
Open two terminal windows:
Terminal 1 - Backend:
cd backend
npm run devServer runs on: http://localhost:5000
Terminal 2 - Frontend:
cd frontend
npm run devApp runs on: http://localhost:3000
- Login with test credentials
Email: test@example.com
Password: password123
- Sign up with email/password or login with existing credentials
- Navigate to Upload page
- Drag & drop your CSV file or click to browse
- See real-time validation with inline error indicators
- Review parsed data in virtualized data grid
- See validation errors highlighted in red
- View summary stats (total, valid, errors)
- Click "Import" to batch create cases
- See animated progress and final report
- Download error CSV if needed
- Browse cases
- Filter by status, category, priority
- Search by case ID or applicant name
- View detailed case information
- Modular Structure: Features are organized by domain (auth, cases, upload)
- Component Library: Built reusable UI components with consistent styling
- State Management: Redux for global state, local state for UI-specific needs
- Animation Strategy: Framer Motion for smooth, performant animations
- Responsive Design: Mobile-first approach with Tailwind breakpoints
- Virtualization: TanStack Virtual for handling large datasets (50k+ rows)
- Inline Validation: Real-time error display with Zod schemas
- Performance: Memoization and lazy loading for optimal rendering
- Client-side Parsing: PapaParse for fast, browser-based parsing
- Streaming: Handles large files without blocking UI
- Validation: Immediate feedback with actionable error messages
- JWT Strategy: Stateless authentication for scalability
- Token Storage: localStorage (can be upgraded to httpOnly cookies)
- Role-based Access:** Admin vs Operator roles
cd frontend
npm test # Run unit tests
npm run test:ui # Visual test UI
npm run e2e # End-to-end testscd backend
npm test # Run unit tests- Component tests with React Testing Library
- Unit tests for validation logic
- E2E tests with Playwright (ready to add)
- API endpoint tests (ready to add)
frontend/src/
├── components/
│ ├── ui/ # Reusable UI components (Button, Card, etc.)
│ └── upload/ # Upload-specific components
├── features/
│ ├── auth/ # Authentication slice & logic
│ ├── cases/ # Cases management slice
│ └── upload/ # Upload slice & logic
├── layouts/
│ ├── AuthLayout.tsx # Auth pages wrapper
│ └── DashboardLayout.tsx # Dashboard wrapper with sidebar
├── pages/
│ ├── auth/ # Login & Register pages
│ ├── dashboard/ # Dashboard home
│ ├── upload/ # CSV upload & preview
│ └── cases/ # Cases list & detail
├── services/
│ └── api/ # Axios client & API calls
├── types/ # TypeScript interfaces
└── lib/ # Utility functions
backend/src/
├── routes/
│ ├── auth.ts # Authentication endpoints
│ └── cases.ts # Cases CRUD endpoints
└── server.ts # Express server setup
VITE_API_URL=http://localhost:5000/apiPORT=5000
NODE_ENV=development
JWT_SECRET=your-super-secret-jwt-key-change-in-production
JWT_EXPIRES_IN=7dcase_id,applicant_name,dob,email,phone,category,priority
C-1001,Asha Verma,1990-03-14,asha.verma@example.com,+919876543210,TAX,HIGH
C-1002,John DOE,1985-12-02,john.doe@example.com,+11234567890,LICENSE,MEDIUMRequired Fields:
case_id- Unique identifierapplicant_name- Full namedob- ISO date (YYYY-MM-DD)category- TAX | LICENSE | PERMITpriority- LOW | MEDIUM | HIGH (defaults to LOW)
Optional Fields:
email- Valid email addressphone- E.164 format (e.g., +1234567890)
- Fork the repository
- Create feature branch (
git checkout -b feature/AmazingFeature) - Commit changes (
git commit -m 'Add AmazingFeature') - Push to branch (
git push origin feature/AmazingFeature) - Open Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
Rajput-xv - @Rajput-xv
Project Link: https://github.com/Rajput-xv/CaseFlow