# biki-das/feedback-app architecture

> Architecture diagram of the GitHub repository biki-das/feedback-app, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2025-01-22). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/biki-das/feedback-app
- Repository: https://github.com/biki-das/feedback-app

## Overview

##### Main System Components

A. Frontend Layer
- Subdivide into main feature modules:
- Authentication (Auth components)
- Feedback Management
- Comments & Replies
- Roadmap
- Sidebar Components

B. State Management Layer
- User state
- Filter state
- Sort state

C. Backend/Database Layer
- Supabase integration (shown by Supabaseconfig.ts)

##### Component Relationships

A. User Interface Flow
**Auth → Feedback → Comments → Replies**
- ↑
**Sidebar (Filters & Roadmap)**

B. Data Flow
**UI Components ↔ Redux Store ↔ Supabase**

##### Specific Implementation Details

Key architectural elements:

A. Frontend Architecture
- Component hierarchy:
- Protected Routes
- Main App Container
- Feature Components
- Utility Components

B. State Management
- Redux store structure:
- Actions
- Reducers
- State slices

Create these distinct sections:

**┌─ User Interface Layer ─────────────────┐**
- ┌─Auth─┐ ┌─Feedback─┐ ┌─Comments─┐    │
- Login │ │List     │ │Add      │    │
- Signup│ │Details  │ │Reply    │    │
- ┘ └─────────┘ └─────────┘    │
- State Management Layer ──────────────┤
- ┌─Redux Store─────────────────┐      │
- Filters | Sort | User State  │      │
- ┘        │
- Backend Layer ────────────────────────┤
- ┌─Supabase────────────────────┐      │
- Auth | Data | Real-time      │      │
- ┘        │
- ┘

##### Important Notes

- Real-time nature of the application
- Protected route wrapper around authenticated features
- Filtering and sorting capabilities
- Roadmap's drag-and-drop functionality
- Mobile responsiveness consideration (via MobileSidebar component)

##### Technical Stack Indicators

- React (Frontend framework)
- Redux (State management)
- Supabase (Backend as a Service)
- TypeScript (Type system)
- Tailwind CSS (Styling)

## Diagram (Mermaid)

```mermaid
graph TB
    %% Styles and Classes
    classDef frontend fill:#3498db,stroke:#2980b9,color:white
    classDef state fill:#2ecc71,stroke:#27ae60,color:white
    classDef backend fill:#f1c40f,stroke:#f39c12,color:black
    classDef utils fill:#9b59b6,stroke:#8e44ad,color:white
    classDef auth fill:#e74c3c,stroke:#c0392b,color:white
    
    %% Main Application Container
    APP["Main App Container"]:::frontend
    click APP "https://github.com/Biki-das/Feedback-App/blob/master/src/App.tsx"

    %% Frontend Layer
    subgraph Frontend
        %% Authentication
        AUTH["Authentication Module"]:::auth
        click AUTH "https://github.com/Biki-das/Feedback-App/tree/master/src/Components/Auth/"
        
        %% Protected Routes
        PROT["Protected Routes"]:::auth
        click PROT "https://github.com/Biki-das/Feedback-App/blob/master/src/Components/Route/ProtectedRoute.jsx"
        
        %% Main Features
        FEED["Feedback Management"]:::frontend
        click FEED "https://github.com/Biki-das/Feedback-App/tree/master/src/Components/Feedback/"
        
        COMM["Comments System"]:::frontend
        click COMM "https://github.com/Biki-das/Feedback-App/tree/master/src/Components/Comment/"
        
        REPLY["Reply System"]:::frontend
        click REPLY "https://github.com/Biki-das/Feedback-App/tree/master/src/Components/Reply/"
        
        ROAD["Roadmap"]:::frontend
        click ROAD "https://github.com/Biki-das/Feedback-App/tree/master/src/Components/Roadmap/"
        
        %% Sidebar
        SIDE["Sidebar Components"]:::frontend
        click SIDE "https://github.com/Biki-das/Feedback-App/tree/master/src/Components/SideBarComponent/"
        
        MOBILE["Mobile Sidebar"]:::frontend
        click MOBILE "https://github.com/Biki-das/Feedback-App/blob/master/src/Components/SideBarComponent/Mobilesidebar.jsx"
        
        %% Utils
        UTILS["Utility Functions"]:::utils
        click UTILS "https://github.com/Biki-das/Feedback-App/tree/master/src/Components/Utils/"
    end

    %% State Management Layer
    subgraph StateManagement
        REDUX{"Redux Store"}:::state
        
        USER["User State"]:::state
        click USER "https://github.com/Biki-das/Feedback-App/tree/master/src/Redux/User/"
        
        FILTER["Filter State"]:::state
        click FILTER "https://github.com/Biki-das/Feedback-App/tree/master/src/Redux/Filter/"
        
        SORT["Sort State"]:::state
        click SORT "https://github.com/Biki-das/Feedback-App/tree/master/src/Redux/Sort/"
    end

    %% Backend Layer
    subgraph Backend
        SUPA["Supabase Integration"]:::backend
        click SUPA "https://github.com/Biki-das/Feedback-App/blob/master/src/Supabase/Supabaseconfig.ts"
    end

    %% Relationships
    APP --> AUTH
    APP --> PROT
    PROT --> FEED
    FEED --> COMM
    COMM --> REPLY
    PROT --> ROAD
    APP --> SIDE
    SIDE --> MOBILE
    
    %% State Management Connections
    FEED <--> REDUX
    COMM <--> REDUX
    REPLY <--> REDUX
    ROAD <--> REDUX
    SIDE <--> REDUX
    
    REDUX --> USER
    REDUX --> FILTER
    REDUX --> SORT
    
    %% Backend Connections
    REDUX <--> SUPA
    AUTH <--> SUPA
    
    %% Utility Connections
    UTILS --> FEED
    UTILS --> COMM
    UTILS --> REPLY
    UTILS --> ROAD

    %% Legend
    subgraph Legend
        L1["Frontend Components"]:::frontend
        L2["State Management"]:::state
        L3["Backend Services"]:::backend
        L4["Utility Functions"]:::utils
        L5["Authentication"]:::auth
    end
```
