# mallanaidu13-create/sacred-temples-india architecture

> Architecture diagram of the GitHub repository mallanaidu13-create/sacred-temples-india, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-26). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/mallanaidu13-create/sacred-temples-india
- Repository: https://github.com/mallanaidu13-create/sacred-temples-india

## Overview

Sacred Temples India is a temple-discovery and pilgrimage companion. The main journey starts at the home screen, where visitors browse curated temples or find nearby sites, then open a temple detail; search, regional browsing, and sacred circuits provide alternate discovery routes. The app loads temple records from Supabase with cached and static fallbacks. Additional branches support live Panchangam, location-aware maps, spiritual guidance, and immersive features. Edges reflect the sampled App, Nearby, Home, Search, and Sankalpa code; several other capabilities are represented from the file tree, with their wiring left unspecified where source was not sampled.

Main entry points: [`src/App.jsx`](https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/App.jsx) (App shell), [`src/pages/NearbyPage.jsx`](https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/pages/NearbyPage.jsx) (Nearby temples), [`src/data.js`](https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/data.js) (Temple data), [`src/pages/HomePage.jsx`](https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/pages/HomePage.jsx) (Home)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_app["App and discovery"]
  node_app["App shell<br/>[App.jsx]"]
  node_home["Home<br/>[HomePage.jsx]"]
  node_discover["Discover<br/>[DiscoverPage.jsx]"]
  node_explore["Explore<br/>[ExplorePage.jsx]"]
  node_search["Temple search<br/>[SearchPage.jsx]"]
  node_browse["Regional browse<br/>[BrowsePages.jsx]"]
end

subgraph group_temples["Temple information"]
  node_detail["Temple detail<br/>[DetailPage.jsx]"]
  node_templedata["Temple data<br/>[data.js]"]
  node_supabase[("Supabase<br/>[supabase.js]")]
  node_fallback["Static fallback"]
end

subgraph group_pilgrimage["Location and pilgrimage"]
  node_circuits["Sacred circuits<br/>[CircuitsPages.jsx]"]
  node_circuitdata["Circuit definitions<br/>[circuits.js]"]
  node_nearby["Nearby temples<br/>[NearbyPage.jsx]"]
  node_geolocation["Geolocation and compass<br/>[useGeo.js]"]
  node_mappls["Mappls services<br/>[mappls-api.js]"]
  node_osm["OpenStreetMap lookup<br/>[osm-temples.js]"]
  node_overpass["Overpass API<br/>[overpass-api.js]"]
end

subgraph group_spiritual["Spiritual tools"]
  node_panchang["Live Panchangam<br/>[LivePanchangam.jsx]"]
  node_language["Panchang languages"]
  node_chat["Sarathi guide<br/>[SarathiChat.jsx]"]
  node_gemini{{"Gemini API"}}
  node_sankalpa["Sankalpa practice<br/>[SankalpaEngine.jsx]"]
  node_sankalpalogic["Sankalpa logic<br/>[sankalpa-logic.js]"]
end

subgraph group_immersive["Immersive experiences"]
  node_sound["Sacred soundscape"]
  node_ar["Mandala AR<br/>[MandalaAR.jsx]"]
  node_vision["Sarathi vision<br/>[SarathiVision.jsx]"]
  node_stamps["Tirtha stamps<br/>[TirthaStamps.jsx]"]
end

node_visitor(("Visitor"))

node_visitor -->|"opens"| node_app
node_app -->|"renders"| node_home
node_app -->|"routes to"| node_discover
node_app -->|"routes to"| node_explore
node_app -->|"routes to"| node_search
node_app -->|"routes to"| node_browse
node_app -->|"opens selected"| node_detail
node_app -->|"routes to"| node_nearby
node_app -->|"routes to"| node_circuits
node_app -->|"computes"| node_panchang
node_app -->|"renders"| node_chat
node_app -->|"renders"| node_sankalpa
node_app -->|"fetches temples"| node_supabase
node_app -->|"uses on failure"| node_fallback
node_supabase -->|"returns records"| node_templedata
node_home -->|"displays"| node_templedata
node_home -->|"shows nearby"| node_nearby
node_search -->|"filters records"| node_templedata
node_circuits -->|"reads"| node_circuitdata
node_nearby -->|"gets location"| node_geolocation
node_nearby -->|"fetches nearby and routes"| node_mappls
node_nearby -->|"discovers temples"| node_osm
node_osm -->|"queries"| node_overpass
node_nearby -->|"compares locations"| node_templedata
node_app -->|"provides context"| node_language
node_panchang -->|"uses translations"| node_language
node_chat -.->|"requests guidance"| node_gemini
node_sankalpa -->|"generates locally"| node_sankalpalogic
node_sankalpa -.->|"requests generation"| node_gemini
node_app -->|"starts soundscape"| node_sound

click node_app "https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/App.jsx"
click node_home "https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/pages/HomePage.jsx"
click node_discover "https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/pages/DiscoverPage.jsx"
click node_explore "https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/pages/ExplorePage.jsx"
click node_search "https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/pages/SearchPage.jsx"
click node_browse "https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/pages/BrowsePages.jsx"
click node_detail "https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/pages/DetailPage.jsx"
click node_templedata "https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/data.js"
click node_supabase "https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/supabase.js"
click node_fallback "https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/fallback-temples.js"
click node_circuits "https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/pages/CircuitsPages.jsx"
click node_circuitdata "https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/content/sacred-circuits/circuits.js"
click node_nearby "https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/pages/NearbyPage.jsx"
click node_geolocation "https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/useGeo.js"
click node_mappls "https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/mappls-api.js"
click node_osm "https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/osm-temples.js"
click node_overpass "https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/overpass-api.js"
click node_panchang "https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/LivePanchangam.jsx"
click node_language "https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/PanchangLangContext.jsx"
click node_chat "https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/SarathiChat.jsx"
click node_sankalpa "https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/SankalpaEngine.jsx"
click node_sankalpalogic "https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/sankalpa-logic.js"
click node_sound "https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/SacredSoundscape.js"
click node_ar "https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/MandalaAR.jsx"
click node_vision "https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/SarathiVision.jsx"
click node_stamps "https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/TirthaStamps.jsx"

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_app,node_home,node_discover,node_explore,node_search,node_browse toneBlue
class node_detail,node_templedata,node_supabase,node_fallback toneAmber
class node_circuits,node_circuitdata,node_nearby,node_geolocation,node_mappls,node_osm,node_overpass toneMint
class node_panchang,node_language,node_chat,node_gemini,node_sankalpa,node_sankalpalogic toneRose
class node_sound,node_ar,node_vision,node_stamps,node_visitor toneIndigo
```

## Components

### App and discovery

- [App shell](https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/App.jsx): `src/App.jsx`
- [Home](https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/pages/HomePage.jsx): `src/pages/HomePage.jsx`
- [Discover](https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/pages/DiscoverPage.jsx): `src/pages/DiscoverPage.jsx`
- [Explore](https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/pages/ExplorePage.jsx): `src/pages/ExplorePage.jsx`
- [Temple search](https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/pages/SearchPage.jsx): `src/pages/SearchPage.jsx`
- [Regional browse](https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/pages/BrowsePages.jsx): `src/pages/BrowsePages.jsx`

### Temple information

- [Temple detail](https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/pages/DetailPage.jsx): `src/pages/DetailPage.jsx`
- [Temple data](https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/data.js): `src/data.js`
- [Supabase](https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/supabase.js): `src/supabase.js`
- [Static fallback](https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/fallback-temples.js): `src/fallback-temples.js`

### Location and pilgrimage

- [Sacred circuits](https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/pages/CircuitsPages.jsx): `src/pages/CircuitsPages.jsx`
- [Circuit definitions](https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/content/sacred-circuits/circuits.js): `src/content/sacred-circuits/circuits.js`
- [Nearby temples](https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/pages/NearbyPage.jsx): `src/pages/NearbyPage.jsx`
- [Geolocation and compass](https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/useGeo.js): `src/useGeo.js`
- [Mappls services](https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/mappls-api.js): `src/mappls-api.js`
- [OpenStreetMap lookup](https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/osm-temples.js): `src/osm-temples.js`
- [Overpass API](https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/overpass-api.js): `src/overpass-api.js`

### Spiritual tools

- [Live Panchangam](https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/LivePanchangam.jsx): `src/LivePanchangam.jsx`
- [Panchang languages](https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/PanchangLangContext.jsx): `src/PanchangLangContext.jsx`
- [Sarathi guide](https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/SarathiChat.jsx): `src/SarathiChat.jsx`
- **Gemini API**
- [Sankalpa practice](https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/SankalpaEngine.jsx): `src/SankalpaEngine.jsx`
- [Sankalpa logic](https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/sankalpa-logic.js): `src/sankalpa-logic.js`

### Immersive experiences

- [Sacred soundscape](https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/SacredSoundscape.js): `src/SacredSoundscape.js`
- [Mandala AR](https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/MandalaAR.jsx): `src/MandalaAR.jsx`
- [Sarathi vision](https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/SarathiVision.jsx): `src/SarathiVision.jsx`
- [Tirtha stamps](https://github.com/mallanaidu13-create/sacred-temples-india/blob/main/src/TirthaStamps.jsx): `src/TirthaStamps.jsx`

### Other components

- **Visitor**

## Connections

- Visitor → App shell: opens
- App shell → Home: renders
- App shell → Discover: routes to
- App shell → Explore: routes to
- App shell → Temple search: routes to
- App shell → Regional browse: routes to
- App shell → Temple detail: opens selected
- App shell → Nearby temples: routes to
- App shell → Sacred circuits: routes to
- App shell → Live Panchangam: computes
- App shell → Sarathi guide: renders
- App shell → Sankalpa practice: renders
- App shell → Supabase: fetches temples
- App shell → Static fallback: uses on failure
- Supabase → Temple data: returns records
- Home → Temple data: displays
- Home → Nearby temples: shows nearby
- Temple search → Temple data: filters records
- Sacred circuits → Circuit definitions: reads
- Nearby temples → Geolocation and compass: gets location
- Nearby temples → Mappls services: fetches nearby and routes
- Nearby temples → OpenStreetMap lookup: discovers temples
- OpenStreetMap lookup → Overpass API: queries
- Nearby temples → Temple data: compares locations
- App shell → Panchang languages: provides context
- Live Panchangam → Panchang languages: uses translations
- Sarathi guide → Gemini API: requests guidance
- Sankalpa practice → Sankalpa logic: generates locally
- Sankalpa practice → Gemini API: requests generation
- App shell → Sacred soundscape: starts soundscape
