Skip to content

Commit

Permalink
don’t show nearby view shadow dot when disabled
Browse files Browse the repository at this point in the history
  • Loading branch information
miles-grant-ibigroup committed May 29, 2024
1 parent 431e4d9 commit cbba193
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 2 deletions.
4 changes: 3 additions & 1 deletion example-config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -665,4 +665,6 @@ itinerary:
### What radius should the nearby query get results within? (in meters)
# radius: 600
### Setting this to true will use the route viewer sort algorithm on routes
# useRouteViewSort: false
# useRouteViewSort: false
### Setting this to false will hide the shadowey dot that appears when dragging the map
# showShadowDotOnMapDrag: false
5 changes: 4 additions & 1 deletion lib/components/map/nearby-view-dot-overlay.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,11 @@ const NearbyViewDotOverlay = ({ location }: Props) => {

const mapStateToProps = (state: AppReduxState) => {
const { highlightedLocation } = state.otp.ui
const { nearbyView } = state.otp.config

return {
location: highlightedLocation
location:
nearbyView?.showShadowDotOnMapDrag === false ? null : highlightedLocation
}
}

Expand Down
1 change: 1 addition & 0 deletions lib/util/config-types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@ export type MapillaryConfig = ApiKeyConfig
export type NearbyViewConfig = {
hideEmptyStops?: boolean
radius?: number
showShadowDotOnMapDrag?: boolean
useRouteViewSort?: boolean
}

Expand Down

0 comments on commit cbba193

Please sign in to comment.