# thureinlynn/burmeal architecture

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

- Interactive diagram: https://gitdiagram.com/thureinlynn/burmeal
- Repository: https://github.com/thureinlynn/burmeal

## Overview

BurMeal is a local food-discovery and shop marketplace: customers browse and filter shop menus and time-limited daily specials, while shop owners manage their shop and listings. The React app coordinates authentication, location-aware discovery, profiles, and owner workflows; API and Firebase/Supabase services provide backend and media access. The tree also shows admin, customer-profile, sharing, and install-related capabilities. Source excerpts are partial and the README is empty, so some feature links and backend routing remain unverified and are shown as dashed or omitted.

Main entry points: [`src/App.tsx`](https://github.com/thureinlynn/burmeal/blob/main/src/App.tsx) (Marketplace app), [`src/main.tsx`](https://github.com/thureinlynn/burmeal/blob/main/src/main.tsx) (App entry), [`src/components/ShopDashboard.tsx`](https://github.com/thureinlynn/burmeal/blob/main/src/components/ShopDashboard.tsx) (Shop dashboard), [`src/context/AuthContext.tsx`](https://github.com/thureinlynn/burmeal/blob/main/src/context/AuthContext.tsx) (Authentication)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_app["App and identity"]
  node_entry["App entry<br/>[main.tsx]"]
  node_application["Marketplace app<br/>[App.tsx]"]
  node_authentication["Authentication<br/>[AuthContext.tsx]"]
  node_auth_ui["Sign-in UI<br/>[AuthModal.tsx]"]
  node_location["Location context"]
  node_location_ui["Location selection<br/>[LocationModal.tsx]"]
  node_language["Language context"]
end

subgraph group_discovery["Food discovery"]
  node_feed["Discovery feed<br/>[App.tsx]"]
  node_filters["Menu and region filters<br/>[filter.ts]"]
  node_search["Smart search<br/>[smartSearch.ts]"]
  node_specials["Daily specials"]
  node_shop_profile["Shop profile"]
  node_pagination["Feed pagination"]
end

subgraph group_merchant["Merchant tools"]
  node_merchant_dashboard["Shop dashboard<br/>[ShopDashboard.tsx]"]
  node_menu_rules["Menu availability"]
  node_menu_limits["Menu limits"]
  node_admin["Administration<br/>[AdminPanel.tsx]"]
  node_customer_profile["Customer profile"]
end

subgraph group_services["Data and services"]
  node_api["API client<br/>[apiClient.ts]"]
  node_backend["Application server<br/>[server.ts]"]
  node_database[("Server database<br/>[db.ts]")]
  node_sync["Firestore sync<br/>[firestoreSync.ts]"]
  node_firestore_service["Firestore service"]
  node_firebase["Firebase setup<br/>[firebase.ts]"]
  node_supabase["Supabase storage<br/>[supabaseClient.ts]"]
end

subgraph group_shared["Shared domain"]
  node_types["Domain types<br/>[index.ts]"]
  node_countries["Countries and currencies<br/>[countries.ts]"]
  node_shop_locations["Shop location helpers"]
  node_badges["Shop service badges"]
  node_sharing["Sharing helpers<br/>[shareHelpers.ts]"]
  node_language_data["Translations<br/>[i18n.ts]"]
end

node_customer(("Customer"))
node_owner(("Shop owner"))
node_external_services[("Firebase and Supabase")]

node_customer -->|"opens"| node_entry
node_owner -->|"opens"| node_entry
node_entry -->|"renders"| node_application
node_entry -->|"provides context"| node_authentication
node_entry -->|"provides context"| node_language
node_entry -->|"provides context"| node_location
node_application -->|"renders"| node_feed
node_application -->|"uses"| node_authentication
node_application -->|"uses"| node_location
node_application -->|"requests data"| node_api
node_application -.->|"renders"| node_auth_ui
node_application -.->|"renders"| node_location_ui
node_application -.->|"renders"| node_merchant_dashboard
node_application -.->|"renders"| node_admin
node_application -.->|"renders"| node_customer_profile
node_feed -.->|"filters"| node_filters
node_filters -->|"searches"| node_search
node_feed -.->|"uses"| node_specials
node_application -.->|"renders"| node_shop_profile
node_shop_profile -->|"uses"| node_pagination
node_merchant_dashboard -->|"uses"| node_menu_rules
node_merchant_dashboard -->|"uses"| node_menu_limits
node_authentication -->|"authenticates with"| node_firebase
node_authentication -->|"loads profiles"| node_firestore_service
node_application -->|"calls"| node_api
node_api -.->|"requests routes"| node_backend
node_backend -->|"uses"| node_database
node_backend -->|"uses"| node_sync
node_firestore_service -->|"uses"| node_firebase
node_firestore_service -->|"deletes media"| node_supabase
node_firebase -.->|"connects"| node_external_services
node_supabase -.->|"stores media"| node_external_services
node_application -->|"uses"| node_types
node_application -->|"uses"| node_sharing
node_application -.->|"uses"| node_badges
node_filters -->|"gets currency"| node_countries
node_location_ui -->|"uses"| node_countries
node_location -->|"uses"| node_countries
node_language -->|"reads translations"| node_language_data
node_merchant_dashboard -->|"uses"| node_shop_locations

click node_entry "https://github.com/thureinlynn/burmeal/blob/main/src/main.tsx"
click node_application "https://github.com/thureinlynn/burmeal/blob/main/src/App.tsx"
click node_authentication "https://github.com/thureinlynn/burmeal/blob/main/src/context/AuthContext.tsx"
click node_auth_ui "https://github.com/thureinlynn/burmeal/blob/main/src/components/AuthModal.tsx"
click node_location "https://github.com/thureinlynn/burmeal/blob/main/src/context/LocationContext.tsx"
click node_location_ui "https://github.com/thureinlynn/burmeal/blob/main/src/components/LocationModal.tsx"
click node_language "https://github.com/thureinlynn/burmeal/blob/main/src/context/LanguageContext.tsx"
click node_feed "https://github.com/thureinlynn/burmeal/blob/main/src/App.tsx"
click node_filters "https://github.com/thureinlynn/burmeal/blob/main/src/utils/filter.ts"
click node_search "https://github.com/thureinlynn/burmeal/blob/main/src/utils/smartSearch.ts"
click node_specials "https://github.com/thureinlynn/burmeal/blob/main/src/utils/dailySpecialHelpers.ts"
click node_shop_profile "https://github.com/thureinlynn/burmeal/blob/main/src/components/ShopProfileView.tsx"
click node_pagination "https://github.com/thureinlynn/burmeal/blob/main/src/utils/paginationHelpers.ts"
click node_merchant_dashboard "https://github.com/thureinlynn/burmeal/blob/main/src/components/ShopDashboard.tsx"
click node_menu_rules "https://github.com/thureinlynn/burmeal/blob/main/src/utils/weeklyMenuHelpers.ts"
click node_menu_limits "https://github.com/thureinlynn/burmeal/blob/main/src/utils/menuLimitHelpers.ts"
click node_admin "https://github.com/thureinlynn/burmeal/blob/main/src/components/AdminPanel.tsx"
click node_customer_profile "https://github.com/thureinlynn/burmeal/blob/main/src/components/CustomerProfile.tsx"
click node_api "https://github.com/thureinlynn/burmeal/blob/main/src/services/apiClient.ts"
click node_backend "https://github.com/thureinlynn/burmeal/blob/main/server.ts"
click node_database "https://github.com/thureinlynn/burmeal/blob/main/src/server/db.ts"
click node_sync "https://github.com/thureinlynn/burmeal/blob/main/src/server/firestoreSync.ts"
click node_firestore_service "https://github.com/thureinlynn/burmeal/blob/main/src/services/firestoreService.ts"
click node_firebase "https://github.com/thureinlynn/burmeal/blob/main/src/firebase.ts"
click node_supabase "https://github.com/thureinlynn/burmeal/blob/main/src/services/supabaseClient.ts"
click node_types "https://github.com/thureinlynn/burmeal/blob/main/src/types/index.ts"
click node_countries "https://github.com/thureinlynn/burmeal/blob/main/src/utils/countries.ts"
click node_shop_locations "https://github.com/thureinlynn/burmeal/blob/main/src/utils/shopLocationHelpers.ts"
click node_badges "https://github.com/thureinlynn/burmeal/blob/main/src/utils/shopServiceBadges.ts"
click node_sharing "https://github.com/thureinlynn/burmeal/blob/main/src/utils/shareHelpers.ts"
click node_language_data "https://github.com/thureinlynn/burmeal/blob/main/src/utils/i18n.ts"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_entry,node_application,node_authentication,node_auth_ui,node_location,node_location_ui,node_language toneBlue
class node_feed,node_filters,node_search,node_specials,node_shop_profile,node_pagination,node_external_services toneAmber
class node_merchant_dashboard,node_menu_rules,node_menu_limits,node_admin,node_customer_profile toneMint
class node_api,node_backend,node_database,node_sync,node_firestore_service,node_firebase,node_supabase toneRose
class node_types,node_countries,node_shop_locations,node_badges,node_sharing,node_language_data,node_customer,node_owner toneIndigo
```

## Components

### App and identity

- [App entry](https://github.com/thureinlynn/burmeal/blob/main/src/main.tsx): `src/main.tsx`
- [Marketplace app](https://github.com/thureinlynn/burmeal/blob/main/src/App.tsx): `src/App.tsx`
- [Authentication](https://github.com/thureinlynn/burmeal/blob/main/src/context/AuthContext.tsx): `src/context/AuthContext.tsx`
- [Sign-in UI](https://github.com/thureinlynn/burmeal/blob/main/src/components/AuthModal.tsx): `src/components/AuthModal.tsx`
- [Location context](https://github.com/thureinlynn/burmeal/blob/main/src/context/LocationContext.tsx): `src/context/LocationContext.tsx`
- [Location selection](https://github.com/thureinlynn/burmeal/blob/main/src/components/LocationModal.tsx): `src/components/LocationModal.tsx`
- [Language context](https://github.com/thureinlynn/burmeal/blob/main/src/context/LanguageContext.tsx): `src/context/LanguageContext.tsx`

### Food discovery

- [Discovery feed](https://github.com/thureinlynn/burmeal/blob/main/src/App.tsx): `src/App.tsx`
- [Menu and region filters](https://github.com/thureinlynn/burmeal/blob/main/src/utils/filter.ts): `src/utils/filter.ts`
- [Smart search](https://github.com/thureinlynn/burmeal/blob/main/src/utils/smartSearch.ts): `src/utils/smartSearch.ts`
- [Daily specials](https://github.com/thureinlynn/burmeal/blob/main/src/utils/dailySpecialHelpers.ts): `src/utils/dailySpecialHelpers.ts`
- [Shop profile](https://github.com/thureinlynn/burmeal/blob/main/src/components/ShopProfileView.tsx): `src/components/ShopProfileView.tsx`
- [Feed pagination](https://github.com/thureinlynn/burmeal/blob/main/src/utils/paginationHelpers.ts): `src/utils/paginationHelpers.ts`

### Merchant tools

- [Shop dashboard](https://github.com/thureinlynn/burmeal/blob/main/src/components/ShopDashboard.tsx): `src/components/ShopDashboard.tsx`
- [Menu availability](https://github.com/thureinlynn/burmeal/blob/main/src/utils/weeklyMenuHelpers.ts): `src/utils/weeklyMenuHelpers.ts`
- [Menu limits](https://github.com/thureinlynn/burmeal/blob/main/src/utils/menuLimitHelpers.ts): `src/utils/menuLimitHelpers.ts`
- [Administration](https://github.com/thureinlynn/burmeal/blob/main/src/components/AdminPanel.tsx): `src/components/AdminPanel.tsx`
- [Customer profile](https://github.com/thureinlynn/burmeal/blob/main/src/components/CustomerProfile.tsx): `src/components/CustomerProfile.tsx`

### Data and services

- [API client](https://github.com/thureinlynn/burmeal/blob/main/src/services/apiClient.ts): `src/services/apiClient.ts`
- [Application server](https://github.com/thureinlynn/burmeal/blob/main/server.ts): `server.ts`
- [Server database](https://github.com/thureinlynn/burmeal/blob/main/src/server/db.ts): `src/server/db.ts`
- [Firestore sync](https://github.com/thureinlynn/burmeal/blob/main/src/server/firestoreSync.ts): `src/server/firestoreSync.ts`
- [Firestore service](https://github.com/thureinlynn/burmeal/blob/main/src/services/firestoreService.ts): `src/services/firestoreService.ts`
- [Firebase setup](https://github.com/thureinlynn/burmeal/blob/main/src/firebase.ts): `src/firebase.ts`
- [Supabase storage](https://github.com/thureinlynn/burmeal/blob/main/src/services/supabaseClient.ts): `src/services/supabaseClient.ts`

### Shared domain

- [Domain types](https://github.com/thureinlynn/burmeal/blob/main/src/types/index.ts): `src/types/index.ts`
- [Countries and currencies](https://github.com/thureinlynn/burmeal/blob/main/src/utils/countries.ts): `src/utils/countries.ts`
- [Shop location helpers](https://github.com/thureinlynn/burmeal/blob/main/src/utils/shopLocationHelpers.ts): `src/utils/shopLocationHelpers.ts`
- [Shop service badges](https://github.com/thureinlynn/burmeal/blob/main/src/utils/shopServiceBadges.ts): `src/utils/shopServiceBadges.ts`
- [Sharing helpers](https://github.com/thureinlynn/burmeal/blob/main/src/utils/shareHelpers.ts): `src/utils/shareHelpers.ts`
- [Translations](https://github.com/thureinlynn/burmeal/blob/main/src/utils/i18n.ts): `src/utils/i18n.ts`

### Other components

- **Customer**
- **Shop owner**
- **Firebase and Supabase**

## Connections

- Customer → App entry: opens (evidence: `src/main.tsx`)
- Shop owner → App entry: opens (evidence: `src/main.tsx`)
- App entry → Marketplace app: renders (evidence: `src/main.tsx`)
- App entry → Authentication: provides context (evidence: `src/main.tsx`)
- App entry → Language context: provides context (evidence: `src/main.tsx`)
- App entry → Location context: provides context (evidence: `src/main.tsx`)
- Marketplace app → Discovery feed: renders (evidence: `src/App.tsx`)
- Marketplace app → Authentication: uses (evidence: `src/App.tsx`)
- Marketplace app → Location context: uses (evidence: `src/App.tsx`)
- Marketplace app → API client: requests data (evidence: `src/App.tsx`)
- Marketplace app → Sign-in UI: renders (evidence: `src/App.tsx`)
- Marketplace app → Location selection: renders (evidence: `src/App.tsx`)
- Marketplace app → Shop dashboard: renders (evidence: `src/App.tsx`)
- Marketplace app → Administration: renders (evidence: `src/App.tsx`)
- Marketplace app → Customer profile: renders (evidence: `src/App.tsx`)
- Discovery feed → Menu and region filters: filters
- Menu and region filters → Smart search: searches (evidence: `src/utils/filter.ts`)
- Discovery feed → Daily specials: uses (evidence: `src/App.tsx`)
- Marketplace app → Shop profile: renders (evidence: `src/App.tsx`)
- Shop profile → Feed pagination: uses (evidence: `src/components/ShopProfileView.tsx`)
- Shop dashboard → Menu availability: uses (evidence: `src/components/ShopDashboard.tsx`)
- Shop dashboard → Menu limits: uses (evidence: `src/components/ShopDashboard.tsx`)
- Authentication → Firebase setup: authenticates with (evidence: `src/context/AuthContext.tsx`)
- Authentication → Firestore service: loads profiles (evidence: `src/context/AuthContext.tsx`)
- Marketplace app → API client: calls (evidence: `src/App.tsx`)
- API client → Application server: requests routes
- Application server → Server database: uses (evidence: `server.ts`)
- Application server → Firestore sync: uses (evidence: `server.ts`)
- Firestore service → Firebase setup: uses (evidence: `src/services/firestoreService.ts`)
- Firestore service → Supabase storage: deletes media (evidence: `src/services/firestoreService.ts`)
- Firebase setup → Firebase and Supabase: connects
- Supabase storage → Firebase and Supabase: stores media
- Marketplace app → Domain types: uses (evidence: `src/App.tsx`)
- Marketplace app → Sharing helpers: uses (evidence: `src/App.tsx`)
- Marketplace app → Shop service badges: uses
- Menu and region filters → Countries and currencies: gets currency (evidence: `src/utils/filter.ts`)
- Location selection → Countries and currencies: uses (evidence: `src/components/LocationModal.tsx`)
- Location context → Countries and currencies: uses (evidence: `src/context/LocationContext.tsx`)
- Language context → Translations: reads translations (evidence: `src/context/LanguageContext.tsx`)
- Shop dashboard → Shop location helpers: uses (evidence: `src/components/ShopDashboard.tsx`)
