Skip to content

Commit 22aae32

Browse files
committed
declare and reuse carto attribution string
1 parent 4a4bd47 commit 22aae32

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/plots/mapbox/constants.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
var requiredVersion = '1.10.1';
44

55
var OSM = '<a href="https://www.openstreetmap.org/copyright" target="_blank">© OpenStreetMap</a> contributors';
6+
var carto = '<a href="https://carto.com/" target="_blank">© CARTO</a>';
67
var stamen = 'Map tiles by <a href="https://stamen.com">Stamen Design</a>, under <a href="https://creativecommons.org/licenses/by/3.0">CC BY 3.0</a>';
78

89
var stylesNonMapbox = {
@@ -48,7 +49,7 @@ var stylesNonMapbox = {
4849
type: 'raster',
4950
attribution: [
5051
OSM,
51-
'<a href="https://carto.com/" target="_blank">© CARTO</a>'
52+
carto
5253
].join(', '),
5354
tiles: ['https://cartodb-basemaps-c.global.ssl.fastly.net/light_all/{z}/{x}/{y}.png'],
5455
tileSize: 256
@@ -70,7 +71,7 @@ var stylesNonMapbox = {
7071
type: 'raster',
7172
attribution: [
7273
OSM,
73-
'<a href="https://carto.com/" target="_blank">© CARTO</a>'
74+
carto
7475
].join(', '),
7576
tiles: ['https://cartodb-basemaps-c.global.ssl.fastly.net/dark_all/{z}/{x}/{y}.png'],
7677
tileSize: 256

0 commit comments

Comments
 (0)