From 5dd0c2394a449fd520689476b92640543036438e Mon Sep 17 00:00:00 2001 From: pfbreton-perso <59520411+pfbreton-perso@users.noreply.github.com> Date: Fri, 16 Jun 2023 15:20:17 -0400 Subject: [PATCH 1/2] browse datalayers overflow fix In my previous improvement where I suggested to set the height of datalayers to the size of the content and add a resize handle i neglected the case where a very long list of layers could make the control unusable by overflowing the available screen space. I suggest to reintroduce a maximum height so that we have a good compromize between resizing the datalayer list and the maximum possible size. --- umap/static/umap/map.css | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/umap/static/umap/map.css b/umap/static/umap/map.css index b303047d..aea61b27 100644 --- a/umap/static/umap/map.css +++ b/umap/static/umap/map.css @@ -587,7 +587,8 @@ ul.photon-autocomplete { border-radius: 2px; } .leaflet-control-browse .umap-browse-datalayers { - height: max-content; + height: fit-content; + max-height: 40em; overflow-y: auto; resize: vertical; } From ac8f343d670bb945102a57506be5e1fbafb69100 Mon Sep 17 00:00:00 2001 From: David Larlet Date: Sat, 17 Jun 2023 09:05:25 -0400 Subject: [PATCH 2/2] Back to max-height only for datalayers Refs https://github.com/umap-project/umap/pull/1149 Refs https://github.com/umap-project/umap/pull/1143 There are still issues with resize+(max-)height combination, to be addressed in a future release. --- umap/static/umap/map.css | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/umap/static/umap/map.css b/umap/static/umap/map.css index aea61b27..0a1f937c 100644 --- a/umap/static/umap/map.css +++ b/umap/static/umap/map.css @@ -587,10 +587,8 @@ ul.photon-autocomplete { border-radius: 2px; } .leaflet-control-browse .umap-browse-datalayers { - height: fit-content; - max-height: 40em; + max-height: 15em; overflow-y: auto; - resize: vertical; } .search-result-tools i, .leaflet-inplace-toolbar a,