umap icon indicating copy to clipboard operation
umap copied to clipboard

Restrict zoom levels available for custom backgrounds

Open simonpoole opened this issue 4 years ago • 3 comments

We (SOSM) just had a map configuration by one of our users make their map unusable and lead to a browser crash for anybody viewing the map which, because it was a recent addition, did the same for everybody visiting our umap instance.

It seems (this isn't quite repeatable) that the user set the max_zoom parameter for a custom layer to 60, that caused the issue. Regardless of that I believe it would be best practice to limit the zoom pickers to a reasonable range (0-24) instead of them being unbounded.

simonpoole avatar Sep 15 '21 08:09 simonpoole

Hey @simonpoole I'm failling to reproduce the issue just setting a max zoom value. Can you point me to the map so I can investigate ?

yohanboniface avatar Sep 16 '21 10:09 yohanboniface

Hi @yohanboniface it was this https://umap.osm.ch/de/map/dd-kletternch_3872#7/46.167/10.300 map. Manually changing (in the json) the max_zoom from 60 to 22 fixed the issue, adding @datendelphin as he actually fixed it.

simonpoole avatar Sep 16 '21 13:09 simonpoole

Can't reproduce it either with a new map. But changeing it from 60 to 22 definitely resolved the issue for that map. Unfortunately no idea what else is needed to trigger it.

datendelphin avatar Sep 16 '21 17:09 datendelphin

I'm closing it since it's an edgy case which has a workaround.

davidbgk avatar May 05 '23 18:05 davidbgk