# kaankaltakkiran/green_mind_game architecture

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

- Interactive diagram: https://gitdiagram.com/kaankaltakkiran/green_mind_game
- Repository: https://github.com/kaankaltakkiran/green_mind_game

## Overview

Green Mind Game is a browser-based environmental quiz. The visible workflow configures groups and question counts, runs timed multiple-choice turns, awards points, and presents scores and winners. The game logic and bundled question bank are local to the frontend. The README also describes authentication, leaderboards, and additional scoring features, but no corresponding implementation appears in the supplied tree; those are noted as documented capabilities rather than connected runtime components.

Main entry points: [`frontend/src/pages/IndexPage.vue`](https://github.com/kaankaltakkiran/green_mind_game/blob/main/frontend/src/pages/IndexPage.vue) (Quiz screen), [`frontend/src/router/routes.ts`](https://github.com/kaankaltakkiran/green_mind_game/blob/main/frontend/src/router/routes.ts) (Page routes), [`frontend/src/composables/useQuizGame.ts`](https://github.com/kaankaltakkiran/green_mind_game/blob/main/frontend/src/composables/useQuizGame.ts) (Game state and turns), [`frontend/src/router/index.ts`](https://github.com/kaankaltakkiran/green_mind_game/blob/main/frontend/src/router/index.ts) (Route setup)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_navigation["Frontend navigation"]
  node_app["App shell<br/>[App.vue]"]
  node_router["Route setup<br/>[index.ts]"]
  node_routes["Page routes<br/>[routes.ts]"]
  node_layout["Main layout<br/>[MainLayout.vue]"]
end

subgraph group_quiz["Quiz experience"]
  node_quiz_page["Quiz screen<br/>[IndexPage.vue]"]
  node_game_logic["Game state and turns<br/>[useQuizGame.ts]"]
  node_question_bank["Question bank<br/>[data.json]"]
  node_quiz_types["Quiz data types<br/>[quiz.ts]"]
  node_documented_capabilities["Documented account and rankings"]
end

subgraph group_support["Frontend support"]
  node_i18n_boot["Internationalization boot<br/>[i18n.ts]"]
  node_language_catalog["English messages<br/>[index.ts]"]
  node_example_component["Example component"]
  node_example_models["Example data models<br/>[models.ts]"]
end

node_player(("Player"))

node_app -.->|"renders routes"| node_router
node_router -->|"loads routes"| node_routes
node_routes -->|"uses layout"| node_layout
node_routes -->|"routes to"| node_quiz_page
node_player -.->|"uses"| node_quiz_page
node_quiz_page -->|"calls game logic"| node_game_logic
node_game_logic -->|"reads questions"| node_question_bank
node_game_logic -->|"uses types"| node_quiz_types
node_quiz_page -.->|"documents features"| node_documented_capabilities
node_i18n_boot -.->|"loads messages"| node_language_catalog
node_example_component -->|"uses types"| node_example_models

click node_app "https://github.com/kaankaltakkiran/green_mind_game/blob/main/frontend/src/App.vue"
click node_router "https://github.com/kaankaltakkiran/green_mind_game/blob/main/frontend/src/router/index.ts"
click node_routes "https://github.com/kaankaltakkiran/green_mind_game/blob/main/frontend/src/router/routes.ts"
click node_layout "https://github.com/kaankaltakkiran/green_mind_game/blob/main/frontend/src/layouts/MainLayout.vue"
click node_quiz_page "https://github.com/kaankaltakkiran/green_mind_game/blob/main/frontend/src/pages/IndexPage.vue"
click node_game_logic "https://github.com/kaankaltakkiran/green_mind_game/blob/main/frontend/src/composables/useQuizGame.ts"
click node_question_bank "https://github.com/kaankaltakkiran/green_mind_game/blob/main/frontend/src/data/data.json"
click node_quiz_types "https://github.com/kaankaltakkiran/green_mind_game/blob/main/frontend/src/types/quiz.ts"
click node_documented_capabilities "https://github.com/kaankaltakkiran/green_mind_game/tree/main/frontend/src"
click node_i18n_boot "https://github.com/kaankaltakkiran/green_mind_game/blob/main/frontend/src/boot/i18n.ts"
click node_language_catalog "https://github.com/kaankaltakkiran/green_mind_game/blob/main/frontend/src/i18n/en-US/index.ts"
click node_example_component "https://github.com/kaankaltakkiran/green_mind_game/blob/main/frontend/src/components/ExampleComponent.vue"
click node_example_models "https://github.com/kaankaltakkiran/green_mind_game/blob/main/frontend/src/components/models.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_router,node_routes,node_layout toneBlue
class node_quiz_page,node_game_logic,node_question_bank,node_quiz_types,node_documented_capabilities toneAmber
class node_i18n_boot,node_language_catalog,node_example_component,node_example_models toneMint
class node_player toneIndigo
```

## Components

### Frontend navigation

- [App shell](https://github.com/kaankaltakkiran/green_mind_game/blob/main/frontend/src/App.vue): `frontend/src/App.vue`
- [Route setup](https://github.com/kaankaltakkiran/green_mind_game/blob/main/frontend/src/router/index.ts): `frontend/src/router/index.ts`
- [Page routes](https://github.com/kaankaltakkiran/green_mind_game/blob/main/frontend/src/router/routes.ts): `frontend/src/router/routes.ts`
- [Main layout](https://github.com/kaankaltakkiran/green_mind_game/blob/main/frontend/src/layouts/MainLayout.vue): `frontend/src/layouts/MainLayout.vue`

### Quiz experience

- [Quiz screen](https://github.com/kaankaltakkiran/green_mind_game/blob/main/frontend/src/pages/IndexPage.vue): `frontend/src/pages/IndexPage.vue`
- [Game state and turns](https://github.com/kaankaltakkiran/green_mind_game/blob/main/frontend/src/composables/useQuizGame.ts): `frontend/src/composables/useQuizGame.ts`
- [Question bank](https://github.com/kaankaltakkiran/green_mind_game/blob/main/frontend/src/data/data.json): `frontend/src/data/data.json`
- [Quiz data types](https://github.com/kaankaltakkiran/green_mind_game/blob/main/frontend/src/types/quiz.ts): `frontend/src/types/quiz.ts`
- [Documented account and rankings](https://github.com/kaankaltakkiran/green_mind_game/tree/main/frontend/src): `frontend/src`

### Frontend support

- [Internationalization boot](https://github.com/kaankaltakkiran/green_mind_game/blob/main/frontend/src/boot/i18n.ts): `frontend/src/boot/i18n.ts`
- [English messages](https://github.com/kaankaltakkiran/green_mind_game/blob/main/frontend/src/i18n/en-US/index.ts): `frontend/src/i18n/en-US/index.ts`
- [Example component](https://github.com/kaankaltakkiran/green_mind_game/blob/main/frontend/src/components/ExampleComponent.vue): `frontend/src/components/ExampleComponent.vue`
- [Example data models](https://github.com/kaankaltakkiran/green_mind_game/blob/main/frontend/src/components/models.ts): `frontend/src/components/models.ts`

### Other components

- **Player**

## Connections

- App shell → Route setup: renders routes
- Route setup → Page routes: loads routes (evidence: `frontend/src/router/index.ts`)
- Page routes → Main layout: uses layout (evidence: `frontend/src/router/routes.ts`)
- Page routes → Quiz screen: routes to (evidence: `frontend/src/router/routes.ts`)
- Player → Quiz screen: uses
- Quiz screen → Game state and turns: calls game logic (evidence: `frontend/src/pages/IndexPage.vue`)
- Game state and turns → Question bank: reads questions (evidence: `frontend/src/composables/useQuizGame.ts`)
- Game state and turns → Quiz data types: uses types (evidence: `frontend/src/composables/useQuizGame.ts`)
- Quiz screen → Documented account and rankings: documents features (evidence: `README.md`)
- Internationalization boot → English messages: loads messages
- Example component → Example data models: uses types (evidence: `frontend/src/components/ExampleComponent.vue`)
