Esri / esri-leaflet

A lightweight set of tools for working with ArcGIS services in Leaflet. :rocket:
https://developers.arcgis.com/esri-leaflet/
Apache License 2.0
1.61k stars 799 forks source link

DarkGray and Gray tilemap do not have dynamic attributions #1355

Closed Etienne-M closed 1 year ago

Etienne-M commented 1 year ago

Describe the bug

When selecting Dark Gray Canvas and Light Gray Canvas from the example in Esri's documentation, you can see that there are dynamic attributions coming from https://static.arcgis.com/attribution/Vector/World_Basemap_v2?f=json

But when using esri-leaflet and using the Dark Gray basemap, the attributions are static.

Reproduction

To reproduce, just follow the examples. The attributionUrl is missing from the configuration of the Dark Gray base map and the configuration of the Gray base map.

Logs

No response

System Info

Leaflet version: `v1.9.3`. Esri Leaflet version: `v3.0.8`.

Additional Information

Bundling through webpack

gavinr commented 1 year ago

Hi @Etienne-M, thank you for the bug report.

To reproduce, just follow the examples

Can you please link to a particular example you are referring to?

Etienne-M commented 1 year ago

Hi @Etienne-M, thank you for the bug report.

To reproduce, just follow the examples

Can you please link to a particular example you are referring to?

I can no longer find the example I followed. This one is close enough, you just have to replace the usage of L.esri.Vector.vectorBasemapLayer by L.esri.basemapLayer

gavinr commented 1 year ago

L.esri.basemapLayer is deprecated:

https://developers.arcgis.com/esri-leaflet/api-reference/layers/basemap-layer/ image

I would suggest using L.esri.Vector.vectorBasemapLayer if you want dynamic attribution.