# rhinori/jigsaw-puzzle-game architecture

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

- Interactive diagram: https://gitdiagram.com/rhinori/jigsaw-puzzle-game
- Repository: https://github.com/rhinori/jigsaw-puzzle-game

## Overview

This is a Flutter jigsaw-puzzle game. The apparent user journey is home screen → puzzle-level selection → gameplay, with puzzle logic and points supporting the game; puzzle data is represented by a model and an API-service module. The README provides no feature details, and the Dart sources were not excerpted, so these relationships are inferred from filenames and shown as unverified. Native runner and generated plugin files appear to be platform scaffolding rather than product functionality.

Main entry points: [`lib/utils/screens/puzzles/game_screen.dart`](https://github.com/rhinori/jigsaw-puzzle-game/blob/master/lib/utils/screens/puzzles/game_screen.dart) (Game screen), [`lib/utils/screens/home/home_screen.dart`](https://github.com/rhinori/jigsaw-puzzle-game/blob/master/lib/utils/screens/home/home_screen.dart) (Home screen), [`lib/utils/screens/puzzles/puzzle_list_levels.dart`](https://github.com/rhinori/jigsaw-puzzle-game/blob/master/lib/utils/screens/puzzles/puzzle_list_levels.dart) (Puzzle levels), [`lib/utils/providers/points_provider.dart`](https://github.com/rhinori/jigsaw-puzzle-game/blob/master/lib/utils/providers/points_provider.dart) (Points provider)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_screens["Game screens"]
  node_home["Home screen<br/>[home_screen.dart]"]
  node_levels["Puzzle levels"]
  node_game_screen["Game screen<br/>[game_screen.dart]"]
end

subgraph group_game["Puzzle gameplay"]
  node_logic["Puzzle logic"]
end

subgraph group_data["Puzzle data"]
  node_puzzle_service["Puzzle data service"]
  node_puzzle_model["Puzzle data model<br/>[puzzle_data.dart]"]
end

subgraph group_state["Score state"]
  node_points_count["Points count<br/>[points_count.dart]"]
  node_points_provider["Points provider"]
end

node_player(("Player"))

node_player -.->|"opens"| node_home
node_home -.->|"selects puzzle"| node_levels
node_levels -.->|"starts game"| node_game_screen
node_game_screen -.->|"uses logic"| node_logic
node_game_screen -.->|"updates score"| node_points_provider
node_points_provider -.->|"tracks points"| node_points_count
node_puzzle_service -.->|"provides data"| node_puzzle_model

click node_home "https://github.com/rhinori/jigsaw-puzzle-game/blob/master/lib/utils/screens/home/home_screen.dart"
click node_levels "https://github.com/rhinori/jigsaw-puzzle-game/blob/master/lib/utils/screens/puzzles/puzzle_list_levels.dart"
click node_game_screen "https://github.com/rhinori/jigsaw-puzzle-game/blob/master/lib/utils/screens/puzzles/game_screen.dart"
click node_logic "https://github.com/rhinori/jigsaw-puzzle-game/blob/master/lib/utils/jigsaw_puzzle_logic.dart"
click node_points_count "https://github.com/rhinori/jigsaw-puzzle-game/blob/master/lib/utils/providers/points_count.dart"
click node_points_provider "https://github.com/rhinori/jigsaw-puzzle-game/blob/master/lib/utils/providers/points_provider.dart"
click node_puzzle_service "https://github.com/rhinori/jigsaw-puzzle-game/blob/master/lib/utils/api_services/puzzle_data_service.dart"
click node_puzzle_model "https://github.com/rhinori/jigsaw-puzzle-game/blob/master/lib/utils/models/puzzle_data.dart"

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_home,node_levels,node_game_screen toneBlue
class node_logic toneAmber
class node_puzzle_service,node_puzzle_model toneMint
class node_points_count,node_points_provider toneRose
class node_player toneIndigo
```

## Components

### Game screens

- [Home screen](https://github.com/rhinori/jigsaw-puzzle-game/blob/master/lib/utils/screens/home/home_screen.dart): `lib/utils/screens/home/home_screen.dart`
- [Puzzle levels](https://github.com/rhinori/jigsaw-puzzle-game/blob/master/lib/utils/screens/puzzles/puzzle_list_levels.dart): `lib/utils/screens/puzzles/puzzle_list_levels.dart`
- [Game screen](https://github.com/rhinori/jigsaw-puzzle-game/blob/master/lib/utils/screens/puzzles/game_screen.dart): `lib/utils/screens/puzzles/game_screen.dart`

### Puzzle gameplay

- [Puzzle logic](https://github.com/rhinori/jigsaw-puzzle-game/blob/master/lib/utils/jigsaw_puzzle_logic.dart): `lib/utils/jigsaw_puzzle_logic.dart`

### Puzzle data

- [Puzzle data service](https://github.com/rhinori/jigsaw-puzzle-game/blob/master/lib/utils/api_services/puzzle_data_service.dart): `lib/utils/api_services/puzzle_data_service.dart`
- [Puzzle data model](https://github.com/rhinori/jigsaw-puzzle-game/blob/master/lib/utils/models/puzzle_data.dart): `lib/utils/models/puzzle_data.dart`

### Score state

- [Points count](https://github.com/rhinori/jigsaw-puzzle-game/blob/master/lib/utils/providers/points_count.dart): `lib/utils/providers/points_count.dart`
- [Points provider](https://github.com/rhinori/jigsaw-puzzle-game/blob/master/lib/utils/providers/points_provider.dart): `lib/utils/providers/points_provider.dart`

### Other components

- **Player**

## Connections

- Player → Home screen: opens
- Home screen → Puzzle levels: selects puzzle
- Puzzle levels → Game screen: starts game
- Game screen → Puzzle logic: uses logic
- Game screen → Points provider: updates score
- Points provider → Points count: tracks points
- Puzzle data service → Puzzle data model: provides data
