Khatabook is a modern, responsive web application built with React + TypeScript that helps small shopkeepers manage credit sales, track customers, record repayments, and monitor outstanding balances — all from a single dashboard.
It features secure authentication (via DummyJSON Auth), customer detail cards, transaction history, PDF export, toast notifications, and a dark/light theme toggle for a smooth and professional user experience. Added Telugu ↔ English language switch support in i18n, including bidirectional translation and UI toggle improvements.
- Login using DummyJSON Auth API
- Endpoint:
POST https://dummyjson.com/auth/login - Request Example:
{ "username": "emilys", "password": "emilyspass" } - Response: Returns
accessToken,refreshToken, and user details
- Endpoint:
- Sign-Up (Mocked): Client-side form to simulate account creation (no backend)
- View all customers with:
- Name, balance, next due date, and status
- Overdue entries are highlighted
- Click any row to open a Customer Detail Card
- Navigate between customers (Previous / Next)
- Displays:
- Contact info, address, join date
- Total credit, outstanding balance, next due date
- Transactions list (loans + repayments)
- Export to PDF (styled report using
jsPDF+jspdf-autotable)
- Add Customer
- Add Loan
- Record Repayment
- Tailwind CSS v3 for clean, mobile-responsive design
- Dark/Light theme toggle (saved in
localStorage) - Sidebar + Header navigation with Material-UI Icons
- Toast notifications with Sonner
- Loading spinner on login (
react-spinners)
- Framework: React 18 + Vite
- Language: TypeScript
- Styling: Tailwind CSS v3 (
dark:mode support) - Routing: React Router v7
- HTTP Client: Axios
- Toasts: Sonner
- PDF Export: jsPDF + jspdf-autotable
- Icons: Material UI Icons
- Auth Mock: DummyJSON
- Node.js ≥ 18.x
- Clone the repository
git clone https://github.com/karthikfron/Khatabook.git cd Khatabook
2.Install Dependencies
npm install
3.**Start development server**
```bash
npm run dev