Commit Graph
24 Commits
Author SHA1 Message Date
tremble7681 102a2525db feat(mechanic-pwa): multi-step damage flow (confirm -> zone detail -> classify -> photo) 2026-05-17 23:45:34 +10:00
tremble7681 8893710254 feat(mechanic-pwa): action menu + vehicle list at /vehicles + mileage dialog + photo icon 2026-05-17 22:13:04 +10:00
tremble7681 ab9ddf7289 feat(mechanic-pwa): use vendor SVG scheme with zone-based markers (1:1 vendor coords for future import)
- Add public/scheme/exterior.svg (131 KB, viewBox 0 0 827 1209, 57 zones class="0"..class="56")
- Add public/scheme/salon.svg (53 KB, Phase 2 reserve)
- New VendorVehicleScheme: fetches SVG as separate asset (?url), strips vendor <script>,
  wires click/hover via event delegation, tints zones red/gray/blue by damage state
- AddMarkerDialog: side required, x/y optional (zone-level markers store NULL x/y)
- InspectionEditor/InspectionReview: swap CompositeVehicleScheme -> VendorVehicleScheme,
  pendingTap now {side} only, humanizeMarkerSide handles zone-{N} and legacy named zones
- Delete CompositeVehicleScheme (PNG grid + bumper suns)
- No backend changes; side=zone-{N} accepted by existing Optional[str] field
2026-05-17 20:18:46 +10:00
tremble7681 bd7665fb1d docs: update repo reference taxi-dashboard -> premium-crm 2026-05-17 19:48:48 +10:00
tremble7681andclaude-flow df709c58e5 feat(mechanic-pwa): composite unfolded scheme + tire wear dialog (replaces 5-tab view)
Single-screen grid layout showing all 5 PNG views + 4 bumper corner sun-zones + decorative
wheels at once. Tap any view for precise AddMarkerDialog; tap bumper corners for center-point
marker; global Tire Wear button opens new TireWearDialog (4-level radio cards).
Deletes MultiViewVehicleScheme. No backend changes. humanizeMarkerSide covers bumper-* and tires.

Co-Authored-By: claude-flow <ruv@ruv.net>
2026-05-17 19:41:13 +10:00
tremble7681andclaude-flow 3c6dacb29b feat(mechanic-pwa): multi-view vendor scheme, exact tap coords, per-marker photo upload
- Replace SVG sedan zone-click model with 5-view PNG scheme (top/front/back/left/right)
- New MultiViewVehicleScheme: tab selector, tap-to-exact-coord marker placement,
  touchAction:manipulation prevents iOS double-tap zoom, marker dots at normalized x/y
- New AddMarkerDialog: bottom-sheet modal with damage_type (16 opts), severity (4 opts),
  description, optional CameraCapture → uploadPhoto(side="free") → photo_id on submit
- InspectionEditor: removes addZoneMarker mutation and zone-count machinery; wires
  pendingTap state → dialog open/close → query invalidation
- InspectionReview: adds read-only MultiViewVehicleScheme; both pages show photo_id
  thumbnails via AuthImg in the marker list
- humanizeMarkerSide updated for new view names; keeps zone-* legacy mapping
- Deletes VehicleScheme.tsx and sedan-top.svg (no remaining imports)
- No backend changes, no new dependencies

Co-Authored-By: claude-flow <ruv@ruv.net>
2026-05-17 12:21:06 +10:00
tremble7681andclaude-flow 7775e74108 feat(mechanic-pwa): 2FA flow with trusted-device cookie support
Wire frontend to backend 2FA contract: two-step state machine in Login.tsx
(credentials → totp), new login2fa() call to POST /api/auth/2fa, credentials:include
on both fetches so the 30-day trusted_device cookie travels correctly.

Co-Authored-By: claude-flow <ruv@ruv.net>
2026-05-17 11:58:42 +10:00
tremble7681 da0436cee8 docs(state): Phase 1 MVP LIVE — backend+frontend deployed, smoke checks green 2026-05-17 11:34:19 +10:00
tremble7681 db938c818d docs(state): Phase 1 MVP code-complete (B-I), deployment runbook ready for Phase J 2026-05-17 10:58:11 +10:00
tremble7681andclaude-flow a428395071 feat(mechanic-pwa): VehicleScheme + InspectionEditor + InspectionReview pages (Phase I4-I6)
Co-Authored-By: claude-flow <ruv@ruv.net>
2026-05-17 10:54:00 +10:00
tremble7681andclaude-flow fc4060d4d9 feat(mechanic-pwa): photo upload infra (CameraCapture + PhotoSlot + AuthImg + presigned PUT)
Co-Authored-By: claude-flow <ruv@ruv.net>
2026-05-17 10:48:51 +10:00
tremble7681andclaude-flow 537548d716 feat(mechanic-pwa): Login + Home + VehicleCard pages with TanStack Query + OAuth2 login
- api/auth.ts: OAuth2 password flow via form-urlencoded POST /api/auth/login (not mechanic prefix)
- api/me.ts: GET /api/v1/mechanic/me with Me interface
- api/vehicles.ts: listVehicles (unwraps {items:[]}), getVehicle with VehicleDetail + InspectionSummary
- api/inspections.ts: createInspection returning full InspectionDetail; 9-value InspectionType union
- Login.tsx: full form with Логин/Пароль labels, useMutation, toast feedback, navigate on success
- Home.tsx: vehicle list with search, /me header with user name, logout, TanStack Query
- VehicleCard.tsx: vehicle info card, all 9 inspection type buttons (ru labels), history list

Co-Authored-By: claude-flow <ruv@ruv.net>
2026-05-17 10:44:39 +10:00
tremble7681andclaude-flow e815955d46 feat(mechanic-pwa): scaffold Vite+React+TS+Tailwind+shadcn+PWA+routing (Phase G G1-G5)
- Vite 8 + React 19 + TypeScript 6 project via create-vite react-ts template
- Tailwind v3.4 with shadcn-compatible cream palette (CSS vars)
- vite-plugin-pwa v1.3 with autoUpdate SW, manifest.webmanifest, 192+512 icons
- shadcn/ui components written manually (default style): button, card, input, label, sonner
- Zustand persist auth store, ky API client with Bearer token hooks
- React Router v7 routing with RequireAuth guard
- TanStack Query v5 + Toaster wired in main.tsx
- 5 stub pages: Login, Home, VehicleCard, InspectionEditor, InspectionReview
- Build: 293 KB JS / 9.4 KB CSS, clean zero-warning tsc+vite build

Co-Authored-By: claude-flow <ruv@ruv.net>
2026-05-17 10:39:27 +10:00
tremble7681 3660b80357 docs(state): Phase E complete (E1-E5), next is Phase F markers 2026-05-17 10:04:34 +10:00
tremble7681 173032c12e docs(state): Phase D complete (D1-D3 + test-fakes refactor), Phase E scoping 2026-05-17 01:08:04 +10:00
tremble7681 cbe9ae5d9c docs(state): Phase D decisions resolved + vendor recon findings, B3 contract widened 2026-05-17 00:36:13 +10:00
tremble7681 3a7bd749cc docs(state): Phase C complete (C1-C3), Phase D scoping notes 2026-05-17 00:15:17 +10:00
tremble7681 b04630cfd5 docs(state): Phase B complete (B1-B4), Phase C test-infra fork documented 2026-05-16 23:28:29 +10:00
tremble7681 dfc2e45731 docs: STATE.md with handoff for next session (Phase A done, Task B1 next) 2026-05-16 22:48:05 +10:00
tremble7681 f4e8818bf7 ops(minio): script to set global CORS allow-origin (verified working) 2026-05-16 22:37:12 +10:00
tremble7681 5370346a89 feat(ops): Caddy fragment for mechanic.pptaxi.ru 2026-05-16 22:18:36 +10:00
tremble7681 4610a50667 docs: record backend layout findings from Task A1 recon 2026-05-16 22:17:42 +10:00
tremble7681 6cebd53b02 docs: rename project to mechanic-pwa; clarify scope vs future driver-app 2026-05-16 22:03:31 +10:00
tremble7681 d6eeb0cc50 chore: initial commit — recon artifacts + design spec + Phase 1 plan 2026-05-16 21:58:10 +10:00