Skip to content

Commit

Permalink
front: show map markers/itinerary when OSM map is unavailable
Browse files Browse the repository at this point in the history
When the OSM map background is unavailable, we can still display
the map markers and itinerary.

Reverts part of b038d3e ("front: display itinerary markers
name when editing a train").

Signed-off-by: Simon Ser <[email protected]>
  • Loading branch information
emersion authored and flomonster committed Dec 19, 2024
1 parent 94d3a84 commit 29133cf
Showing 1 changed file with 13 additions and 17 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -388,23 +388,19 @@ const Map = ({
<RenderPopup pathProperties={pathProperties} />
</>
)}
{mapIsLoaded && (
<>
<ItineraryLayer
layerOrder={LAYER_GROUPS_ORDER[LAYERS.ITINERARY.GROUP]}
geometry={pathGeometry}
hideItineraryLine={hideItinerary}
showStdcmAssets={showStdcmAssets}
isFeasible={isFeasible}
/>
{mapRef.current && (
<ItineraryMarkers
simulationPathSteps={simulationPathSteps}
map={mapRef.current.getMap()}
showStdcmAssets={showStdcmAssets}
/>
)}
</>
<ItineraryLayer
layerOrder={LAYER_GROUPS_ORDER[LAYERS.ITINERARY.GROUP]}
geometry={pathGeometry}
hideItineraryLine={hideItinerary}
showStdcmAssets={showStdcmAssets}
isFeasible={isFeasible}
/>
{mapRef.current && (
<ItineraryMarkers
simulationPathSteps={simulationPathSteps}
map={mapRef.current.getMap()}
showStdcmAssets={showStdcmAssets}
/>
)}
{mapSearchMarker && <SearchMarker data={mapSearchMarker} colors={colors[mapStyle]} />}
{snappedPoint !== undefined && <SnappedMarker geojson={snappedPoint} />}
Expand Down

0 comments on commit 29133cf

Please sign in to comment.