# khaja2988/fsdend architecture

> Architecture diagram of the GitHub repository khaja2988/fsdend, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-17). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/khaja2988/fsdend
- Repository: https://github.com/khaja2988/fsdend

## Overview

This is a React employee-management frontend: visitors can explore the public site and register or sign in; HR users reach a protected dashboard for employee, leave, attendance, performance, and payroll functions; employees have a separate self-service dashboard. The sampled code shows client-side token checking and an employee-delete API request, but most screens use static content or are unsampled. The graph reflects documented routes and visible navigation, not a verified backend or complete employee authentication flow.

Main entry points: [`src/App.jsx`](https://github.com/khaja2988/fsdend/blob/main/src/App.jsx) (Route application), [`src/pages/Dashboard.jsx`](https://github.com/khaja2988/fsdend/blob/main/src/pages/Dashboard.jsx) (HR dashboard shell), [`src/pages/EmployeeDashboard.jsx`](https://github.com/khaja2988/fsdend/blob/main/src/pages/EmployeeDashboard.jsx) (Employee dashboard), [`src/pages/Login.jsx`](https://github.com/khaja2988/fsdend/blob/main/src/pages/Login.jsx) (HR login)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_public["Public site"]
  node_app["Route application<br/>[App.jsx]"]
  node_navbar["Site navigation<br/>[Navbar.jsx]"]
  node_landing["Landing page<br/>[Landing.jsx]"]
  node_about["About page<br/>[About.jsx]"]
  node_features["Features page<br/>[Features.jsx]"]
  node_contact["Contact page<br/>[Contact.jsx]"]
end

subgraph group_access["Account access"]
  node_register["Registration form<br/>[Register.jsx]"]
  node_login["HR login<br/>[Login.jsx]"]
  node_employee_login["Employee login<br/>[EmployeeLogin.jsx]"]
  node_token_store[("Browser token store")]
end

subgraph group_hr["HR dashboard"]
  node_dashboard["HR dashboard shell<br/>[Dashboard.jsx]"]
  node_add_employee["Add employee<br/>[AddEmployee.jsx]"]
  node_employee_details["Employee details"]
  node_employee_management["Employee management"]
  node_delete_employee["Delete employee<br/>[DeleteEmployee.jsx]"]
  node_leave_management["Leave management"]
  node_attendance["Attendance<br/>[Attendance.jsx]"]
  node_performance_reviews["Performance reviews"]
  node_payroll["Payroll management"]
  node_profile["HR profile<br/>[Profile.jsx]"]
  node_settings["HR settings<br/>[Settings.jsx]"]
  node_update_employee["Update employee<br/>[UpdateEmployee.jsx]"]
end

subgraph group_selfservice["Employee self-service"]
  node_employee_dashboard["Employee dashboard"]
  node_employee_leaves["Employee leaves<br/>[Leaves.jsx]"]
  node_employee_performance["Employee performance<br/>[Performance.jsx]"]
end

node_visitor(("Visitor"))
node_employee(("Employee user"))
node_api["Employee API"]

node_visitor -->|"opens"| node_app
node_employee -->|"opens"| node_app
node_app -->|"renders"| node_navbar
node_app -->|"routes"| node_landing
node_app -->|"routes"| node_about
node_app -->|"routes"| node_features
node_app -->|"routes"| node_contact
node_app -->|"routes"| node_register
node_app -->|"routes"| node_login
node_app -->|"routes"| node_employee_login
node_app -->|"routes"| node_employee_dashboard
node_app -->|"protects route"| node_dashboard
node_app -->|"checks token"| node_token_store
node_login -->|"writes token"| node_token_store
node_app -->|"routes"| node_add_employee
node_app -->|"routes"| node_employee_details
node_app -->|"routes"| node_leave_management
node_app -->|"routes"| node_attendance
node_app -->|"routes"| node_performance_reviews
node_app -->|"routes"| node_payroll
node_app -->|"routes"| node_profile
node_dashboard -->|"navigates to"| node_employee_management
node_dashboard -->|"navigates to"| node_update_employee
node_dashboard -->|"navigates to"| node_settings
node_app -->|"routes"| node_delete_employee
node_delete_employee -->|"fetches and deletes"| node_api
node_employee_dashboard -->|"navigates to"| node_employee_leaves
node_employee_dashboard -->|"navigates to"| node_employee_performance

click node_app "https://github.com/khaja2988/fsdend/blob/main/src/App.jsx"
click node_navbar "https://github.com/khaja2988/fsdend/blob/main/src/components/Navbar.jsx"
click node_landing "https://github.com/khaja2988/fsdend/blob/main/src/pages/Landing.jsx"
click node_about "https://github.com/khaja2988/fsdend/blob/main/src/pages/About.jsx"
click node_features "https://github.com/khaja2988/fsdend/blob/main/src/pages/Features.jsx"
click node_contact "https://github.com/khaja2988/fsdend/blob/main/src/pages/Contact.jsx"
click node_register "https://github.com/khaja2988/fsdend/blob/main/src/pages/Register.jsx"
click node_login "https://github.com/khaja2988/fsdend/blob/main/src/pages/Login.jsx"
click node_employee_login "https://github.com/khaja2988/fsdend/blob/main/src/pages/EmployeeLogin.jsx"
click node_dashboard "https://github.com/khaja2988/fsdend/blob/main/src/pages/Dashboard.jsx"
click node_add_employee "https://github.com/khaja2988/fsdend/blob/main/src/pages/AddEmployee.jsx"
click node_employee_details "https://github.com/khaja2988/fsdend/blob/main/src/pages/dashboard/EmployeeDetails.jsx"
click node_employee_management "https://github.com/khaja2988/fsdend/blob/main/src/pages/dashboard/EmployeeManagement.jsx"
click node_delete_employee "https://github.com/khaja2988/fsdend/blob/main/src/pages/dashboard/DeleteEmployee.jsx"
click node_leave_management "https://github.com/khaja2988/fsdend/blob/main/src/pages/dashboard/LeaveManagement.jsx"
click node_attendance "https://github.com/khaja2988/fsdend/blob/main/src/pages/dashboard/Attendance.jsx"
click node_performance_reviews "https://github.com/khaja2988/fsdend/blob/main/src/pages/dashboard/PerformanceReviews.jsx"
click node_payroll "https://github.com/khaja2988/fsdend/blob/main/src/pages/dashboard/PayrollManagement.jsx"
click node_profile "https://github.com/khaja2988/fsdend/blob/main/src/pages/dashboard/Profile.jsx"
click node_settings "https://github.com/khaja2988/fsdend/blob/main/src/pages/dashboard/Settings.jsx"
click node_update_employee "https://github.com/khaja2988/fsdend/blob/main/src/pages/dashboard/UpdateEmployee.jsx"
click node_employee_dashboard "https://github.com/khaja2988/fsdend/blob/main/src/pages/EmployeeDashboard.jsx"
click node_employee_leaves "https://github.com/khaja2988/fsdend/blob/main/src/pages/employee/Leaves.jsx"
click node_employee_performance "https://github.com/khaja2988/fsdend/blob/main/src/pages/employee/Performance.jsx"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_app,node_navbar,node_landing,node_about,node_features,node_contact,node_employee toneBlue
class node_register,node_login,node_employee_login,node_token_store toneAmber
class node_dashboard,node_add_employee,node_employee_details,node_employee_management,node_delete_employee,node_leave_management,node_attendance,node_performance_reviews,node_payroll,node_profile,node_settings,node_update_employee,node_api toneMint
class node_employee_dashboard,node_employee_leaves,node_employee_performance toneRose
class node_visitor toneIndigo
```

## Components

### Public site

- [Route application](https://github.com/khaja2988/fsdend/blob/main/src/App.jsx): `src/App.jsx`
- [Site navigation](https://github.com/khaja2988/fsdend/blob/main/src/components/Navbar.jsx): `src/components/Navbar.jsx`
- [Landing page](https://github.com/khaja2988/fsdend/blob/main/src/pages/Landing.jsx): `src/pages/Landing.jsx`
- [About page](https://github.com/khaja2988/fsdend/blob/main/src/pages/About.jsx): `src/pages/About.jsx`
- [Features page](https://github.com/khaja2988/fsdend/blob/main/src/pages/Features.jsx): `src/pages/Features.jsx`
- [Contact page](https://github.com/khaja2988/fsdend/blob/main/src/pages/Contact.jsx): `src/pages/Contact.jsx`

### Account access

- [Registration form](https://github.com/khaja2988/fsdend/blob/main/src/pages/Register.jsx): `src/pages/Register.jsx`
- [HR login](https://github.com/khaja2988/fsdend/blob/main/src/pages/Login.jsx): `src/pages/Login.jsx`
- [Employee login](https://github.com/khaja2988/fsdend/blob/main/src/pages/EmployeeLogin.jsx): `src/pages/EmployeeLogin.jsx`
- **Browser token store**

### HR dashboard

- [HR dashboard shell](https://github.com/khaja2988/fsdend/blob/main/src/pages/Dashboard.jsx): `src/pages/Dashboard.jsx`
- [Add employee](https://github.com/khaja2988/fsdend/blob/main/src/pages/AddEmployee.jsx): `src/pages/AddEmployee.jsx`
- [Employee details](https://github.com/khaja2988/fsdend/blob/main/src/pages/dashboard/EmployeeDetails.jsx): `src/pages/dashboard/EmployeeDetails.jsx`
- [Employee management](https://github.com/khaja2988/fsdend/blob/main/src/pages/dashboard/EmployeeManagement.jsx): `src/pages/dashboard/EmployeeManagement.jsx`
- [Delete employee](https://github.com/khaja2988/fsdend/blob/main/src/pages/dashboard/DeleteEmployee.jsx): `src/pages/dashboard/DeleteEmployee.jsx`
- [Leave management](https://github.com/khaja2988/fsdend/blob/main/src/pages/dashboard/LeaveManagement.jsx): `src/pages/dashboard/LeaveManagement.jsx`
- [Attendance](https://github.com/khaja2988/fsdend/blob/main/src/pages/dashboard/Attendance.jsx): `src/pages/dashboard/Attendance.jsx`
- [Performance reviews](https://github.com/khaja2988/fsdend/blob/main/src/pages/dashboard/PerformanceReviews.jsx): `src/pages/dashboard/PerformanceReviews.jsx`
- [Payroll management](https://github.com/khaja2988/fsdend/blob/main/src/pages/dashboard/PayrollManagement.jsx): `src/pages/dashboard/PayrollManagement.jsx`
- [HR profile](https://github.com/khaja2988/fsdend/blob/main/src/pages/dashboard/Profile.jsx): `src/pages/dashboard/Profile.jsx`
- [HR settings](https://github.com/khaja2988/fsdend/blob/main/src/pages/dashboard/Settings.jsx): `src/pages/dashboard/Settings.jsx`
- [Update employee](https://github.com/khaja2988/fsdend/blob/main/src/pages/dashboard/UpdateEmployee.jsx): `src/pages/dashboard/UpdateEmployee.jsx`

### Employee self-service

- [Employee dashboard](https://github.com/khaja2988/fsdend/blob/main/src/pages/EmployeeDashboard.jsx): `src/pages/EmployeeDashboard.jsx`
- [Employee leaves](https://github.com/khaja2988/fsdend/blob/main/src/pages/employee/Leaves.jsx): `src/pages/employee/Leaves.jsx`
- [Employee performance](https://github.com/khaja2988/fsdend/blob/main/src/pages/employee/Performance.jsx): `src/pages/employee/Performance.jsx`

### Other components

- **Visitor**
- **Employee user**
- **Employee API**

## Connections

- Visitor → Route application: opens
- Employee user → Route application: opens
- Route application → Site navigation: renders (evidence: `src/App.jsx`)
- Route application → Landing page: routes (evidence: `src/App.jsx`)
- Route application → About page: routes (evidence: `src/App.jsx`)
- Route application → Features page: routes (evidence: `src/App.jsx`)
- Route application → Contact page: routes (evidence: `src/App.jsx`)
- Route application → Registration form: routes (evidence: `src/App.jsx`)
- Route application → HR login: routes (evidence: `src/App.jsx`)
- Route application → Employee login: routes (evidence: `src/App.jsx`)
- Route application → Employee dashboard: routes (evidence: `src/App.jsx`)
- Route application → HR dashboard shell: protects route (evidence: `src/App.jsx`)
- Route application → Browser token store: checks token (evidence: `src/App.jsx`)
- HR login → Browser token store: writes token (evidence: `src/pages/Login.jsx`)
- Route application → Add employee: routes (evidence: `src/App.jsx`)
- Route application → Employee details: routes (evidence: `src/App.jsx`)
- Route application → Leave management: routes (evidence: `src/App.jsx`)
- Route application → Attendance: routes (evidence: `src/App.jsx`)
- Route application → Performance reviews: routes (evidence: `src/App.jsx`)
- Route application → Payroll management: routes (evidence: `src/App.jsx`)
- Route application → HR profile: routes (evidence: `src/App.jsx`)
- HR dashboard shell → Employee management: navigates to (evidence: `src/pages/Dashboard.jsx`)
- HR dashboard shell → Update employee: navigates to (evidence: `src/pages/Dashboard.jsx`)
- HR dashboard shell → HR settings: navigates to (evidence: `src/pages/Dashboard.jsx`)
- Route application → Delete employee: routes (evidence: `src/App.jsx`)
- Delete employee → Employee API: fetches and deletes (evidence: `src/pages/dashboard/DeleteEmployee.jsx`)
- Employee dashboard → Employee leaves: navigates to (evidence: `src/pages/EmployeeDashboard.jsx`)
- Employee dashboard → Employee performance: navigates to (evidence: `src/pages/EmployeeDashboard.jsx`)
