# ergrzaccar/ergr-zaccar architecture

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

- Interactive diagram: https://gitdiagram.com/ergrzaccar/ergr-zaccar
- Repository: https://github.com/ergrzaccar/ergr-zaccar

## Overview

This is a French/Arabic public-information website for a forestry and land-management organization, rather than the minimal starter described in the README. Visitors enter through routed pages to explore organizational information, activities, nurseries, projects, resources, news, tenders, careers and contact details. Search spans those domains; the careers flow also supports job and internship applications and alert subscriptions. The graph reflects documented routing and sampled imports; unsampled page internals and any server-backed integrations are not inferred.

Main entry points: [`src/data/searchIndex.ts`](https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/data/searchIndex.ts) (Search index), [`src/pages/CareersPage.tsx`](https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/pages/CareersPage.tsx) (Careers page), [`src/app/router.tsx`](https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/app/router.tsx) (Page router), [`src/pages`](https://github.com/ergrzaccar/ergr-zaccar/tree/master/src/pages) (Information pages)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_app["Application shell"]
  node_providers["App providers<br/>[AppProviders.tsx]"]
  node_router["Page router<br/>[router.tsx]"]
  node_routes["Route metadata<br/>[routes.ts]"]
  node_root["Site shell<br/>[RootLayout.tsx]"]
  node_i18n["Translations"]
end

subgraph group_content["Public information"]
  node_pages["Information pages"]
  node_home["Home content<br/>[home.ts]"]
  node_organization["Organization content<br/>[organization.ts]"]
  node_map["Territory map<br/>[TerritoryMap.tsx]"]
  node_nurseries["Nursery directory<br/>[nurseries.ts]"]
  node_projects["Projects content<br/>[projectsPage.ts]"]
end

subgraph group_engagement["Visitor engagement"]
  node_search["Search palette"]
  node_searchstate["Search state<br/>[SearchProvider.tsx]"]
  node_searchdata["Search index<br/>[searchIndex.ts]"]
  node_lightbox["Image lightbox"]
  node_toast["Toast notifications<br/>[ToastContext.tsx]"]
end

subgraph group_careers["Careers"]
  node_careerspage["Careers page<br/>[CareersPage.tsx]"]
  node_careerdata["Career listings<br/>[careersPage.ts]"]
  node_jobs["Job listings"]
  node_application["Application form"]
  node_alerts["Alert subscription"]
end

node_visitor(("Visitor"))

node_visitor -->|"opens site"| node_router
node_providers -->|"wraps routes"| node_router
node_router -->|"renders shell"| node_root
node_router -->|"routes pages"| node_pages
node_routes -->|"supplies route entries"| node_searchdata
node_root -->|"renders palette"| node_search
node_pages -.->|"presents home information"| node_home
node_pages -.->|"presents organization information"| node_organization
node_map -->|"reads content"| node_home
node_map -->|"reads content"| node_organization
node_map -->|"reads locations"| node_nurseries
node_search -->|"filters items"| node_searchdata
node_search -->|"uses search context"| node_searchstate
node_searchstate -->|"loads index"| node_searchdata
node_searchdata -->|"indexes entries"| node_nurseries
node_searchdata -->|"indexes entries"| node_projects
node_searchdata -->|"indexes offers"| node_careerdata
node_searchdata -->|"indexes page routes"| node_pages
node_providers -->|"provides context"| node_lightbox
node_providers -->|"provides context"| node_toast
node_router -->|"routes careers"| node_careerspage
node_careerspage -->|"renders listings"| node_jobs
node_careerspage -->|"renders application"| node_application
node_careerspage -->|"renders subscription"| node_alerts
node_jobs -->|"reads offers"| node_careerdata
node_application -->|"uses career data"| node_careerdata
node_application -->|"shows notifications"| node_toast
node_alerts -->|"shows notifications"| node_toast
node_careerspage -.->|"uses translations"| node_i18n

click node_providers "https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/app/providers/AppProviders.tsx"
click node_router "https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/app/router.tsx"
click node_routes "https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/app/routes.ts"
click node_root "https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/layouts/RootLayout.tsx"
click node_i18n "https://github.com/ergrzaccar/ergr-zaccar/tree/master/src/data/i18n"
click node_pages "https://github.com/ergrzaccar/ergr-zaccar/tree/master/src/pages"
click node_home "https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/data/home.ts"
click node_organization "https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/data/organization.ts"
click node_map "https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/components/home/TerritoryMap.tsx"
click node_nurseries "https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/data/nurseries.ts"
click node_projects "https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/data/projectsPage.ts"
click node_search "https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/components/search/SearchPaletteModal.tsx"
click node_searchstate "https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/context/SearchProvider.tsx"
click node_searchdata "https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/data/searchIndex.ts"
click node_lightbox "https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/context/LightboxContext.tsx"
click node_toast "https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/context/ToastContext.tsx"
click node_careerspage "https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/pages/CareersPage.tsx"
click node_careerdata "https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/data/careersPage.ts"
click node_jobs "https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/components/careers/CareersJobsSection.tsx"
click node_application "https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/components/careers/CareersApplicationSection.tsx"
click node_alerts "https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/components/alerts/AlertSubscriptionCard.tsx"

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_providers,node_router,node_routes,node_root,node_i18n toneBlue
class node_pages,node_home,node_organization,node_map,node_nurseries,node_projects toneAmber
class node_search,node_searchstate,node_searchdata,node_lightbox,node_toast toneMint
class node_careerspage,node_careerdata,node_jobs,node_application,node_alerts toneRose
class node_visitor toneIndigo
```

## Components

### Application shell

- [App providers](https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/app/providers/AppProviders.tsx): `src/app/providers/AppProviders.tsx`
- [Page router](https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/app/router.tsx): `src/app/router.tsx`
- [Route metadata](https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/app/routes.ts): `src/app/routes.ts`
- [Site shell](https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/layouts/RootLayout.tsx): `src/layouts/RootLayout.tsx`
- [Translations](https://github.com/ergrzaccar/ergr-zaccar/tree/master/src/data/i18n): `src/data/i18n`

### Public information

- [Information pages](https://github.com/ergrzaccar/ergr-zaccar/tree/master/src/pages): `src/pages`
- [Home content](https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/data/home.ts): `src/data/home.ts`
- [Organization content](https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/data/organization.ts): `src/data/organization.ts`
- [Territory map](https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/components/home/TerritoryMap.tsx): `src/components/home/TerritoryMap.tsx`
- [Nursery directory](https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/data/nurseries.ts): `src/data/nurseries.ts`
- [Projects content](https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/data/projectsPage.ts): `src/data/projectsPage.ts`

### Visitor engagement

- [Search palette](https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/components/search/SearchPaletteModal.tsx): `src/components/search/SearchPaletteModal.tsx`
- [Search state](https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/context/SearchProvider.tsx): `src/context/SearchProvider.tsx`
- [Search index](https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/data/searchIndex.ts): `src/data/searchIndex.ts`
- [Image lightbox](https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/context/LightboxContext.tsx): `src/context/LightboxContext.tsx`
- [Toast notifications](https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/context/ToastContext.tsx): `src/context/ToastContext.tsx`

### Careers

- [Careers page](https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/pages/CareersPage.tsx): `src/pages/CareersPage.tsx`
- [Career listings](https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/data/careersPage.ts): `src/data/careersPage.ts`
- [Job listings](https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/components/careers/CareersJobsSection.tsx): `src/components/careers/CareersJobsSection.tsx`
- [Application form](https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/components/careers/CareersApplicationSection.tsx): `src/components/careers/CareersApplicationSection.tsx`
- [Alert subscription](https://github.com/ergrzaccar/ergr-zaccar/blob/master/src/components/alerts/AlertSubscriptionCard.tsx): `src/components/alerts/AlertSubscriptionCard.tsx`

### Other components

- **Visitor**

## Connections

- Visitor → Page router: opens site (evidence: `src/app/router.tsx`)
- App providers → Page router: wraps routes (evidence: `src/App.tsx`)
- Page router → Site shell: renders shell (evidence: `src/app/router.tsx`)
- Page router → Information pages: routes pages (evidence: `src/app/router.tsx`)
- Route metadata → Search index: supplies route entries (evidence: `src/data/searchIndex.ts`)
- Site shell → Search palette: renders palette (evidence: `src/layouts/RootLayout.tsx`)
- Information pages → Home content: presents home information
- Information pages → Organization content: presents organization information
- Territory map → Home content: reads content (evidence: `src/components/home/TerritoryMap.tsx`)
- Territory map → Organization content: reads content (evidence: `src/components/home/TerritoryMap.tsx`)
- Territory map → Nursery directory: reads locations (evidence: `src/components/home/TerritoryMap.tsx`)
- Search palette → Search index: filters items (evidence: `src/components/search/SearchPaletteModal.tsx`)
- Search palette → Search state: uses search context (evidence: `src/components/search/SearchPaletteModal.tsx`)
- Search state → Search index: loads index (evidence: `src/context/SearchProvider.tsx`)
- Search index → Nursery directory: indexes entries (evidence: `src/data/searchIndex.ts`)
- Search index → Projects content: indexes entries (evidence: `src/data/searchIndex.ts`)
- Search index → Career listings: indexes offers (evidence: `src/data/searchIndex.ts`)
- Search index → Information pages: indexes page routes (evidence: `src/data/searchIndex.ts`)
- App providers → Image lightbox: provides context (evidence: `src/app/providers/AppProviders.tsx`)
- App providers → Toast notifications: provides context (evidence: `src/app/providers/AppProviders.tsx`)
- Page router → Careers page: routes careers (evidence: `src/app/router.tsx`)
- Careers page → Job listings: renders listings (evidence: `src/pages/CareersPage.tsx`)
- Careers page → Application form: renders application (evidence: `src/pages/CareersPage.tsx`)
- Careers page → Alert subscription: renders subscription (evidence: `src/pages/CareersPage.tsx`)
- Job listings → Career listings: reads offers (evidence: `src/components/careers/CareersJobsSection.tsx`)
- Application form → Career listings: uses career data (evidence: `src/components/careers/CareersApplicationSection.tsx`)
- Application form → Toast notifications: shows notifications (evidence: `src/components/careers/CareersApplicationSection.tsx`)
- Alert subscription → Toast notifications: shows notifications (evidence: `src/components/alerts/AlertSubscriptionCard.tsx`)
- Careers page → Translations: uses translations
