# srhridoy/notes_app_using_hive_and_getx architecture

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

- Interactive diagram: https://gitdiagram.com/srhridoy/notes_app_using_hive_and_getx
- Repository: https://github.com/srhridoy/notes_app_using_hive_and_getx

## Overview

##### Main Components Identification

a) Presentation Layer
- UI Components (from /lib/ui/)
- Screens (home_screen.dart, note_details_screen.dart)
- Styling & Resources (from /lib/utils/)

b) Business Logic Layer
- Controllers (from /lib/controllers/)
- Models (from /lib/models/)

c) Data Persistence Layer
- Hive Database (implied by project name)

- ┌─────────────────────────────────────┐
- UI Layer                 │
- (Screens, Widgets, Styling Utils)  │
- ┘
- ↕
- ┌─────────────────────────────────────┐
- Controller Layer            │
- (Business Logic, State Mgmt)    │
- ┘
- ↕
- ┌─────────────────────────────────────┐
- Data Layer                │
- (Models, Hive Database)          │
- ┘

##### Component Details

- Rectangles with rounded corners for UI components (blue)
- Regular rectangles for controllers (green)
- Hexagons for models (purple)

##### Specific Elements

a) UI Layer:
- HomeScreen
- NoteDetailsScreen
- Utils (AllColors, AllSizes, AllStyles)

b) Controller Layer:
- HomeController

c) Data Layer:
- NoteModel
- Hive Database

##### Flow Representation

- User interaction flow
- Data flow between layers
- CRUD operations

##### Platform-Specific Elements

- Android support
- iOS support

##### Additional Details

Annotations for:
- Flutter framework version
- Hive database integration
- Platform support (iOS/Android)

- High-level architecture visualization
- Specific implementation details
- Clear data flow representation
- Component relationships

Keep the focus on the main architectural components while showing how the Flutter-specific elements (UI, Controllers, Models) interact with each other and the Hive database.

Remember to:
- Use clear, readable labels
- Maintain consistent spacing and alignment
- A title and brief description
- Version information

## Diagram (Mermaid)

```mermaid
flowchart TB
    subgraph "UI Layer"
        HomeScreen["Home Screen"]
        NoteDetailsScreen["Note Details Screen"]
        
        subgraph "Styling & Resources"
            AllColors["All Colors"]
            AllSizes["All Sizes"]
            AllStyles["All Styles"]
        end
    end

    subgraph "Business Logic Layer"
        HomeController["Home Controller"]
        MainApp["Main App"]
    end

    subgraph "Data Layer"
        NoteModel["Note Model"]
        HiveDB[(Hive Database)]
    end

    subgraph "Platform Layer"
        Android["Android Native"]
        iOS["iOS Native"]
    end

    %% Relationships
    HomeScreen --> HomeController
    NoteDetailsScreen --> HomeController
    HomeController --> NoteModel
    NoteModel --> HiveDB
    MainApp --> HomeScreen
    MainApp --> NoteDetailsScreen
    
    %% Styling Resources Relationships
    AllColors --> HomeScreen
    AllColors --> NoteDetailsScreen
    AllSizes --> HomeScreen
    AllSizes --> NoteDetailsScreen
    AllStyles --> HomeScreen
    AllStyles --> NoteDetailsScreen
    
    %% Platform Relationships
    Android --> MainApp
    iOS --> MainApp

    %% Click Events
    click HomeScreen "https://github.com/SRHridoy/Notes_App_using_Hive_and_Getx/blob/main/lib/ui/home_screen.dart"
    click NoteDetailsScreen "https://github.com/SRHridoy/Notes_App_using_Hive_and_Getx/blob/main/lib/ui/note_details_screen.dart"
    click AllColors "https://github.com/SRHridoy/Notes_App_using_Hive_and_Getx/blob/main/lib/utils/all_colors.dart"
    click AllSizes "https://github.com/SRHridoy/Notes_App_using_Hive_and_Getx/blob/main/lib/utils/all_sizes.dart"
    click AllStyles "https://github.com/SRHridoy/Notes_App_using_Hive_and_Getx/blob/main/lib/utils/all_styles.dart"
    click HomeController "https://github.com/SRHridoy/Notes_App_using_Hive_and_Getx/blob/main/lib/controllers/home_controller.dart"
    click NoteModel "https://github.com/SRHridoy/Notes_App_using_Hive_and_Getx/blob/main/lib/models/note_model.dart"
    click MainApp "https://github.com/SRHridoy/Notes_App_using_Hive_and_Getx/blob/main/lib/main.dart"
    click Android "https://github.com/SRHridoy/Notes_App_using_Hive_and_Getx/tree/main/android/app/src/main/"
    click iOS "https://github.com/SRHridoy/Notes_App_using_Hive_and_Getx/tree/main/ios/Runner/"

    %% Styling
    classDef ui fill:#a8d1ff,stroke:#333,stroke-width:2px
    classDef controller fill:#90EE90,stroke:#333,stroke-width:2px
    classDef model fill:#DDA0DD,stroke:#333,stroke-width:2px
    classDef database fill:#FFA500,stroke:#333,stroke-width:2px
    classDef platform fill:#D3D3D3,stroke:#333,stroke-width:2px
    classDef styling fill:#FFB6C1,stroke:#333,stroke-width:2px

    class HomeScreen,NoteDetailsScreen ui
    class HomeController,MainApp controller
    class NoteModel model
    class HiveDB database
    class Android,iOS platform
    class AllColors,AllSizes,AllStyles styling
```
