Is is possible to remove excessive whitespace in LayerList widget when you have selectionEnabled as true?
Only happens when group layer is empty and selectionEnabled is true.
Visual example:
Solved! Go to Solution.
I've been looking into this and you might be able to add this css style to remove it but I'm not sure if it would cause issues elsewhere without further testing.
https://codepen.io/sagewall/pen/qBQEQzd
.esri-layer-list__list:empty {
min-height: 0px;
}
Thanks for point this out @Aeseir it looks like a bug to me. I can create an internal issue. If you want to keep track of it you could submit a bug though support and you'll get updates.
I am not fussed one way of the other, let me know what is easier for you.
I've been looking into this and you might be able to add this css style to remove it but I'm not sure if it would cause issues elsewhere without further testing.
https://codepen.io/sagewall/pen/qBQEQzd
.esri-layer-list__list:empty {
min-height: 0px;
}
This works, tested it before and haven't found any issues....yet.
If your team wants visible white space to indicate a "landing" spot when user drags the content you can also handle it this way:
.esri-layer-list__list:empty {
min-height: 0px;
}
.esri-layer-list__item:hover > .esri-layer-list__list{
min-height: 48px;
}
Thanks for the suggestion. The extra white space is intended to indicate that a layer can be dragged into the group layer, but the design can certainly be improved. Appreciate you pointing this out.
Not a problem. In that case recommend making it clearly visible with additional markers (e.g. dotted border or such) as some of our less visibly capable users struggle to differentiate what the white space refers to.
Thanks again for the support.