Skip to content

Commit

Permalink
EDSC-3884: Set latitude check to Ant/arctic circle (#1704)
Browse files Browse the repository at this point in the history
For automatically switching to a polar basemap if all coordinates are above the specified latitude.
  • Loading branch information
rushgeo authored Dec 27, 2023
1 parent 8a10f14 commit 6094375
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions static/src/js/components/Map/ShapefileLayer.js
Original file line number Diff line number Diff line change
Expand Up @@ -215,8 +215,8 @@ class ShapefileLayerExtended extends L.Layer {
featureLatLngs = featureLayer.getLatLngs().flat()
}

allLatsArctic = featureLatLngs.every((latlng) => latlng.lat > 45)
allLatsAntarctic = featureLatLngs.every((latlng) => latlng.lat < -45)
allLatsArctic = featureLatLngs.every((latlng) => latlng.lat > 66.5)
allLatsAntarctic = featureLatLngs.every((latlng) => latlng.lat < -66.5)

const addIconClasses = (layer) => {
const { options = {} } = layer
Expand Down

0 comments on commit 6094375

Please sign in to comment.