# koushikm8926/medistor architecture

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

- Interactive diagram: https://gitdiagram.com/koushikm8926/medistor
- Repository: https://github.com/koushikm8926/medistor

## Overview

##### Main Components

a. Client-Side (Mobile App)
- Authentication Layer
- Login/Signup screens
- Password reset functionality
- Navigation System
- Song Management
- Song lists by category (All, Cancons, Dites, Histories, Legends)
- Audio player functionality
- User Interface Components
- Screen components
- Views
- Player controls

b. Assets Management
- Audio Files System
- Image Resources

c. Platform-Specific Components
- iOS Implementation
- Android Implementation

**┌─────────────────────────────────────────────┐**
- Presentation Layer           │
- (Screens, Navigation, UI Components)        │
- ┤
- Business Layer               │
- (Audio Player, Auth Logic, State Management)│
- ┤
- Data Layer                   │
- (Audio Files, Assets, Local Storage)        │
- ┘

##### Key Relationships to Highlight

a. User Flow:
- Authentication flow between Login/Signup/Reset screens
- Navigation paths between different song list screens
- Player screen interactions

b. Data Flow:
- Audio file loading and playback
- User session management
- Asset loading and caching

##### Specific Implementation Details

- How the audio player interfaces with the native modules
- Screen navigation hierarchy
- Authentication state management
- Platform-specific implementations for iOS and Android

##### Component Breakdown

**Authentication Module**
- LoginScreen
- SignupScreen
- ResetPassword

**Song Management**
- AllSongs
- CanconsSongs
- DitesSongs
- HistoriesSongs
- LegendsSongs

**Player Implementation**
- Audio Controller
- Playback UI
- Asset Management

##### Additional Elements

Symbols for:
- User interaction points (👤)
- Data storage points (💾)
- Audio processing (🔊)
- Navigation flows (➡️)

## Diagram (Mermaid)

```mermaid
graph TB
    subgraph "Presentation Layer"
        UI_Auth[Authentication UI]
        UI_Lists[Song Lists UI]
        UI_Player[Player UI]
        UI_Nav[Navigation UI]
    end

    subgraph "Business Layer"
        Auth[Authentication Logic]
        SongMgmt[Song Management]
        PlaybackCtrl[Playback Controller]
        NavSystem[Navigation System]
    end

    subgraph "Data Layer"
        AudioFiles[Audio Files]
        ImageRes[Image Resources]
        LocalStorage[Local Storage]
    end

    subgraph "Platform Layer"
        IOS[iOS Implementation]
        Android[Android Implementation]
    end

    subgraph "Authentication Screens"
        Login[Login Screen]
        Signup[Signup Screen]
        Reset[Reset Password]
        Welcome[Welcome Screen]
    end

    subgraph "Song List Screens"
        AllList[All Songs List]
        CanconsList[Cancons List]
        DitesList[Dites List]
        HistoriesList[Histories List]
        LegendsList[Legends List]
    end

    subgraph "Playback Screens"
        AllPlay[All Songs Play]
        CanconsPlay[Cancons Play]
        DitesPlay[Dites Play]
        HistoriesPlay[Histories Play]
        LegendsPlay[Legends Play]
    end

    %% Core Application Components
    App[App Component]
    Index[Entry Point]

    %% Additional Screens
    Home[Home Screen]
    Profile[Profile Screen]
    Privacy[Privacy Screen]

    %% Relationships
    UI_Auth --> Auth
    Auth --> LocalStorage
    UI_Lists --> SongMgmt
    SongMgmt --> AudioFiles
    UI_Player --> PlaybackCtrl
    PlaybackCtrl --> AudioFiles
    NavSystem --> UI_Nav

    %% Platform Connections
    PlaybackCtrl --> IOS
    PlaybackCtrl --> Android

    %% Screen Relationships
    UI_Auth --> Login & Signup & Reset & Welcome
    UI_Lists --> AllList & CanconsList & DitesList & HistoriesList & LegendsList
    UI_Player --> AllPlay & CanconsPlay & DitesPlay & HistoriesPlay & LegendsPlay

    %% Click Events
    click Login "https://github.com/koushikm8926/medistor/blob/main/screens/LoginScreen.js"
    click Signup "https://github.com/koushikm8926/medistor/blob/main/screens/SignupScreen.js"
    click Reset "https://github.com/koushikm8926/medistor/blob/main/screens/ResetPassword.js"
    click Welcome "https://github.com/koushikm8926/medistor/blob/main/screens/WellcomeScreen.js"
    click AllList "https://github.com/koushikm8926/medistor/blob/main/screens/AllSongsListScreen.js"
    click CanconsList "https://github.com/koushikm8926/medistor/blob/main/screens/CanconsSongsListScreen.js"
    click DitesList "https://github.com/koushikm8926/medistor/blob/main/screens/DitesSongsListScreen.js"
    click HistoriesList "https://github.com/koushikm8926/medistor/blob/main/screens/HistoriesSongsListScreen.js"
    click LegendsList "https://github.com/koushikm8926/medistor/blob/main/screens/LegendsSongsListScreen.js"
    click AllPlay "https://github.com/koushikm8926/medistor/blob/main/screens/AllSongsPlayScreen.js"
    click CanconsPlay "https://github.com/koushikm8926/medistor/blob/main/screens/CanConsSongsPlayScreen.js"
    click DitesPlay "https://github.com/koushikm8926/medistor/blob/main/screens/DitesSongsPlayScreen.js"
    click HistoriesPlay "https://github.com/koushikm8926/medistor/blob/main/screens/HistoriesSongPlayScreen.js"
    click LegendsPlay "https://github.com/koushikm8926/medistor/blob/main/screens/LegendsSongsPlayScreens.js"
    click AudioFiles "https://github.com/koushikm8926/medistor/tree/main/audios/"
    click ImageRes "https://github.com/koushikm8926/medistor/tree/main/images/"
    click IOS "https://github.com/koushikm8926/medistor/blob/main/ios/songplayer/AppDelegate.mm"
    click Android "https://github.com/koushikm8926/medistor/blob/main/android/app/src/main/java/com/songplayer/MainActivity.kt"
    click App "https://github.com/koushikm8926/medistor/blob/main/App.js"
    click Index "https://github.com/koushikm8926/medistor/blob/main/index.js"
    click Home "https://github.com/koushikm8926/medistor/blob/main/screens/HomeScreen.js"
    click Profile "https://github.com/koushikm8926/medistor/blob/main/screens/ProfileScreen.js"
    click Privacy "https://github.com/koushikm8926/medistor/blob/main/screens/PrivacyScreen.js"

    %% Styling
    classDef auth fill:#e6e6fa
    classDef ui fill:#add8e6
    classDef business fill:#90ee90
    classDef data fill:#ffa500
    classDef platform fill:#d3d3d3

    class UI_Auth,Auth,Login,Signup,Reset,Welcome auth
    class UI_Lists,UI_Player,UI_Nav ui
    class SongMgmt,PlaybackCtrl,NavSystem business
    class AudioFiles,ImageRes,LocalStorage data
    class IOS,Android platform
```
