")
+ .appendTo(baseSection);
- if (map.hasLayer(layer)) {
- item.addClass('active');
- }
+ var mapContainer = $("
")
+ .appendTo(buttonContainer);
- var div = $('
')
- .appendTo(item);
+ var input = $("
")
+ .prop("id", id)
+ .prop("checked", map.hasLayer(layer))
+ .appendTo(buttonContainer);
- map.whenReady(function() {
- var miniMap = L.map(div[0], {attributionControl: false, zoomControl: false})
- .addLayer(new layer.constructor());
+ var item = $("