# chrisscastaneda/hop-dot architecture

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

- Interactive diagram: https://gitdiagram.com/chrisscastaneda/hop-dot
- Repository: https://github.com/chrisscastaneda/hop-dot

## Overview

Hop Dot is a browser-based triangular peg-jumping game. In the main Vue workflow, a player selects a dot, chooses an empty destination, and the game updates the board and displays move animation or an end-state message. The game logic and board presentation are implemented together in `src/HopDot.vue`, with individual dots rendered by `src/components/DotComponent.vue`. The repository also includes a small static-server path and a separate plain Vue app under `public/`; their relationship to the main Vue app is not established. Unsampled template and runtime details are omitted.

Main entry points: [`src/HopDot.vue`](https://github.com/chrisscastaneda/hop-dot/blob/main/src/HopDot.vue) (Board and state), [`src/main.js`](https://github.com/chrisscastaneda/hop-dot/blob/main/src/main.js) (Vue entry), [`server.js`](https://github.com/chrisscastaneda/hop-dot/blob/main/server.js) (Static server), [`src/components/DotComponent.vue`](https://github.com/chrisscastaneda/hop-dot/blob/main/src/components/DotComponent.vue) (Dot display)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_game["Game"]
  node_mount["Vue entry<br/>[main.js]"]
  node_board["Board and state<br/>[HopDot.vue]"]
  node_moves["Move rules<br/>[HopDot.vue]"]
  node_animation["Move animation<br/>[HopDot.vue]"]
  node_dot["Dot display<br/>[DotComponent.vue]"]
end

subgraph group_delivery["Static serving"]
  node_server["Static server<br/>[server.js]"]
  node_staticapp["Standalone dot app<br/>[app.js]"]
end

node_player(("Player"))

node_player -->|"opens game"| node_mount
node_mount -->|"mounts"| node_board
node_board -->|"renders"| node_dot
node_player -->|"selects dots"| node_board
node_board -->|"attempts move"| node_moves
node_moves -.->|"sets animation"| node_animation
node_player -->|"requests files"| node_server
node_server -->|"serves files"| node_staticapp

click node_mount "https://github.com/chrisscastaneda/hop-dot/blob/main/src/main.js"
click node_board "https://github.com/chrisscastaneda/hop-dot/blob/main/src/HopDot.vue"
click node_moves "https://github.com/chrisscastaneda/hop-dot/blob/main/src/HopDot.vue"
click node_animation "https://github.com/chrisscastaneda/hop-dot/blob/main/src/HopDot.vue"
click node_dot "https://github.com/chrisscastaneda/hop-dot/blob/main/src/components/DotComponent.vue"
click node_server "https://github.com/chrisscastaneda/hop-dot/blob/main/server.js"
click node_staticapp "https://github.com/chrisscastaneda/hop-dot/blob/main/public/app.js"

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_mount,node_board,node_moves,node_animation,node_dot toneBlue
class node_server,node_staticapp toneAmber
class node_player toneIndigo
```

## Components

### Game

- [Vue entry](https://github.com/chrisscastaneda/hop-dot/blob/main/src/main.js): `src/main.js`
- [Board and state](https://github.com/chrisscastaneda/hop-dot/blob/main/src/HopDot.vue): `src/HopDot.vue`
- [Move rules](https://github.com/chrisscastaneda/hop-dot/blob/main/src/HopDot.vue): `src/HopDot.vue`
- [Move animation](https://github.com/chrisscastaneda/hop-dot/blob/main/src/HopDot.vue): `src/HopDot.vue`
- [Dot display](https://github.com/chrisscastaneda/hop-dot/blob/main/src/components/DotComponent.vue): `src/components/DotComponent.vue`

### Static serving

- [Static server](https://github.com/chrisscastaneda/hop-dot/blob/main/server.js): `server.js`
- [Standalone dot app](https://github.com/chrisscastaneda/hop-dot/blob/main/public/app.js): `public/app.js`

### Other components

- **Player**

## Connections

- Player → Vue entry: opens game (evidence: `README.md`)
- Vue entry → Board and state: mounts (evidence: `src/main.js`)
- Board and state → Dot display: renders (evidence: `src/HopDot.vue`)
- Player → Board and state: selects dots (evidence: `src/HopDot.vue`)
- Board and state → Move rules: attempts move (evidence: `src/HopDot.vue`)
- Move rules → Move animation: sets animation (evidence: `src/HopDot.vue`)
- Player → Static server: requests files (evidence: `server.js`)
- Static server → Standalone dot app: serves files (evidence: `server.js`)
