# jiaxiantao/3d-express-warehouse architecture

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

- Interactive diagram: https://gitdiagram.com/jiaxiantao/3d-express-warehouse
- Repository: https://github.com/jiaxiantao/3d-express-warehouse

## Overview

This is a browser-based 3D warehouse/WMS demo. The main workflow opens the warehouse console, seeds slot inventory, applies URL state or a SKU scan, and presents interactive 3D slots with status filters, statistics, and a detail/action panel. The scene also supports robot movement and camera views. The graph preserves documented QR, deep-link, screenshot/fullscreen, and slot-management capabilities. Some feature wiring is documented or indexed but not excerpted; those edges cite the README or are omitted where ownership is unclear.

Main entry points: [`src/app/warehouse/page.tsx`](https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/app/warehouse/page.tsx) (Warehouse page), [`src/components/warehouse-scene.tsx`](https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/components/warehouse-scene.tsx) (Interactive 3D scene), [`src/lib/warehouse-data.ts`](https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/lib/warehouse-data.ts) (Slot state and actions), [`src/components/warehouse-robot.tsx`](https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/components/warehouse-robot.tsx) (Robot model)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_console["Warehouse console"]
  node_console["Warehouse page<br/>[page.tsx]"]
  node_urlstate["URL state"]
  node_scanner["QR scanner"]
  node_quick["Quick actions"]
  node_panel["Slot panel"]
  node_stats["Statistics and filters"]
  node_robotpad["Robot pad"]
end

subgraph group_inventory["Inventory and slot data"]
  node_scan["SKU scan resolver<br/>[warehouse-scan.ts]"]
  node_data["Slot state and actions<br/>[warehouse-data.ts]"]
  node_types["Warehouse domain types<br/>[warehouse-types.ts]"]
  node_rackcategory["Rack categories"]
end

subgraph group_visualization["3D warehouse scene"]
  node_scene["Interactive 3D scene"]
  node_environment["Warehouse environment"]
  node_layout["Rack and slot geometry"]
  node_colors["Status colors"]
  node_animations["Slot animations"]
end

subgraph group_robot["Robot navigation"]
  node_robot["Robot model"]
  node_robotcontrols["Robot controls"]
  node_navigation["Walk navigation"]
  node_drive["Drive state"]
  node_robotconfig["Robot configuration"]
  node_robotanimation["Robot animation rig"]
  node_robotanimator["Robot animator"]
end

node_user(("Warehouse user"))

node_user -->|"opens console"| node_console
node_console -->|"seeds slots"| node_data
node_console -->|"reads URL state"| node_urlstate
node_console -->|"resolves SKU"| node_scan
node_console -->|"opens scanner"| node_scanner
node_console -->|"renders actions"| node_quick
node_console -->|"renders details"| node_panel
node_console -->|"renders statistics"| node_stats
node_console -->|"renders scene"| node_scene
node_console -->|"renders controls"| node_robotpad
node_scan -->|"looks up slots"| node_data
node_data -->|"selects products"| node_rackcategory
node_console -->|"applies slot actions"| node_data
node_scene -->|"displays slot state"| node_data
node_scene -->|"positions slots"| node_layout
node_scene -->|"colors status"| node_colors
node_scene -->|"animates slot actions"| node_animations
node_scene -->|"renders environment"| node_environment
node_scene -->|"renders robot"| node_robot
node_scene -->|"attaches controls"| node_robotcontrols
node_robotcontrols -->|"steps toward targets"| node_navigation
node_robotcontrols -->|"reads drive state"| node_drive
node_navigation -->|"uses aisle bounds"| node_layout
node_robot -->|"sets up animation"| node_robotanimation
node_robot -->|"renders animator"| node_robotanimator
node_data -->|"uses domain types"| node_types
node_stats -->|"uses status colors"| node_colors
node_panel -->|"uses status colors"| node_colors
node_user -.->|"scans SKU"| node_scanner
node_user -.->|"filters and views"| node_scene
node_user -.->|"manages slots"| node_panel

click node_console "https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/app/warehouse/page.tsx"
click node_urlstate "https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/lib/use-warehouse-url-state.ts"
click node_scanner "https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/components/warehouse-qr-scanner.tsx"
click node_quick "https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/components/warehouse-quick-actions.tsx"
click node_panel "https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/components/warehouse-slot-panel.tsx"
click node_stats "https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/components/warehouse-stats-bar.tsx"
click node_robotpad "https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/components/warehouse-robot-pad.tsx"
click node_scan "https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/lib/warehouse-scan.ts"
click node_data "https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/lib/warehouse-data.ts"
click node_types "https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/lib/warehouse-types.ts"
click node_rackcategory "https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/lib/warehouse-rack-category.ts"
click node_scene "https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/components/warehouse-scene.tsx"
click node_environment "https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/components/warehouse-environment.tsx"
click node_layout "https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/lib/warehouse-layout.ts"
click node_colors "https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/lib/warehouse-colors.ts"
click node_animations "https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/lib/warehouse-animations.ts"
click node_robot "https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/components/warehouse-robot.tsx"
click node_robotcontrols "https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/components/warehouse-robot-controls.tsx"
click node_navigation "https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/lib/warehouse-robot-navigation.ts"
click node_drive "https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/lib/warehouse-robot-drive.ts"
click node_robotconfig "https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/lib/warehouse-robot-config.ts"
click node_robotanimation "https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/lib/warehouse-robot-animation.ts"
click node_robotanimator "https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/components/warehouse-robot-animator.tsx"

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_console,node_urlstate,node_scanner,node_quick,node_panel,node_stats,node_robotpad,node_user toneBlue
class node_scan,node_data,node_types,node_rackcategory toneAmber
class node_scene,node_environment,node_layout,node_colors,node_animations toneMint
class node_robot,node_robotcontrols,node_navigation,node_drive,node_robotconfig,node_robotanimation,node_robotanimator toneRose
```

## Components

### Warehouse console

- [Warehouse page](https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/app/warehouse/page.tsx): `src/app/warehouse/page.tsx`
- [URL state](https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/lib/use-warehouse-url-state.ts): `src/lib/use-warehouse-url-state.ts`
- [QR scanner](https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/components/warehouse-qr-scanner.tsx): `src/components/warehouse-qr-scanner.tsx`
- [Quick actions](https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/components/warehouse-quick-actions.tsx): `src/components/warehouse-quick-actions.tsx`
- [Slot panel](https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/components/warehouse-slot-panel.tsx): `src/components/warehouse-slot-panel.tsx`
- [Statistics and filters](https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/components/warehouse-stats-bar.tsx): `src/components/warehouse-stats-bar.tsx`
- [Robot pad](https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/components/warehouse-robot-pad.tsx): `src/components/warehouse-robot-pad.tsx`

### Inventory and slot data

- [SKU scan resolver](https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/lib/warehouse-scan.ts): `src/lib/warehouse-scan.ts`
- [Slot state and actions](https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/lib/warehouse-data.ts): `src/lib/warehouse-data.ts`
- [Warehouse domain types](https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/lib/warehouse-types.ts): `src/lib/warehouse-types.ts`
- [Rack categories](https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/lib/warehouse-rack-category.ts): `src/lib/warehouse-rack-category.ts`

### 3D warehouse scene

- [Interactive 3D scene](https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/components/warehouse-scene.tsx): `src/components/warehouse-scene.tsx`
- [Warehouse environment](https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/components/warehouse-environment.tsx): `src/components/warehouse-environment.tsx`
- [Rack and slot geometry](https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/lib/warehouse-layout.ts): `src/lib/warehouse-layout.ts`
- [Status colors](https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/lib/warehouse-colors.ts): `src/lib/warehouse-colors.ts`
- [Slot animations](https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/lib/warehouse-animations.ts): `src/lib/warehouse-animations.ts`

### Robot navigation

- [Robot model](https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/components/warehouse-robot.tsx): `src/components/warehouse-robot.tsx`
- [Robot controls](https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/components/warehouse-robot-controls.tsx): `src/components/warehouse-robot-controls.tsx`
- [Walk navigation](https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/lib/warehouse-robot-navigation.ts): `src/lib/warehouse-robot-navigation.ts`
- [Drive state](https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/lib/warehouse-robot-drive.ts): `src/lib/warehouse-robot-drive.ts`
- [Robot configuration](https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/lib/warehouse-robot-config.ts): `src/lib/warehouse-robot-config.ts`
- [Robot animation rig](https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/lib/warehouse-robot-animation.ts): `src/lib/warehouse-robot-animation.ts`
- [Robot animator](https://github.com/jiaxiantao/3d-express-warehouse/blob/main/src/components/warehouse-robot-animator.tsx): `src/components/warehouse-robot-animator.tsx`

### Other components

- **Warehouse user**

## Connections

- Warehouse user → Warehouse page: opens console (evidence: `README.md`)
- Warehouse page → Slot state and actions: seeds slots (evidence: `src/app/warehouse/page.tsx`)
- Warehouse page → URL state: reads URL state (evidence: `src/app/warehouse/page.tsx`)
- Warehouse page → SKU scan resolver: resolves SKU (evidence: `src/app/warehouse/page.tsx`)
- Warehouse page → QR scanner: opens scanner (evidence: `src/app/warehouse/page.tsx`)
- Warehouse page → Quick actions: renders actions (evidence: `src/app/warehouse/page.tsx`)
- Warehouse page → Slot panel: renders details (evidence: `src/app/warehouse/page.tsx`)
- Warehouse page → Statistics and filters: renders statistics (evidence: `src/app/warehouse/page.tsx`)
- Warehouse page → Interactive 3D scene: renders scene (evidence: `src/app/warehouse/page.tsx`)
- Warehouse page → Robot pad: renders controls (evidence: `src/app/warehouse/page.tsx`)
- SKU scan resolver → Slot state and actions: looks up slots (evidence: `src/lib/warehouse-scan.ts`)
- Slot state and actions → Rack categories: selects products (evidence: `src/lib/warehouse-data.ts`)
- Warehouse page → Slot state and actions: applies slot actions (evidence: `README.md`)
- Interactive 3D scene → Slot state and actions: displays slot state (evidence: `README.md`)
- Interactive 3D scene → Rack and slot geometry: positions slots (evidence: `src/components/warehouse-scene.tsx`)
- Interactive 3D scene → Status colors: colors status (evidence: `src/components/warehouse-scene.tsx`)
- Interactive 3D scene → Slot animations: animates slot actions (evidence: `src/components/warehouse-scene.tsx`)
- Interactive 3D scene → Warehouse environment: renders environment (evidence: `src/components/warehouse-scene.tsx`)
- Interactive 3D scene → Robot model: renders robot (evidence: `src/components/warehouse-scene.tsx`)
- Interactive 3D scene → Robot controls: attaches controls (evidence: `src/components/warehouse-scene.tsx`)
- Robot controls → Walk navigation: steps toward targets (evidence: `src/components/warehouse-robot-controls.tsx`)
- Robot controls → Drive state: reads drive state (evidence: `src/components/warehouse-robot-controls.tsx`)
- Walk navigation → Rack and slot geometry: uses aisle bounds (evidence: `src/lib/warehouse-robot-navigation.ts`)
- Robot model → Robot animation rig: sets up animation (evidence: `src/components/warehouse-robot.tsx`)
- Robot model → Robot animator: renders animator (evidence: `src/components/warehouse-robot.tsx`)
- Slot state and actions → Warehouse domain types: uses domain types (evidence: `src/lib/warehouse-data.ts`)
- Statistics and filters → Status colors: uses status colors (evidence: `src/components/warehouse-stats-bar.tsx`)
- Slot panel → Status colors: uses status colors (evidence: `src/components/warehouse-slot-panel.tsx`)
- Warehouse user → QR scanner: scans SKU (evidence: `README.md`)
- Warehouse user → Interactive 3D scene: filters and views (evidence: `README.md`)
- Warehouse user → Slot panel: manages slots (evidence: `README.md`)
