diff --git a/openspec/changes/e2e-test-reorganization/specs/e2e-testing/spec.md b/openspec/changes/e2e-test-reorganization/specs/e2e-testing/spec.md new file mode 100644 index 0000000..e93befc --- /dev/null +++ b/openspec/changes/e2e-test-reorganization/specs/e2e-testing/spec.md @@ -0,0 +1,16 @@ +## MODIFIED Requirements + +### Requirement: Planner E2E test infrastructure +The Planner E2E test suite SHALL mock BRouter by default, split tests by feature file, and provide shared test helpers for common setup patterns. + +#### Scenario: BRouter mocked by default +- **WHEN** a Planner E2E test runs +- **THEN** BRouter is mocked via a shared Playwright fixture unless the test explicitly opts into the real BRouter endpoint + +#### Scenario: Tests split by feature file +- **WHEN** the Planner E2E test suite is executed +- **THEN** tests are organized into focused files by feature area (session, routing, multi-day, overlays, coloring) instead of a single monolithic test file + +#### Scenario: Shared test helpers +- **WHEN** a Planner E2E test needs to create a session and wait for connection +- **THEN** it uses a shared helper function that handles session creation, navigation, and waiting for the connected state diff --git a/openspec/changes/journal-poi-details/specs/journal-route-detail/spec.md b/openspec/changes/journal-poi-details/specs/journal-route-detail/spec.md new file mode 100644 index 0000000..3093d6d --- /dev/null +++ b/openspec/changes/journal-poi-details/specs/journal-route-detail/spec.md @@ -0,0 +1,16 @@ +## MODIFIED Requirements + +### Requirement: POI metadata on route detail waypoints +The Journal route detail page SHALL display POI metadata (phone, address, website, opening hours) for waypoints that have associated OpenStreetMap POI data. + +#### Scenario: POI metadata displayed on waypoints +- **WHEN** a route detail page is loaded and a waypoint has POI metadata from the Planner +- **THEN** the waypoint displays the POI name, icon, and category alongside its coordinates + +#### Scenario: Phone, address, and website shown +- **WHEN** a waypoint has POI metadata including phone, address, or website +- **THEN** those details are shown in the waypoint detail section with appropriate links (tel: for phone, mailto: or https: for website) + +#### Scenario: Waypoints without POI data display normally +- **WHEN** a waypoint on the route detail page has no associated POI metadata +- **THEN** the waypoint displays as before with coordinates and name only, with no empty POI sections shown diff --git a/openspec/changes/mobile-app/specs/mobile-testing/spec.md b/openspec/changes/mobile-app/specs/mobile-testing/spec.md index 9274b77..6291245 100644 --- a/openspec/changes/mobile-app/specs/mobile-testing/spec.md +++ b/openspec/changes/mobile-app/specs/mobile-testing/spec.md @@ -24,3 +24,7 @@ The mobile app SHALL use Maestro for end-to-end flow testing on real/emulated de ### Requirement: No Vitest for mobile Vitest SHALL NOT be used for the mobile app. React Native Testing Library has incomplete Vitest support — Jest with jest-expo is the stable, Expo-recommended choice. + +#### Scenario: Vitest not used +- **WHEN** unit or component tests are added to the mobile app +- **THEN** they use Jest with jest-expo preset, not Vitest diff --git a/openspec/changes/mobile-nearby-sync/specs/mobile-nearby-sync/spec.md b/openspec/changes/mobile-nearby-sync/specs/mobile-nearby-sync/spec.md new file mode 100644 index 0000000..eb75375 --- /dev/null +++ b/openspec/changes/mobile-nearby-sync/specs/mobile-nearby-sync/spec.md @@ -0,0 +1,23 @@ +## ADDED Requirements + +### Requirement: BLE nearby route sync +The mobile app SHALL discover nearby devices via Bluetooth LE and transfer route data (waypoints + GPX geometry) directly between devices without internet connectivity. + +#### Scenario: BLE device discovery +- **WHEN** a user enables nearby sync on the route detail screen +- **THEN** the app advertises via BLE and discovers other nearby devices that have the same route open + +#### Scenario: Route transfer +- **WHEN** a nearby device with a newer version of the route is discovered +- **THEN** the user is prompted to accept the update and the route data is transferred via chunked BLE messages + +#### Scenario: Version check before sync +- **WHEN** two devices discover each other via BLE +- **THEN** they exchange route version numbers and only the device with the older version is offered the update + +### Requirement: QR waypoint sharing +The mobile app SHALL support sharing waypoint coordinates via QR code as a fallback when BLE is unavailable or impractical. + +#### Scenario: QR waypoint sharing +- **WHEN** a user taps "Share via QR" on a route +- **THEN** a QR code is generated containing compressed waypoint coordinates that another device can scan to receive the waypoints diff --git a/openspec/specs/elevation-map-interaction/spec.md b/openspec/specs/elevation-map-interaction/spec.md index eeea56b..7fe6879 100644 --- a/openspec/specs/elevation-map-interaction/spec.md +++ b/openspec/specs/elevation-map-interaction/spec.md @@ -1,4 +1,8 @@ -## ADDED Requirements +## Purpose + +Bidirectional interaction between the map and elevation chart, enabling users to explore route elevation by hovering, clicking, and dragging on either surface. + +## Requirements ### Requirement: Route hover highlights elevation chart Hovering over the route polyline on the map SHALL highlight the corresponding position on the elevation chart. diff --git a/openspec/specs/map-core/spec.md b/openspec/specs/map-core/spec.md index 23d1b4b..49fd1eb 100644 --- a/openspec/specs/map-core/spec.md +++ b/openspec/specs/map-core/spec.md @@ -1,4 +1,8 @@ -## ADDED Requirements +## Purpose + +Renderer-agnostic map configuration data (tile sources, route color palettes, POI categories) usable by any rendering engine without DOM or library dependencies. + +## Requirements ### Requirement: Renderer-agnostic map definitions The `@trails-cool/map-core` package SHALL provide map configuration data usable by any rendering engine. diff --git a/openspec/specs/map-display/spec.md b/openspec/specs/map-display/spec.md index 50d474f..885842d 100644 --- a/openspec/specs/map-display/spec.md +++ b/openspec/specs/map-display/spec.md @@ -1,4 +1,8 @@ -## MODIFIED Requirements +## Purpose + +Map tile layer display with base layer switching and independent overlay tile layers in the Planner. + +## Requirements ### Requirement: Base layer switching The map SHALL support switching between multiple base tile layers, and SHALL support toggling overlay tile layers independently. diff --git a/openspec/specs/multi-day-routes/spec.md b/openspec/specs/multi-day-routes/spec.md index 45c50a4..7d3ab38 100644 --- a/openspec/specs/multi-day-routes/spec.md +++ b/openspec/specs/multi-day-routes/spec.md @@ -1,4 +1,8 @@ -## ADDED Requirements +## Purpose + +Multi-day route planning with overnight waypoint markers, per-day statistics, day-aware UI, and day structure preserved in GPX exports. + +## Requirements ### Requirement: Overnight waypoint markers Any waypoint SHALL be toggleable as an overnight stop, creating day boundaries in the route. diff --git a/openspec/specs/osm-poi-overlays/spec.md b/openspec/specs/osm-poi-overlays/spec.md index f05a44b..67ee0c8 100644 --- a/openspec/specs/osm-poi-overlays/spec.md +++ b/openspec/specs/osm-poi-overlays/spec.md @@ -1,4 +1,8 @@ -## ADDED Requirements +## Purpose + +POI overlay panel for toggling OpenStreetMap point-of-interest categories on the Planner map, with viewport-scoped loading, caching, and profile-aware defaults. + +## Requirements ### Requirement: POI overlay panel The Planner SHALL provide a collapsible panel for toggling POI categories on the map. diff --git a/openspec/specs/osm-tile-overlays/spec.md b/openspec/specs/osm-tile-overlays/spec.md index 396fee5..91811fe 100644 --- a/openspec/specs/osm-tile-overlays/spec.md +++ b/openspec/specs/osm-tile-overlays/spec.md @@ -1,4 +1,8 @@ -## ADDED Requirements +## Purpose + +Tile-based map overlays (hillshading, Waymarked Trails cycling/hiking/MTB routes) with support for multiple simultaneous overlays, proper attribution, and profile-aware auto-enabling. + +## Requirements ### Requirement: Hillshading overlay The Planner map SHALL offer a hillshading tile overlay that visualizes terrain relief. diff --git a/openspec/specs/planner-session/spec.md b/openspec/specs/planner-session/spec.md index 62f48aa..9a60a38 100644 --- a/openspec/specs/planner-session/spec.md +++ b/openspec/specs/planner-session/spec.md @@ -1,4 +1,8 @@ -## MODIFIED Requirements +## Purpose + +Real-time collaborative editing sessions in the Planner using Yjs CRDTs, synchronizing waypoints, route options, and overlay preferences across all connected participants. + +## Requirements ### Requirement: Real-time collaborative editing The Planner SHALL synchronize waypoint edits, route options, and overlay preferences across all connected participants in real-time using Yjs CRDTs.