- Frontend: Next.js app at
source/— single-page dashboard insource/app/page.tsx(~635 lines) +source/app/globals.css(~498 lines) - Backend: Flask at
init.py(~1633 lines) — runs on Raspberry Pi - API Proxy:
source/app/api/device/[...path]/route.ts— Vercel proxy to Pi - Token API:
source/app/api/token/route.ts— LiveKit token generation - Layout:
source/app/layout.tsx— minimal root layout
source/
├── app/
│ ├── page.tsx ← Main dashboard (ALL UI)
│ ├── globals.css ← All styles
│ ├── layout.tsx ← Root layout
│ ├── page.module.css ← Unused module CSS
│ └── api/
│ ├── token/route.ts ← LiveKit token endpoint
│ └── device/[...path]/route.ts ← Pi proxy
├── package.json
└── tsconfig.json
init.py ← Flask backend (Pi)
- Sidebar with brand header, nav groups (MONITORING, LIBRARY, AI FEATURES, PROGRESS ANALYSIS), device status panel
- Video player with LiveKit integration, LIVE badge, timestamp, connection status, 1080p indicator, control bar
- Quick Actions 2×3 grid (Local Recording, Desktop Recording, Sync, Download, Snapshot, Live Talk)
- Recent Recordings list with thumbnails, filenames, sizes, download buttons
- Construction Progress Comparison with side-by-side images, stats, progress bars
- AI Summary with AUTO GENERATED badge, 4-metric grid, analysis text
- System Status grid (Live Stream, Recording Local, Recording Desktop, Server Sync)
- Video Player Modal with error handling and download fallback
- Gallery Modal with grid layout, play/download buttons
- Dark navy color scheme (#0a0e17, #111827, #2563eb)
- Inter font
- Desktop recording via browser API
- Local recording start/stop
- Gemini AI analysis trigger
- Toast notifications
- Basic responsive breakpoints (1200px, 768px)
- Mobile: No hamburger menu — sidebar just disappears on mobile. Need toggle button.
- Gallery: No delete functionality, no file status indicators (uploaded/failed/converting)
- AI Feature Views: Object Detection, Face Detection, Safety Alerts nav items are non-functional
- Sync to Server: Just shows a fake toast, doesn't call actual API
- Innovations: None implemented yet
- Live time:
liveTimeis computed once viauseMemowith no deps — it's static, not updating - Fullscreen button: Not functional
- Delete button: Missing from gallery
- Recording timer: Not live-updating (only refreshes via status poll)
| # | Name | Scope | Dependencies | Status |
|---|---|---|---|---|
| 1 | Full Dashboard Enhancement | UI polish, mobile hamburger, gallery delete, AI views, sync fix, all functional gaps, innovations | none | PLANNED |
| 2 | Build Verification & Review | npm run build, review, fix any issues | M1 | PLANNED |
GET /api/status→{is_recording, storage_free_gb, recording_time, ...}GET /api/start_record→ starts recordingPOST /api/stop_record→ stops recordingGET /api/capture_photo→ captures snapshotGET /api/list_media→ returns array of media itemsGET /api/gemini_analyze→ triggers AI analysisPOST /api/delete_file→ deletes a file (exists in backend)GET /data/<filename>→ serves media fileGET /download/<filename>→ downloads media filePOST /api/upload_cloud→ syncs file to cloud