mirror of
https://github.com/mauriceboe/TREK.git
synced 2026-12-03 09:38:54 +00:00
fix(maps): let users and admins enter a CARTO API key (#2060)
CARTO stamps an "API KEY REQUIRED" watermark onto every basemap tile fetched without a key since 26.08.2026, and both CartoDB presets plus the built-in fallback are CARTO. The key is free and needs no account, so add it as a setting rather than dropping the provider. carto_api_key sits next to mapbox_access_token: per user in Settings/Map, instance-wide under Admin/User Defaults, encrypted at rest, injected from CARTO_API_KEY on managed instances. Unlike Mapbox it never switches the map provider, since a raster key says nothing about the renderer. The key is appended as ?key= at render time instead of being stored in the template, so a saved URL stays portable and survives a rotation. That is also what reaches the four maps that pinned CARTO and ignored the user's tile setting: atlas, collections, the public trip share and the public journey. The two share pages read it from their token-gated payload, the same way baseCurrency already travels. Also lifts the release notice above page chrome. Its overlay sat at z-index 50, under the Vacay mode toolbar at 61, so the dialog was neither on top nor modal. Adds a six-step layer scale to index.css and moves the three notice shells onto it. Closes #2054 Closes #2052
This commit is contained in:
@@ -374,6 +374,9 @@ const admin: TranslationStrings = {
|
||||
'admin.defaultSettings.mapboxStylePlaceholder': 'Tria un estil…',
|
||||
'admin.defaultSettings.mapbox3d': 'Edificis i terreny en 3D',
|
||||
'admin.defaultSettings.mapboxQuality': "Mode d'alta qualitat",
|
||||
'admin.defaultSettings.cartoKey': 'Clau CARTO compartida',
|
||||
'admin.defaultSettings.cartoKeyHint':
|
||||
"S'utilitza per a cada usuari que no hagi introduït la seva pròpia clau, de manera que tota la instància obtingui tessel·les de CARTO sense marca d'aigua. S'emmagatzema xifrada.",
|
||||
'admin.unsplashKey': "Clau API d'Unsplash",
|
||||
'admin.unsplashKeyHint': "Per a la cerca d'imatges. Gratuït a unsplash.com/developers",
|
||||
'admin.tabs.plugins': 'Connectors',
|
||||
|
||||
@@ -23,6 +23,12 @@ const settings: TranslationStrings = {
|
||||
'settings.mapMapboxToken': "Token d'accés de Mapbox",
|
||||
'settings.mapMapboxTokenHint': 'Token públic (pk.*) de',
|
||||
'settings.mapMapboxTokenLink': "mapbox.com → Tokens d'accés",
|
||||
'settings.mapCartoKey': "Clau d'API de CARTO",
|
||||
'settings.mapCartoKeyHint':
|
||||
"Els mapes base de CARTO mostren una marca d'aigua sense clau. Gratuïta i sense compte, des de",
|
||||
'settings.mapCartoKeyLink': "clau d'API de mapes base de carto.com",
|
||||
'settings.mapCartoKeyMissing':
|
||||
'Aquesta plantilla és un mapa base de CARTO. Sense clau, CARTO estampa "API KEY REQUIRED" a cada tessel·la.',
|
||||
'settings.mapStyle': 'Estil de mapa',
|
||||
'settings.mapStylePlaceholder': 'Selecciona un estil de Mapbox',
|
||||
'settings.mapStyleHint': 'Predefinit o la teva pròpia URL mapbox://styles/USUARI/ID',
|
||||
|
||||
Reference in New Issue
Block a user