We can allow users to add extra HTML markup on the legend, at least for a title before the items.
On _getOnAddArrayLegend() function, we can simply add
div.innerHTML += '<div class="title">' + legend.title + '</div>';
after
var div = L.DomUtil.create('div', legendClass);
Need to sanitize and check if the title is there, but i'm still getting used to Leaflet and ui-leaflet, so i'm not sure if I have enough time to make a patch and PR.
We can allow users to add extra HTML markup on the legend, at least for a title before the items.
On _getOnAddArrayLegend() function, we can simply add
div.innerHTML += '<div class="title">' + legend.title + '</div>';
aftervar div = L.DomUtil.create('div', legendClass);
Need to sanitize and check if the title is there, but i'm still getting used to Leaflet and ui-leaflet, so i'm not sure if I have enough time to make a patch and PR.
If anyone could help here, would be great.