# gridsuite/gridexplore-app architecture

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

- Interactive diagram: https://gitdiagram.com/gridsuite/gridexplore-app
- Repository: https://github.com/gridsuite/gridexplore-app

## Overview

GridExplore is a React interface for exploring and managing GridSuite studies, cases, directories, and related network data. Users navigate the directory tree and content, search for elements, and invoke contextual actions to create, import, move, share, or delete items; export flows prepare and download case or study data. The UI also includes contingency-list and network-modification workflows. Redux holds explorer and preference state, while REST helpers communicate with GridSuite services. The graph reflects documented and indexed relationships; unsampled modules are included where they represent major product capabilities, without asserting unverified wiring.

Main entry points: [`src/utils/rest-api.ts`](https://github.com/gridsuite/gridexplore-app/blob/main/src/utils/rest-api.ts) (REST operations), [`src/components/app.tsx`](https://github.com/gridsuite/gridexplore-app/blob/main/src/components/app.tsx) (App shell), [`src/components/menus/directory-tree-contextual-menu.tsx`](https://github.com/gridsuite/gridexplore-app/blob/main/src/components/menus/directory-tree-contextual-menu.tsx) (Directory actions), [`src/components/menus/content-contextual-menu.tsx`](https://github.com/gridsuite/gridexplore-app/blob/main/src/components/menus/content-contextual-menu.tsx) (Content actions)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_app["Application shell"]
  node_app["App shell<br/>[app.tsx]"]
  node_explorer["Explorer layout"]
end

subgraph group_explore["Explore and navigate"]
  node_tree["Directory tree"]
  node_content["Directory content"]
  node_search["Element search<br/>[search-bar.tsx]"]
  node_treeutils["Tree navigation<br/>[treeview-utils.tsx]"]
end

subgraph group_operations["Manage elements"]
  node_treeactions["Directory actions"]
  node_contentactions["Content actions"]
  node_study["Study creation"]
  node_case["Case workflows"]
  node_contingency["Contingency lists"]
  node_modification["Network modification"]
  node_export["Export and download<br/>[downloadUtils.ts]"]
end

subgraph group_services["State and services"]
  node_api["REST operations<br/>[rest-api.ts]"]
  node_state["Explorer state<br/>[reducer.ts]"]
  node_actions["State actions<br/>[actions.ts]"]
  node_store["Redux store<br/>[store.ts]"]
  node_preferences["Saved preferences<br/>[local-storage.ts]"]
end

node_user(("User"))
node_backend{{"GridSuite services"}}

node_user -->|"uses"| node_app
node_app -->|"renders"| node_explorer
node_app -->|"loads configuration"| node_api
node_app -->|"dispatches state"| node_store
node_explorer -.->|"presents navigation"| node_tree
node_explorer -.->|"presents items"| node_content
node_tree -.->|"uses"| node_treeutils
node_tree -.->|"offers actions"| node_treeactions
node_content -.->|"offers actions"| node_contentactions
node_content -.->|"offers search"| node_search
node_search -->|"searches elements"| node_api
node_treeactions -->|"opens"| node_study
node_treeactions -->|"opens"| node_case
node_treeactions -->|"requests operations"| node_api
node_contentactions -->|"opens"| node_study
node_contentactions -->|"exports study"| node_api
node_contentactions -->|"downloads export"| node_export
node_study -->|"loads case parameters"| node_api
node_study -->|"updates state"| node_actions
node_api -->|"sends requests"| node_backend
node_store -->|"uses reducer"| node_state
node_state -->|"reads and saves"| node_preferences
node_actions -->|"updates"| node_state
node_export -->|"fetches export data"| node_api

click node_app "https://github.com/gridsuite/gridexplore-app/blob/main/src/components/app.tsx"
click node_explorer "https://github.com/gridsuite/gridexplore-app/blob/main/src/components/explorer-layout.tsx"
click node_tree "https://github.com/gridsuite/gridexplore-app/blob/main/src/components/tree-views-container.tsx"
click node_content "https://github.com/gridsuite/gridexplore-app/blob/main/src/components/directory-content.tsx"
click node_search "https://github.com/gridsuite/gridexplore-app/blob/main/src/components/search/search-bar.tsx"
click node_treeutils "https://github.com/gridsuite/gridexplore-app/blob/main/src/components/treeview-utils.tsx"
click node_treeactions "https://github.com/gridsuite/gridexplore-app/blob/main/src/components/menus/directory-tree-contextual-menu.tsx"
click node_contentactions "https://github.com/gridsuite/gridexplore-app/blob/main/src/components/menus/content-contextual-menu.tsx"
click node_study "https://github.com/gridsuite/gridexplore-app/blob/main/src/components/dialogs/create-study-dialog/create-study-dialog.tsx"
click node_case "https://github.com/gridsuite/gridexplore-app/blob/main/src/components/dialogs/create-case-dialog/create-case-dialog.tsx"
click node_contingency "https://github.com/gridsuite/gridexplore-app/tree/main/src/components/dialogs/contingency-list"
click node_modification "https://github.com/gridsuite/gridexplore-app/tree/main/src/components/dialogs/network-modification"
click node_export "https://github.com/gridsuite/gridexplore-app/blob/main/src/components/utils/downloadUtils.ts"
click node_api "https://github.com/gridsuite/gridexplore-app/blob/main/src/utils/rest-api.ts"
click node_state "https://github.com/gridsuite/gridexplore-app/blob/main/src/redux/reducer.ts"
click node_actions "https://github.com/gridsuite/gridexplore-app/blob/main/src/redux/actions.ts"
click node_store "https://github.com/gridsuite/gridexplore-app/blob/main/src/redux/store.ts"
click node_preferences "https://github.com/gridsuite/gridexplore-app/blob/main/src/redux/local-storage.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_app,node_explorer,node_user toneBlue
class node_tree,node_content,node_search,node_treeutils toneAmber
class node_treeactions,node_contentactions,node_study,node_case,node_contingency,node_modification,node_export toneMint
class node_api,node_state,node_actions,node_store,node_preferences toneRose
class node_backend toneIndigo
```

## Components

### Application shell

- [App shell](https://github.com/gridsuite/gridexplore-app/blob/main/src/components/app.tsx): `src/components/app.tsx`
- [Explorer layout](https://github.com/gridsuite/gridexplore-app/blob/main/src/components/explorer-layout.tsx): `src/components/explorer-layout.tsx`

### Explore and navigate

- [Directory tree](https://github.com/gridsuite/gridexplore-app/blob/main/src/components/tree-views-container.tsx): `src/components/tree-views-container.tsx`
- [Directory content](https://github.com/gridsuite/gridexplore-app/blob/main/src/components/directory-content.tsx): `src/components/directory-content.tsx`
- [Element search](https://github.com/gridsuite/gridexplore-app/blob/main/src/components/search/search-bar.tsx): `src/components/search/search-bar.tsx`
- [Tree navigation](https://github.com/gridsuite/gridexplore-app/blob/main/src/components/treeview-utils.tsx): `src/components/treeview-utils.tsx`

### Manage elements

- [Directory actions](https://github.com/gridsuite/gridexplore-app/blob/main/src/components/menus/directory-tree-contextual-menu.tsx): `src/components/menus/directory-tree-contextual-menu.tsx`
- [Content actions](https://github.com/gridsuite/gridexplore-app/blob/main/src/components/menus/content-contextual-menu.tsx): `src/components/menus/content-contextual-menu.tsx`
- [Study creation](https://github.com/gridsuite/gridexplore-app/blob/main/src/components/dialogs/create-study-dialog/create-study-dialog.tsx): `src/components/dialogs/create-study-dialog/create-study-dialog.tsx`
- [Case workflows](https://github.com/gridsuite/gridexplore-app/blob/main/src/components/dialogs/create-case-dialog/create-case-dialog.tsx): `src/components/dialogs/create-case-dialog/create-case-dialog.tsx`
- [Contingency lists](https://github.com/gridsuite/gridexplore-app/tree/main/src/components/dialogs/contingency-list): `src/components/dialogs/contingency-list`
- [Network modification](https://github.com/gridsuite/gridexplore-app/tree/main/src/components/dialogs/network-modification): `src/components/dialogs/network-modification`
- [Export and download](https://github.com/gridsuite/gridexplore-app/blob/main/src/components/utils/downloadUtils.ts): `src/components/utils/downloadUtils.ts`

### State and services

- [REST operations](https://github.com/gridsuite/gridexplore-app/blob/main/src/utils/rest-api.ts): `src/utils/rest-api.ts`
- [Explorer state](https://github.com/gridsuite/gridexplore-app/blob/main/src/redux/reducer.ts): `src/redux/reducer.ts`
- [State actions](https://github.com/gridsuite/gridexplore-app/blob/main/src/redux/actions.ts): `src/redux/actions.ts`
- [Redux store](https://github.com/gridsuite/gridexplore-app/blob/main/src/redux/store.ts): `src/redux/store.ts`
- [Saved preferences](https://github.com/gridsuite/gridexplore-app/blob/main/src/redux/local-storage.ts): `src/redux/local-storage.ts`

### Other components

- **User**
- **GridSuite services**

## Connections

- User → App shell: uses
- App shell → Explorer layout: renders (evidence: `src/components/app.tsx`)
- App shell → REST operations: loads configuration (evidence: `src/components/app.tsx`)
- App shell → Redux store: dispatches state (evidence: `src/components/app.tsx`)
- Explorer layout → Directory tree: presents navigation
- Explorer layout → Directory content: presents items
- Directory tree → Tree navigation: uses
- Directory tree → Directory actions: offers actions
- Directory content → Content actions: offers actions
- Directory content → Element search: offers search
- Element search → REST operations: searches elements (evidence: `src/components/search/search-bar.tsx`)
- Directory actions → Study creation: opens (evidence: `src/components/menus/directory-tree-contextual-menu.tsx`)
- Directory actions → Case workflows: opens (evidence: `src/components/menus/directory-tree-contextual-menu.tsx`)
- Directory actions → REST operations: requests operations (evidence: `src/components/menus/directory-tree-contextual-menu.tsx`)
- Content actions → Study creation: opens (evidence: `src/components/menus/content-contextual-menu.tsx`)
- Content actions → REST operations: exports study (evidence: `src/components/menus/content-contextual-menu.tsx`)
- Content actions → Export and download: downloads export (evidence: `src/components/menus/content-contextual-menu.tsx`)
- Study creation → REST operations: loads case parameters (evidence: `src/components/dialogs/create-study-dialog/create-study-dialog.tsx`)
- Study creation → State actions: updates state (evidence: `src/components/dialogs/create-study-dialog/create-study-dialog.tsx`)
- REST operations → GridSuite services: sends requests (evidence: `src/utils/rest-api.ts`)
- Redux store → Explorer state: uses reducer (evidence: `src/redux/store.ts`)
- Explorer state → Saved preferences: reads and saves (evidence: `src/redux/reducer.ts`)
- State actions → Explorer state: updates (evidence: `src/redux/reducer.ts`)
- Export and download → REST operations: fetches export data (evidence: `src/components/utils/downloadUtils.ts`)
