Repository navigation
Conversation
…eck, single arrowhead on water polylines, and scale move duration
|
Reviewed PR #187 changes across shortest water path precomputation ( Findings & Fixes Applied
Validation
Head commit: |
Update: Progressive Move Line Drawing along Water RouteAdded progressive move line stroke drawing during playback and capture stepping on individual shark pages (
Validation: |
…cate recaptures copy
|
Pushed commit \c0ea012\ with follow-up polish:
|
|
Pushed commit \58de034\ with bird's-eye view shark swim animation:
|
Update: Continuous Water Route Scrubbing & Smooth Swim Animation (Commit 3152c36)
All checks passed:
|
|
Fixes synchronized shark animation and continuous timeline scrubbing:
All 137 unit tests and 49 Playwright e2e tests pass. |
|
Replaced the shark SVG marker with a clean, crisp circular traveller dot ( |
|
Updated the underlying water route track ( |
|
Updated in commit bd023cc:
|
|
Updated in commit ebfbba2:
|
Closes #183.
Stacked on top of #186 (
feat/185-map-circle-keyboard).Summary of Changes
Shortest Water Route Engine (
src/lib/server/oceanRoutes.ts):hikeandexplore(pull 1661:water-route.mjsandpaddle-route.mjs) for Moorea's coastline geometry (src/lib/moorea-outline.json, OpenStreetMap, ODbL 1.0).Database Cache & Importer:
nursery_routestable to Drizzle schema (drizzle/0006_keen_shaman.sql) storing(fromId, toId, km, straightKm, coordinates).IMPORTER_VERSION = '12'insrc/lib/server/import/index.tsso the disposable SQLite cache rebuilds and precomputes water routes on import.src/lib/server/data.tswith helpernurseryRoute(d, fromId, toId)(automatically reversing coordinates whenfromId > toId).Multi-Point Polyline Geometry & Maps:
src/lib/components/lineGeometry.ts:offsetPolylineto smoothly offset multi-point polylines rightwards for bidirectional travel separation (falling back todirectedPointsfor 2-point lines).pointAlongPathfor smooth distance-based interpolation along multi-point polylines.MooreaMap.svelte(SVG fallback) to render multi-point SVG paths along water routes with arrow markers.InteractiveMap.svelte(Leaflet) to render water route polylines with rightward lateral offset and marker-mid arrows.travelleranimation on shark pages to glide smoothly along the water route, scaled by water distance (or jumping underprefers-reduced-motion).Pages & Copy:
/recaptures:km (water)andkm (direct)./sharks/[id]:≥ X km by wateralongside direct straight-line distance.Tooling & Tests:
scripts/ocean-routes.mjsCLI tool and"routes": "node scripts/ocean-routes.mjs"script inpackage.jsonto verify routes and export GeoJSON (--geojson).src/lib/server/oceanRoutes.test.tsandsrc/lib/components/lineGeometry.test.ts.e2e/map-routes.spec.tstesting routed move lines on/recapturesand traveller animation on/sharks/[id].AGENTS.mdwith water route documentation.Verification
pnpm lint: Pass (0 errors)pnpm check: Pass (0 errors, 0 warnings)pnpm test: Pass (22 node tests + 136 vitest tests passing)pnpm routes: Pass (91 pairs computed, 0 land crossings)pnpm build: Passpnpm test:e2e: Pass (48 Playwright tests passing)