mirror of
https://github.com/home-assistant/frontend.git
synced 2025-07-24 09:46:36 +00:00
Better configure Carto Basemaps (#1267)
This commit is contained in:
parent
673f769237
commit
0ae676d9ba
@ -64,10 +64,12 @@ class HaPanelMap extends LocalizeMixin(PolymerElement) {
|
||||
this.$.map.parentNode.appendChild(style);
|
||||
map.setView([51.505, -0.09], 13);
|
||||
Leaflet.tileLayer(
|
||||
'https://{s}.basemaps.cartocdn.com/light_all/{z}/{x}/{y}.png',
|
||||
`https://{s}.basemaps.cartocdn.com/light_all/{z}/{x}/{y}${Leaflet.Browser.retina ? '@2x.png' : '.png'}`,
|
||||
{
|
||||
attribution: '© <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors, © <a href="https://carto.com/attributions">CARTO</a>',
|
||||
maxZoom: 18,
|
||||
attribution: '© <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a>, © <a href="https://carto.com/attributions">CARTO</a>',
|
||||
subdomains: 'abcd',
|
||||
minZoom: 0,
|
||||
maxZoom: 20,
|
||||
}
|
||||
).addTo(map);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user