From 2a9aca302485bc08f5b2dd2a54987de6f80fc338 Mon Sep 17 00:00:00 2001 From: Ariel Costas Guerrero Date: Fri, 19 Dec 2025 13:06:27 +0100 Subject: Implement loading stops as tiles from OTP --- src/frontend/app/routes/planner.tsx | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'src/frontend/app/routes/planner.tsx') diff --git a/src/frontend/app/routes/planner.tsx b/src/frontend/app/routes/planner.tsx index b1a9813..9e44425 100644 --- a/src/frontend/app/routes/planner.tsx +++ b/src/frontend/app/routes/planner.tsx @@ -9,7 +9,7 @@ import { useLocation } from "react-router"; import { useApp } from "~/AppContext"; import LineIcon from "~/components/LineIcon"; import { PlannerOverlay } from "~/components/PlannerOverlay"; -import { REGION_DATA } from "~/config/RegionConfig"; +import { APP_CONSTANTS } from "~/config/constants"; import { usePageTitle } from "~/contexts/PageTitleContext"; import { type Itinerary } from "~/data/PlannerApi"; import { usePlanner } from "~/hooks/usePlanner"; @@ -392,7 +392,7 @@ const ItineraryDetail = ({ if (!arrivalsByStop[stopKey]) { try { const resp = await fetch( - `${REGION_DATA.consolidatedCirculationsEndpoint}?stopId=${encodeURIComponent(leg.from.stopCode || leg.from.stopId)}`, + `${APP_CONSTANTS.consolidatedCirculationsEndpoint}?stopId=${encodeURIComponent(leg.from.stopCode || leg.from.stopId)}`, { headers: { Accept: "application/json" } } ); @@ -424,9 +424,11 @@ const ItineraryDetail = ({ ref={mapRef} initialViewState={{ longitude: - origin?.lon || (REGION_DATA.defaultCenter as [number, number])[0], + origin?.lon || + (APP_CONSTANTS.defaultCenter as [number, number])[0], latitude: - origin?.lat || (REGION_DATA.defaultCenter as [number, number])[1], + origin?.lat || + (APP_CONSTANTS.defaultCenter as [number, number])[1], zoom: 13, }} mapStyle={mapStyle} -- cgit v1.3