diff --git a/README.md b/README.md index 0b58c52..9826c05 100755 --- a/README.md +++ b/README.md @@ -1,18 +1,16 @@ -# ⏰ ActaTempus - Time Tracking and Management System +# ⏰ ActaTempus: Time Tracking and Management System ## 🌟 Overview -**ActaTempus** is a modern, comprehensive web application designed to efficiently manage and track work hours. It features: -- A **backend** developed in both Go and Dart, following **functional programming principles**. -- An interactive **React frontend** for an intuitive user experience. +**ActaTempus** is a sophisticated web application designed for efficient work hour management and tracking. Featuring a dual backend developed in **Go** and **Dart** alongside a modern **Next.js frontend**, ActaTempus emphasizes functional programming principles and streamlined user experience. --- ## 🚀 Features (Long-Term Goals) -✅ **User Management**: Registration, login, and profile updates +✅ **User Management**: Registration, login, profile updates ✅ **Time Tracking**: Start/stop tracking, manual entries, and break management -✅ **Project Management**: Create and manage projects +✅ **Project Management**: Create and manage projects, tasks, and time entries ✅ **Reporting**: Generate daily/weekly reports and export as PDF/CSV ✅ **Role-Based Access Control (RBAC)**: Fine-grained permission system @@ -20,20 +18,20 @@ ## 🏗️ Architecture -This system follows **Domain-Driven Design (DDD)** and **Clean Architecture** principles to ensure a modular, maintainable, and scalable codebase. -It is structured into **four primary layers**: +ActaTempus adheres to **Domain-Driven Design (DDD)** and **Clean Architecture** principles for a scalable and maintainable codebase. +The system is divided into **four primary layers**: 1️⃣ **Domain Layer**: - - Contains contracts and interface definitions. + - Contracts, definitions, and interfaces only. 2️⃣ **Infrastructure Layer**: - - Implements external sources like databases and configurations. + - Database and external service integrations (e.g., Prisma with PostgreSQL). 3️⃣ **Application Layer**: - - Implements business logic and server responses. + - Business logic, services, and response handling. 4️⃣ **Interface Layer**: - - Defines the external-facing API. + - External communication interfaces. ![Architecture Diagram](docs/media/architecture.png) @@ -42,25 +40,25 @@ It is structured into **four primary layers**: ## 🛠️ Technology Stack ### 🎨 Frontend: -- **React**: User Interface -- **Axios/Fetch API**: HTTP requests -- **WebSockets**: Real-time updates -- **Styled Components**: CSS-in-JS +- **Next.js**: React framework for SSR and SPA capabilities +- **Deno**: Lightweight, secure runtime for development tooling +- **Dependencies**: + - `fp-ts`: Functional programming in TypeScript + - `@reactivex/rxjs`: Reactive programming + - `clsx`: Conditional class handling + - `lucide-react`: Icon library + - `next-intl`: Internationalization ### ⚙️ Backend: #### Go: -- **GORM**: ORM for PostgreSQL -- **go-redis**: Redis integration -- **gorilla/websocket** & **mux**: WebSocket & HTTP routing +- **Prisma-Go**: PostgreSQL ORM integration with Prisma #### Dart: -- **drift/aqueduct**: ORM for database access -- **redis_client**: Redis integration -- **shelf_web_socket**: WebSocket handling +- **Prisma-Dart**: PostgreSQL ORM adapter for Dart -### 📦 Databases: -- **PostgreSQL**: Main data storage -- **Redis**: Caching and real-time updates +### 📦 Database: +- **PostgreSQL**: Primary database +- **Prisma**: Shared ORM schema across Dart and Go backends --- @@ -69,8 +67,8 @@ It is structured into **four primary layers**: ``` backend-go/ # Go backend implementation backend-dart/ # Dart backend implementation -frontend-react/ # React frontend -docs/ # Documentation and design diagrams +frontend-next/ # Next.js frontend +docs/ # Documentation, specs, and design diagrams ``` --- @@ -79,12 +77,12 @@ docs/ # Documentation and design diagrams ### Prerequisites -💡 All dependencies are pre-configured in the **devcontainer**. If you're setting up manually, ensure you have: +All dependencies are bundled with the **devcontainer**. For manual setup, ensure you have: - [Docker](https://www.docker.com/) -- Node.js (Frontend) -- Go (Go backend) -- Dart (Dart backend) -- PostgreSQL and Redis +- Node.js +- Go +- Dart +- PostgreSQL ### 🔧 Installation @@ -95,20 +93,23 @@ docs/ # Documentation and design diagrams ``` 2. **Use the devcontainer**: - Ensure the repository is on a **Unix-native file system** (e.g., WSL on Windows). Launch with Visual Studio Code: + Place the repository on a **Unix-native file system**. + Otherwise you will experience severe performance issues. + Launch it with Visual Studio Code: ```bash code . ``` --- -## 🖥️ Running the Software +## 🖥️ Running ActaTempus ### Frontend ```bash -cd frontend-react -deno run dev # Starts UI on port 3000 +cd frontend-next +# Install dependencies (if not using devcontainer) +deno task dev # Starts the UI on port 3000 ``` ### Backend (Go) @@ -129,7 +130,7 @@ dart run bin/backend_dart.dart # Starts on port 8080 ## 🗄️ Database Management -We use **Prisma ORM** for consistent database schema management across both backends. +ActaTempus uses **Prisma ORM** for database schema management and code generation across both backends. ### Deploy the Schema @@ -153,11 +154,11 @@ bunx prisma generate ## 🔧 Known Issues -### 🐛 Browser Extensions Cause Hydration Issues +### 🐛 Browser Extensions and Hydration -Certain extensions (e.g., Grammarly) inject DOM attributes that cause SSR mismatches: +Some browser extensions (e.g., Grammarly) inject DOM attributes that cause SSR mismatches: - Example: `` -- Disable such extensions if issues occur. +- Disable such extensions if issues occur. ![Hydration Issue](docs/media/image.png) @@ -167,18 +168,18 @@ Certain extensions (e.g., Grammarly) inject DOM attributes that cause SSR mismat ### Phase 1: **Initialize** - ✅ Define specifications -- ✅ Initialize repository +- ✅ Set up repository ### Phase 2: **Setup** -- ✅ Frontend (NextJS, Deno) +- ✅ Frontend (Next.js, Deno) - ✅ Backends (Dart & Go) -- ✅ Dev-container +- ✅ Devcontainer ### Phase 3: **MVP Development** -- Build foundational backends in Go & Dart. +- Build foundational backends in Go & Dart - Implement: - ✅ Domain layer (Entities, Repositories) - - ✅ Business logic (Services, DTOs, JWT Authentication) + - ✅ Application logic (Services, DTOs, JWT Authentication) - ✅ Basic authorization ### Phase 4: **Web UI** @@ -187,11 +188,6 @@ Certain extensions (e.g., Grammarly) inject DOM attributes that cause SSR mismat - Project management - Reporting -### Future Iterations -- 📊 Report exports (Excel, PDF) -- 💳 Billing integration -- 🏢 Multi-tenant support - --- ## 🌐 Resources