# sujal880/blinkit-ui architecture

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

- Interactive diagram: https://gitdiagram.com/sujal880/blinkit-ui
- Repository: https://github.com/sujal880/blinkit-ui

## Overview

##### Project Type and Purpose
- This is a cross-platform mobile application built with Flutter (Dart) targeting Android and iOS.
- Purpose appears to be a multi-screen app (login, splash, home, category, cart, print, bottom navigation) with a shared “domain” constants layer and reusable UI widgets.

##### File Structure Analysis
Top-level directories:
- android – Native Android project and Gradle build.
- ios    – Native iOS Xcode workspace and Swift/Objective-C bridge.
- lib    – Dart source:
– domain/constants (appcolors.dart)
– main.dart (app entrypoint)
– repository/screens (feature modules: login, splash, home, category, cart, print, bottomnav)
– repository/widgets (shared UI helpers)
- assets – Fonts and images used by the app.
- test   – Widget-level tests.
Build/config files: pubspec.yaml (dependencies/assets), Gradle wrappers, Xcode configs.

##### README Insights
- No architectural overview provided. We’ll infer a layered Flutter architecture with clear presentation (screens/widgets) and domain constant layers.

## Diagram (Mermaid)

```mermaid
flowchart TB
    %% Platform Layers
    subgraph "Android Host"
        AndroidShell["Gradle & Kotlin Entrypoint\nMainActivity.kt"]:::platform
        AndroidShell -->|"launch"| FlutterEngine
        AndroidShell -->|"build"| APK["APK/AAB"]:::build
    end

    subgraph "iOS Host"
        iOSShell["Xcode & Swift Entrypoint\nAppDelegate.swift"]:::platform
        iOSShell -->|"launch"| FlutterEngine
        iOSShell -->|"build"| IPA["IPA"]:::build
    end

    %% Engine Layer
    FlutterEngine["Flutter Engine & Dart Runtime"]:::engine
    FlutterEngine -->|"start"| Main

    %% Entry Point
    Main["main.dart"]:::app
    Main -->|"navigate"| SplashScreen

    %% Presentation Layer
    subgraph "Presentation Layer" 
        direction TB
        SplashScreen["SplashScreen"]:::presentation
        LoginScreen["LoginScreen"]:::presentation
        HomeScreen["HomeScreen"]:::presentation
        CategoryScreen["CategoryScreen"]:::presentation
        CartScreen["CartScreen"]:::presentation
        PrintScreen["PrintScreen"]:::presentation
        BottomNavScreen["BottomNavigationScreen"]:::presentation

        SplashScreen -->|"next"| LoginScreen
        LoginScreen -->|"next"| HomeScreen
        HomeScreen -->|"next"| CategoryScreen
        CategoryScreen -->|"next"| CartScreen
        CartScreen -->|"next"| PrintScreen
        PrintScreen -->|"next"| BottomNavScreen

        SplashScreen -->|"uses"| UIHelper
        LoginScreen -->|"uses"| UIHelper
        HomeScreen -->|"uses"| UIHelper
        CategoryScreen -->|"uses"| UIHelper
        CartScreen -->|"uses"| UIHelper
        PrintScreen -->|"uses"| UIHelper
        BottomNavScreen -->|"uses"| UIHelper
    end

    UIHelper["UIHelper"]:::presentation
    UIHelper -->|"uses"| Constants
    UIHelper -->|"loads"| Fonts
    UIHelper -->|"loads"| Images

    %% Domain Layer
    subgraph "Domain Layer"
        Constants["appcolors.dart"]:::domain
    end

    %% Assets Module
    subgraph "Assets Module"
        Fonts["Fonts"]:::assets
        Images["Images"]:::assets
    end

    %% External Services Placeholder
    ExternalAPI["External API / Services"]:::external
    Main -.->|"future calls"| ExternalAPI

    %% Testing & Config
    Pubspec["pubspec.yaml"]:::config
    Test["widget_test.dart"]:::test
    Pubspec -.-> Assets
    Test -.-> PresentationLayer

    %% Click Events
    click AndroidShell "https://github.com/sujal880/blinkit-ui/blob/master/android/app/src/main/kotlin/com/example/blinkit_series/MainActivity.kt"
    click iOSShell "https://github.com/sujal880/blinkit-ui/blob/master/ios/Runner/AppDelegate.swift"
    click Main "https://github.com/sujal880/blinkit-ui/blob/master/lib/main.dart"
    click SplashScreen "https://github.com/sujal880/blinkit-ui/blob/master/lib/repository/screens/splash/splashscreen.dart"
    click LoginScreen "https://github.com/sujal880/blinkit-ui/blob/master/lib/repository/screens/login/loginscreen.dart"
    click HomeScreen "https://github.com/sujal880/blinkit-ui/blob/master/lib/repository/screens/home/homescreen.dart"
    click CategoryScreen "https://github.com/sujal880/blinkit-ui/blob/master/lib/repository/screens/category/categoryscreen.dart"
    click CartScreen "https://github.com/sujal880/blinkit-ui/blob/master/lib/repository/screens/cart/cartscreen.dart"
    click PrintScreen "https://github.com/sujal880/blinkit-ui/blob/master/lib/repository/screens/print/printscreen.dart"
    click BottomNavScreen "https://github.com/sujal880/blinkit-ui/blob/master/lib/repository/screens/bottomnav/bottomnavscreen.dart"
    click UIHelper "https://github.com/sujal880/blinkit-ui/blob/master/lib/repository/widgets/uihelper.dart"
    click Constants "https://github.com/sujal880/blinkit-ui/blob/master/lib/domain/constants/appcolors.dart"
    click Fonts "https://github.com/sujal880/blinkit-ui/tree/master/assets/fonts/"
    click Images "https://github.com/sujal880/blinkit-ui/tree/master/assets/images/"
    click Pubspec "https://github.com/sujal880/blinkit-ui/blob/master/pubspec.yaml"
    click Test "https://github.com/sujal880/blinkit-ui/blob/master/test/widget_test.dart"

    %% Styles
    classDef platform fill:#cce5ff,stroke:#66b0ff,color:#003366
    classDef engine fill:#d4edda,stroke:#8fd19e,color:#155724
    classDef app fill:#e2e3e5,stroke:#bcbcbe,color:#383d41
    classDef presentation fill:#ffe5b4,stroke:#ffcc80,color:#663c00
    classDef domain fill:#fff3cd,stroke:#ffe8a1,color:#856404
    classDef assets fill:#e2e3e5,stroke:#bcbcbe,color:#383d41
    classDef external fill:#f8d7da,stroke:#f5c6cb,color:#721c24,stroke-dasharray: 5 5
    classDef build fill:#d1ecf1,stroke:#a3d5e6,color:#0c5460
    classDef config fill:#d1ecf1,stroke:#a3d5e6,color:#0c5460
    classDef test fill:#f0f0f0,stroke:#cccccc,color:#333333
```
