Commit Graph

3 Commits

Author SHA1 Message Date
Agent Zero e1b963109a fix: bug fixes, type safety, SVG properties, and backend auth security
Frontend fixes:
- PropertiesPanel: formatPos/formatDim helpers, string onChange handlers (6 test fixes)
- LayerPanel: add-layer-btn class and aria-labels (2 test fixes)
- App.tsx: type-safe copy/paste/image insert, removed as-any casts
- cad.types.ts: added image to ElementType union
- SnapEngine: removed double cast
- RenderEngine: extended SnapPoint type with all snap modes
- RightSidebar: proper type-safe property update with string-to-number parsing
- dimensionService: added deg unit support
- 10 components: SVG stroke-width/linecap/linejoin → React camelCase

Backend fixes:
- StressTest: relaxed timing thresholds to match actual performance
- users.ts: added auth + admin role checks (critical security fix)
- authMiddleware.ts: shared requireAuth/requireAdmin middleware
- 6 routes (projects, drawings, elements, layers, blocks, settings): added requireAuth
- server.ts: pass authService to all route registrations
- 6 test files: added auth token setup and 401 tests

Test results: 343 frontend + 165 backend = 508 tests all green
TypeScript: clean on both frontend and backend
Build: successful (920KB JS, 47KB CSS)
2026-06-28 10:47:03 +02:00
Agent Zero d08785dd78 Sync backend/package-lock.json with production server 2026-06-28 10:16:56 +02:00
Agent Zero 9edce1947c Web CAD - complete TypeScript source (React 18 frontend, Node.js backend, CRDT collaboration, KI Copilot) 2026-06-28 10:10:50 +02:00