# benjidev028/mova architecture

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

- Interactive diagram: https://gitdiagram.com/benjidev028/mova
- Repository: https://github.com/benjidev028/mova

## Overview

##### Project Type and Purpose
- This is a React Native mobile application (“movaNB”) for a ride-hailing service.
- The README is minimal, but the file tree shows authentication flows, separate screens for drivers (conducteur), passengers (passager), and generic user management.
- It integrates with Google Places (two components under src/composants/googleplace*).

##### File Structure Analysis
- Top-level:
- movaNB/App.js, index.js, app.json – React Native entry points
- movaNB/assets – static images/intro
- movaNB/src/composants – reusable components (GooglePlaceInput, etc.)
- movaNB/src/navigation – React Navigation stacks and tab navigators
- movaNB/src/screen – feature folders (authentifaction, conducteur, passager, user) each containing screen modules
- Pattern: feature-based organization (each domain area has its own folder of screens) and a clear separation of navigation versus UI components.
- No backend code here – the mobile app consumes external APIs (authentication, ride-matching, Google Places).

##### Key Insights from README
- Title “mova” hints at mobility/ride-sharing.

##### Detailed Capture
- Don’t forget the feature grouping: authentication stack vs. client stack vs. tabs
- Call out reusable component library (src/composants) as a shared module
- Sequence for a full booking flow: login → search → select route → confirm → payment → confirmation

## Diagram (Mermaid)

```mermaid
flowchart TD
  subgraph "Mobile App"
    direction TB
    subgraph "Entry Points"
      AApp["App.js"]:::client
      AIndex["index.js"]:::client
      AJson["app.json"]:::client
    end
    subgraph "UI Component Library"
      UI1["GooglePlaceInputScreen"]:::client
      UI2["GooglePlacesInputPublicOnly"]:::client
    end
    subgraph "Navigation Layer"
      NMain["MainNavigator"]:::client
      NAuth["AuthStack"]:::client
      NClient["ClientStack"]:::client
      NTabs["ClientTabs"]:::client
    end
    subgraph "Auth Screens"
      Intro["IntroScreen"]:::client
      Login["LoginScreen"]:::client
      Register["RegisterScreen"]:::client
      CodeRec["CodeReceivedScreen"]:::client
      EmailVer["EmailVerifiedScreen"]:::client
      PassReset["PasswordResetScreen"]:::client
    end
    subgraph "Driver Screens"
      Pickup["PickupLocationScreen"]:::client
      DropOff["DropOffLocation"]:::client
      Pref["PreferenceScreen"]:::client
      RouteSel["RouteSelectionScreen"]:::client
      VehPrice["VehiculeAndPriceScreen"]:::client
      Review["ReviewAndConfirmScreen"]:::client
    end
    subgraph "Passenger Screens"
      ListFound["ListFoundScreen"]:::client
      DetailTrip["DetailTripScreen"]:::client
      FilterModal["FilterModalScreen"]:::client
      PayBooking["PayBooking"]:::client
    end
    subgraph "User Management Screens"
      Home["HomeScreen"]:::client
      SearchTraj["SearchTrajetScreen"]:::client
      AddTraj["AddTrajetScreen"]:::client
      MesTraj["MesTrajetsScreen"]:::client
      Profile["ProfileScreen"]:::client
    end
    subgraph "API Client Layer"
      AuthServiceClient["Auth API Client"]:::client
      RideServiceClient["Ride API Client"]:::client
      PaymentServiceClient["Payment API Client"]:::client
      GooglePlacesClient["Google Places Client"]:::client
    end
  end

  subgraph "Backend Services"
    direction TB
    AuthService["Authentication Service"]:::backend
    RideService["Ride Management Service"]:::backend
    PaymentService["Payment Service"]:::backend
    UserDB["User/Profile DB"]:::db
    TripDB["Trip/Booking DB"]:::db
  end

  subgraph "External APIs"
    direction TB
    GooglePlacesAPI["Google Places API"]:::external
    PaymentGateway["Payment Gateway"]:::external
  end

  AApp -->|launches| NMain
  NMain -->|uses| NAuth
  NMain -->|uses| NClient
  NAuth -->|login/register| AuthServiceClient
  AuthServiceClient -->|"POST /auth/login"| AuthService
  AuthService -->|"JWT/user data"| AuthServiceClient
  NClient -->|tab navigation| NTabs
  NTabs -->|ClientStack| NClient

  AuthServiceClient --> AuthService
  RideServiceClient --> RideService
  PaymentServiceClient --> PaymentService
  GooglePlacesClient --> GooglePlacesAPI

  Login --> AuthServiceClient
  Register --> AuthServiceClient
  RouteSel --> RideServiceClient
  ListFound --> RideServiceClient
  PayBooking --> PaymentServiceClient
  UI1 --> GooglePlacesClient
  UI2 --> GooglePlacesClient

  AuthService --> UserDB
  RideService --> TripDB
  UserDB -- data --> RideService
  PaymentService --> PaymentGateway
  UI1 -.->|autocomplete| GooglePlacesAPI
  UI2 -.->|autocomplete| GooglePlacesAPI

  click AApp "https://github.com/benjidev028/mova/blob/main/movaNB/App.js"
  click AIndex "https://github.com/benjidev028/mova/blob/main/movaNB/index.js"
  click AJson "https://github.com/benjidev028/mova/blob/main/movaNB/app.json"
  click UI1 "https://github.com/benjidev028/mova/blob/main/src/composants/googleplace/GooglePlaceInputScreen.js"
  click UI2 "https://github.com/benjidev028/mova/blob/main/src/composants/googleplacepublic/GooglePlacesInputPublicOnly.js"
  click NMain "https://github.com/benjidev028/mova/blob/main/src/navigation/MainNavigator.js"
  click NAuth "https://github.com/benjidev028/mova/blob/main/src/navigation/client/AuthStack.js"
  click NClient "https://github.com/benjidev028/mova/blob/main/src/navigation/client/ClientStack.js"
  click NTabs "https://github.com/benjidev028/mova/blob/main/src/navigation/client/ClientTabs.js"
  click Intro "https://github.com/benjidev028/mova/blob/main/src/screen/authentifaction/Intro/IntroScreen.js"
  click Login "https://github.com/benjidev028/mova/blob/main/src/screen/authentifaction/login/LoginScreen.js"
  click Register "https://github.com/benjidev028/mova/blob/main/src/screen/authentifaction/register/RegisterScreen.js"
  click CodeRec "https://github.com/benjidev028/mova/blob/main/src/screen/authentifaction/CodeReceived/CodeReceivedScreen.js"
  click EmailVer "https://github.com/benjidev028/mova/blob/main/src/screen/authentifaction/EmailVerified/EmailVerifiedScreen.js"
  click PassReset "https://github.com/benjidev028/mova/blob/main/src/screen/authentifaction/PasswordReset/PasswordResetScreen.js"
  click Pickup "https://github.com/benjidev028/mova/blob/main/src/screen/conducteur/PickupLocation/PickupLocationScreen.js"
  click DropOff "https://github.com/benjidev028/mova/blob/main/src/screen/conducteur/DropOffLocation/DropOffLocation.js"
  click Pref "https://github.com/benjidev028/mova/blob/main/src/screen/conducteur/Preference/PreferenceScreen.js"
  click RouteSel "https://github.com/benjidev028/mova/blob/main/src/screen/conducteur/RouteSelection/RouteSelectionScreen.js"
  click VehPrice "https://github.com/benjidev028/mova/blob/main/src/screen/conducteur/VehiculeAndPrice/VehiculeAndPriceScreen.js"
  click Review "https://github.com/benjidev028/mova/blob/main/src/screen/conducteur/ReviewAndConfirm/ReviewAndConfirmScreen.js"
  click ListFound "https://github.com/benjidev028/mova/blob/main/src/screen/passager/ListFound/ListFoundScreen.js"
  click DetailTrip "https://github.com/benjidev028/mova/blob/main/src/screen/passager/DetailTrip/DetailTripScreen.js"
  click FilterModal "https://github.com/benjidev028/mova/blob/main/src/screen/passager/FilterModal/FilterModalScreen.js"
  click PayBooking "https://github.com/benjidev028/mova/blob/main/src/screen/passager/PayBooking/PayBooking.js"
  click Home "https://github.com/benjidev028/mova/blob/main/src/screen/user/Home/HomeScreen.js"
  click SearchTraj "https://github.com/benjidev028/mova/blob/main/src/screen/user/SearchTrajet/SearchTrajetScreen.js"
  click AddTraj "https://github.com/benjidev028/mova/blob/main/src/screen/user/AddTrajet/AddTrajetScreen.js"
  click MesTraj "https://github.com/benjidev028/mova/blob/main/src/screen/user/MesTrajets/MesTrajetsScreen.js"
  click Profile "https://github.com/benjidev028/mova/blob/main/src/screen/user/Profile/ProfileScreen.js"

  classDef client fill:#BBE1FA,stroke:#1E81B0
  classDef backend fill:#C8E6C9,stroke:#388E3C
  classDef db fill:#FFF3C4,stroke:#F9A825
  classDef external fill:#FFE0B2,stroke:#E65100
```
