Press n or j to go to the next uncovered block, b, p or k for the previous block.
| 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 | 13x 13x | import type React from "react";
import type { PlannerEndpoint } from "@overworld/journeys";
import type { InterestPlace } from "@overworld/places/catalog";
import type { PlannerRouteColors } from "../../api/trimet/plannerRouteColors";
import type { StopCatalogStop } from "../../api/trimet/stopCatalog";
import type { TripPlannerItinerary, TripPlannerResponse } from "../../api/trimet/tripplanner";
import type { SavedPlannerStop } from "./PlannerStopSelect";
export const EMPTY_STOPS: StopCatalogStop[] = [];
export type TripState =
| { status: "idle" }
| { status: "loading" }
| { status: "error"; message: string }
| { status: "ready" | "empty" };
export type PlannedSearch = {
from: PlannerEndpoint;
to: PlannerEndpoint;
response: TripPlannerResponse;
};
export const coordinateHelp = "Enter longitude, latitude (for example -122.68, 45.52).";
export interface TripPlannerProps {
inSidebar?: boolean;
directionsFooter?: HTMLDivElement;
savedStops?: SavedPlannerStop[];
renderPlaceDestination?: (place?: InterestPlace) => React.ReactNode;
renderMapStatus?: (
itineraries: TripPlannerItinerary[],
selected: number,
highlightedLeg: number | undefined,
onMapLeg: (leg?: number) => void,
routeColors?: PlannerRouteColors,
previewTrip?: number
) => React.ReactNode;
}
|