From 2a8dbf91a878e17717e439e8ca020d9310b0499d Mon Sep 17 00:00:00 2001 From: Maurice Date: Mon, 19 Oct 2026 23:26:41 +0000 Subject: [PATCH] fix(tours): keep the city walk helpers only their own files use inside them (CW-01, CW-03, CW-04) The filter for a walk's stations in the planner, the opening windows of a walk's schedule and the station shape of a walk's progress were exported, although nothing outside their own file reads them, so the check for unused exports counted three more than it allows. They are local to their files now; a city walk plans, checks off and times its stops as before. --- client/src/components/Tours/planner/stationModel.ts | 2 +- client/src/components/Tours/walk/walkSchedule.ts | 2 +- server/src/nest/tours/tour-visits.service.ts | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/client/src/components/Tours/planner/stationModel.ts b/client/src/components/Tours/planner/stationModel.ts index b1e831373..6a062a2df 100644 --- a/client/src/components/Tours/planner/stationModel.ts +++ b/client/src/components/Tours/planner/stationModel.ts @@ -19,7 +19,7 @@ export interface WalkTimes { } /** The stations of a city walk: its points that are no shaping points. */ -export function stationsOf(points: readonly TourPlannerWaypoint[]): TourPlannerWaypoint[] { +function stationsOf(points: readonly TourPlannerWaypoint[]): TourPlannerWaypoint[] { return points.filter((point) => !point.shaping); } diff --git a/client/src/components/Tours/walk/walkSchedule.ts b/client/src/components/Tours/walk/walkSchedule.ts index a9ea92c27..00f56b1b7 100644 --- a/client/src/components/Tours/walk/walkSchedule.ts +++ b/client/src/components/Tours/walk/walkSchedule.ts @@ -49,7 +49,7 @@ function daysOf(spec: string): Set | null { } /** The windows a place is open on a date, in minutes; null where the hours cannot be read. */ -export function openWindows(hours: string, date: string): Array<[number, number]> | null { +function openWindows(hours: string, date: string): Array<[number, number]> | null { const weekday = weekdayOf(date); if (weekday === null) return null; const text = hours.trim(); diff --git a/server/src/nest/tours/tour-visits.service.ts b/server/src/nest/tours/tour-visits.service.ts index af22a773f..5797135a0 100644 --- a/server/src/nest/tours/tour-visits.service.ts +++ b/server/src/nest/tours/tour-visits.service.ts @@ -111,7 +111,7 @@ export class TourVisitsService { } /** CW-09: one station of a walk on a day, as an assistant reads it. */ -export interface WalkProgressStation { +interface WalkProgressStation { position: number; name: string | null; lat: number;