Skip to content

Commit

Permalink
Replace map tiles to OpenStreetMap (#122)
Browse files Browse the repository at this point in the history
  • Loading branch information
viktor-yakubiv authored Oct 21, 2020
1 parent 529d984 commit 33f569b
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
2 changes: 1 addition & 1 deletion csp.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ const config = {
SELF,
PRODUCION,
'data:',
'maps.wikimedia.org',
'*.openstreetmap.org',
// Google Analytics may transport data via image:
// https://developers.google.com/analytics/devguides/collection/analyticsjs/field-reference#transport
'*.google-analytics.com',
Expand Down
8 changes: 5 additions & 3 deletions modules/repositories-map/map.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,12 @@ const CustomMap = ({ dataProviders }) => {

useEffect(() => {
const coverLayer = L.tileLayer(
'https://maps.wikimedia.org/osm-intl/{z}/{x}/{y}{r}.png',
'https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png',
{
attribution:
'<a href="https://wikimediafoundation.org/wiki/Maps_Terms_of_Use">Wikimedia</a>',
attribution: `
<a href="https://www.openstreetmap.org">OpenStreetMap</a> under
<a href="https://creativecommons.org/licenses/by-sa/2.0">CC-BY-SA</a>
`,
minZoom: 2,
maxZoom: 12,
}
Expand Down

1 comment on commit 33f569b

@vercel
Copy link

@vercel vercel bot commented on 33f569b Oct 21, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.