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 | 9x | import type { Map } from "mapbox-gl";
import type { VehiclePosition } from "@overworld/trimet-client";
import { createVehicleTooltips as createTooltips } from "@overworld/maps/transit";
import { ROUTE_DISPLAY } from "../../../../api/trimet/constants";
import { getRouteById } from "../../../../api/trimet/routeConfig";
export function createVehicleTooltips(
map: Map,
layer: string,
find: (id: string) => { vehicle: VehiclePosition; point: [number, number] } | undefined,
onFollow: (vehicle: VehiclePosition) => void
) {
return createTooltips(map, layer, find, onFollow, { routeDisplay: ROUTE_DISPLAY, getRouteById });
}
|