# gmphto/feedback architecture

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

- Interactive diagram: https://gitdiagram.com/gmphto/feedback
- Repository: https://github.com/gmphto/feedback

## Overview

Lumera is a full-stack workspace for developers to define project scope and track projects. The main flow is sign-in, opening the project dashboard, creating or editing a project definition, and saving it through authenticated APIs to PostgreSQL; the editor also presents planning context and project sections. The README describes the product purpose, while excerpts substantiate key server calls and routing. Several client views and the project API are indexed but not sampled, so their internal interactions are omitted where unverified.

Main entry points: [`server/src/projects/routes.ts`](https://github.com/gmphto/feedback/blob/master/server/src/projects/routes.ts) (Project routes), [`client/src/features/auth/state/AuthProvider.tsx`](https://github.com/gmphto/feedback/blob/master/client/src/features/auth/state/AuthProvider.tsx) (Auth state and actions), [`server/src/projects/module.ts`](https://github.com/gmphto/feedback/blob/master/server/src/projects/module.ts) (Project operations), [`server/src/auth/routes.ts`](https://github.com/gmphto/feedback/blob/master/server/src/auth/routes.ts) (Auth routes)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_experience["Client experience"]
  node_client_app["App entry<br/>[main.tsx]"]
  node_app_routing["Protected routing<br/>[AppRoutes.tsx]"]
end

subgraph group_identity["Authentication"]
  node_auth_ui["Auth state and actions<br/>[AuthProvider.tsx]"]
  node_auth_client["Session API client<br/>[auth.ts]"]
  node_auth_routes["Auth routes<br/>[routes.ts]"]
  node_auth_service["Login service<br/>[service.ts]"]
  node_oidc_provider["OIDC adapter<br/>[oidc.ts]"]
  node_auth_repository["Session repository<br/>[repository.ts]"]
end

subgraph group_project["Project planning"]
  node_projects_index["Project entry<br/>[ProjectIndex.tsx]"]
  node_dashboard["Project dashboard<br/>[Dashboard.tsx]"]
  node_project_editor["Project editor<br/>[Editor.tsx]"]
  node_editor_context["Planning context pane<br/>[ContextPane.tsx]"]
  node_project_client_api["Project API client<br/>[api.ts]"]
end

subgraph group_backend["Backend services"]
  node_http_api["HTTP API<br/>[app.ts]"]
  node_project_routes["Project routes<br/>[routes.ts]"]
  node_project_policy["Project policy<br/>[policy.ts]"]
  node_project_creation["Definition validation<br/>[creation.ts]"]
  node_project_module["Project operations<br/>[module.ts]"]
end

subgraph group_persistence["Persistence"]
  node_database[("PostgreSQL access<br/>[database.ts]")]
end

node_developer(("Developer"))
node_postgres[("PostgreSQL")]
node_oidc_service["OIDC identity provider"]

node_developer -->|"uses"| node_client_app
node_client_app -->|"renders"| node_app_routing
node_app_routing -->|"routes to"| node_projects_index
node_projects_index -->|"renders"| node_dashboard
node_projects_index -->|"renders"| node_project_editor
node_client_app -->|"provides"| node_auth_ui
node_auth_ui -->|"queries session"| node_auth_client
node_auth_ui -->|"starts or ends session"| node_auth_client
node_auth_ui -->|"gates routes"| node_app_routing
node_project_editor -->|"renders"| node_editor_context
node_project_editor -.->|"saves project"| node_project_client_api
node_dashboard -.->|"loads projects"| node_project_client_api
node_auth_client -.->|"requests session"| node_http_api
node_project_client_api -.->|"requests projects"| node_http_api
node_http_api -->|"registers"| node_auth_routes
node_http_api -->|"registers"| node_project_routes
node_auth_routes -->|"starts and completes login"| node_auth_service
node_auth_service -->|"verifies identity"| node_oidc_provider
node_auth_service -->|"stores login and session"| node_auth_repository
node_oidc_provider -.->|"uses provider"| node_oidc_service
node_auth_routes -->|"checks or revokes session"| node_auth_repository
node_project_routes -->|"requires session"| node_auth_routes
node_project_routes -->|"validates request"| node_project_policy
node_project_routes -->|"validates definition"| node_project_creation
node_project_routes -->|"dispatches operations"| node_project_module
node_project_module -->|"validates names"| node_project_policy
node_project_module -->|"validates input"| node_project_creation
node_project_module -->|"reads and writes"| node_database
node_auth_repository -->|"reads and writes"| node_database
node_database -->|"queries"| node_postgres

click node_client_app "https://github.com/gmphto/feedback/blob/master/client/src/main.tsx"
click node_app_routing "https://github.com/gmphto/feedback/blob/master/client/src/app/AppRoutes.tsx"
click node_auth_ui "https://github.com/gmphto/feedback/blob/master/client/src/features/auth/state/AuthProvider.tsx"
click node_auth_client "https://github.com/gmphto/feedback/blob/master/client/src/features/auth/api/auth.ts"
click node_projects_index "https://github.com/gmphto/feedback/blob/master/client/src/features/projects/ProjectIndex.tsx"
click node_dashboard "https://github.com/gmphto/feedback/blob/master/client/src/features/projects/dashboard/Dashboard.tsx"
click node_project_editor "https://github.com/gmphto/feedback/blob/master/client/src/features/projects/editor/Editor.tsx"
click node_editor_context "https://github.com/gmphto/feedback/blob/master/client/src/features/projects/editor/components/ContextPane/ContextPane.tsx"
click node_project_client_api "https://github.com/gmphto/feedback/blob/master/client/src/features/projects/api/api.ts"
click node_http_api "https://github.com/gmphto/feedback/blob/master/server/src/app.ts"
click node_auth_routes "https://github.com/gmphto/feedback/blob/master/server/src/auth/routes.ts"
click node_auth_service "https://github.com/gmphto/feedback/blob/master/server/src/auth/service.ts"
click node_oidc_provider "https://github.com/gmphto/feedback/blob/master/server/src/auth/oidc.ts"
click node_auth_repository "https://github.com/gmphto/feedback/blob/master/server/src/auth/repository.ts"
click node_project_routes "https://github.com/gmphto/feedback/blob/master/server/src/projects/routes.ts"
click node_project_policy "https://github.com/gmphto/feedback/blob/master/server/src/projects/policy.ts"
click node_project_creation "https://github.com/gmphto/feedback/blob/master/server/src/projects/creation.ts"
click node_project_module "https://github.com/gmphto/feedback/blob/master/server/src/projects/module.ts"
click node_database "https://github.com/gmphto/feedback/blob/master/server/src/db/database.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_client_app,node_app_routing toneBlue
class node_auth_ui,node_auth_client,node_auth_routes,node_auth_service,node_oidc_provider,node_auth_repository,node_postgres toneAmber
class node_projects_index,node_dashboard,node_project_editor,node_editor_context,node_project_client_api toneMint
class node_http_api,node_project_routes,node_project_policy,node_project_creation,node_project_module toneRose
class node_database,node_developer,node_oidc_service toneIndigo
```

## Components

### Client experience

- [App entry](https://github.com/gmphto/feedback/blob/master/client/src/main.tsx): `client/src/main.tsx`
- [Protected routing](https://github.com/gmphto/feedback/blob/master/client/src/app/AppRoutes.tsx): `client/src/app/AppRoutes.tsx`

### Authentication

- [Auth state and actions](https://github.com/gmphto/feedback/blob/master/client/src/features/auth/state/AuthProvider.tsx): `client/src/features/auth/state/AuthProvider.tsx`
- [Session API client](https://github.com/gmphto/feedback/blob/master/client/src/features/auth/api/auth.ts): `client/src/features/auth/api/auth.ts`
- [Auth routes](https://github.com/gmphto/feedback/blob/master/server/src/auth/routes.ts): `server/src/auth/routes.ts`
- [Login service](https://github.com/gmphto/feedback/blob/master/server/src/auth/service.ts): `server/src/auth/service.ts`
- [OIDC adapter](https://github.com/gmphto/feedback/blob/master/server/src/auth/oidc.ts): `server/src/auth/oidc.ts`
- [Session repository](https://github.com/gmphto/feedback/blob/master/server/src/auth/repository.ts): `server/src/auth/repository.ts`

### Project planning

- [Project entry](https://github.com/gmphto/feedback/blob/master/client/src/features/projects/ProjectIndex.tsx): `client/src/features/projects/ProjectIndex.tsx`
- [Project dashboard](https://github.com/gmphto/feedback/blob/master/client/src/features/projects/dashboard/Dashboard.tsx): `client/src/features/projects/dashboard/Dashboard.tsx`
- [Project editor](https://github.com/gmphto/feedback/blob/master/client/src/features/projects/editor/Editor.tsx): `client/src/features/projects/editor/Editor.tsx`
- [Planning context pane](https://github.com/gmphto/feedback/blob/master/client/src/features/projects/editor/components/ContextPane/ContextPane.tsx): `client/src/features/projects/editor/components/ContextPane/ContextPane.tsx`
- [Project API client](https://github.com/gmphto/feedback/blob/master/client/src/features/projects/api/api.ts): `client/src/features/projects/api/api.ts`

### Backend services

- [HTTP API](https://github.com/gmphto/feedback/blob/master/server/src/app.ts): `server/src/app.ts`
- [Project routes](https://github.com/gmphto/feedback/blob/master/server/src/projects/routes.ts): `server/src/projects/routes.ts`
- [Project policy](https://github.com/gmphto/feedback/blob/master/server/src/projects/policy.ts): `server/src/projects/policy.ts`
- [Definition validation](https://github.com/gmphto/feedback/blob/master/server/src/projects/creation.ts): `server/src/projects/creation.ts`
- [Project operations](https://github.com/gmphto/feedback/blob/master/server/src/projects/module.ts): `server/src/projects/module.ts`

### Persistence

- [PostgreSQL access](https://github.com/gmphto/feedback/blob/master/server/src/db/database.ts): `server/src/db/database.ts`

### Other components

- **Developer**
- **PostgreSQL**
- **OIDC identity provider**

## Connections

- Developer → App entry: uses (evidence: `README.md`)
- App entry → Protected routing: renders (evidence: `client/src/main.tsx`)
- Protected routing → Project entry: routes to (evidence: `client/src/app/AppRoutes.tsx`)
- Project entry → Project dashboard: renders (evidence: `client/src/features/projects/ProjectIndex.tsx`)
- Project entry → Project editor: renders (evidence: `client/src/features/projects/ProjectIndex.tsx`)
- App entry → Auth state and actions: provides (evidence: `client/src/main.tsx`)
- Auth state and actions → Session API client: queries session (evidence: `client/src/features/auth/state/AuthProvider.tsx`)
- Auth state and actions → Session API client: starts or ends session (evidence: `client/src/features/auth/state/AuthProvider.tsx`)
- Auth state and actions → Protected routing: gates routes (evidence: `client/src/app/App.tsx`)
- Project editor → Planning context pane: renders (evidence: `client/src/features/projects/editor/components/ContextPane/ContextPane.tsx`)
- Project editor → Project API client: saves project
- Project dashboard → Project API client: loads projects
- Session API client → HTTP API: requests session
- Project API client → HTTP API: requests projects
- HTTP API → Auth routes: registers (evidence: `server/src/app.ts`)
- HTTP API → Project routes: registers (evidence: `server/src/app.ts`)
- Auth routes → Login service: starts and completes login (evidence: `server/src/auth/routes.ts`)
- Login service → OIDC adapter: verifies identity (evidence: `server/src/auth/service.ts`)
- Login service → Session repository: stores login and session (evidence: `server/src/auth/service.ts`)
- OIDC adapter → OIDC identity provider: uses provider
- Auth routes → Session repository: checks or revokes session (evidence: `server/src/auth/routes.ts`)
- Project routes → Auth routes: requires session (evidence: `server/src/projects/routes.ts`)
- Project routes → Project policy: validates request (evidence: `server/src/projects/routes.ts`)
- Project routes → Definition validation: validates definition (evidence: `server/src/projects/routes.ts`)
- Project routes → Project operations: dispatches operations (evidence: `server/src/projects/routes.ts`)
- Project operations → Project policy: validates names (evidence: `server/src/projects/module.ts`)
- Project operations → Definition validation: validates input (evidence: `server/src/projects/module.ts`)
- Project operations → PostgreSQL access: reads and writes (evidence: `server/src/projects/module.ts`)
- Session repository → PostgreSQL access: reads and writes (evidence: `server/src/auth/repository.ts`)
- PostgreSQL access → PostgreSQL: queries (evidence: `server/src/db/database.ts`)
