maplibre-gl-layer-control-tidop 0.0.9 → 0.0.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.cjs CHANGED
@@ -814,6 +814,10 @@ class LayerControl {
814
814
  }
815
815
  this.buildLayerItems();
816
816
  }
817
+ const actionButtons = this.createActionButtons();
818
+ this.panel.insertBefore(actionButtons, this.panel.firstChild);
819
+ const header = this.createPanelHeader();
820
+ this.panel.insertBefore(header, this.panel.firstChild);
817
821
  if (!this.state.collapsed) {
818
822
  requestAnimationFrame(() => {
819
823
  this.updatePanelPosition();
@@ -1168,10 +1172,6 @@ class LayerControl {
1168
1172
  if (!this.state.collapsed) {
1169
1173
  panel.classList.add("expanded");
1170
1174
  }
1171
- const header = this.createPanelHeader();
1172
- panel.appendChild(header);
1173
- const actionButtons = this.createActionButtons();
1174
- panel.appendChild(actionButtons);
1175
1175
  return panel;
1176
1176
  }
1177
1177
  /**
@@ -3456,7 +3456,7 @@ class LayerControl {
3456
3456
  }
3457
3457
  });
3458
3458
  console.log(uiLayerIds);
3459
- const reversedIds = [...uiLayerIds].reverse();
3459
+ const reversedIds = [...uiLayerIds];
3460
3460
  console.log(reversedIds);
3461
3461
  const style = this.map.getStyle();
3462
3462
  const mapLibreLayerIds = new Set(((_a = style == null ? void 0 : style.layers) == null ? void 0 : _a.map((l) => l.id)) || []);