fix: GIS-Systeme im Control Panel sichtbar + Rename zu MapLayersControlPanel.js
- useEffect-Abhängigkeit um GisSystemStatic erweitert (Fix für leeres Control Panel nach Reload) - DataSheet.js umbenannt in MapLayersControlPanel.js für bessere Verständlichkeit - Version erhöht auf 1.1.136
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
// /componentss/DataSheet.js
|
||||
// /componentss/MapLayersControlPanel.js
|
||||
import React, { useEffect, useState } from "react";
|
||||
import { setSelectedArea } from "../redux/slices/selectedAreaSlice";
|
||||
import EditModeToggle from "./EditModeToggle";
|
||||
@@ -10,7 +10,7 @@ import { selectMapLayersState, setLayerVisibility } from "../redux/slices/mapLay
|
||||
import { setVisible } from "../redux/slices/poiLayerVisibleSlice";
|
||||
import { incrementZoomTrigger } from "../redux/slices/zoomTriggerSlice";
|
||||
|
||||
function DataSheet() {
|
||||
function MapLayersControlPanel() {
|
||||
const [editMode, setEditMode] = useState(false); // Zustand für editMode
|
||||
const poiVisible = useSelector((state) => state.poiLayerVisible.visible);
|
||||
const setPoiVisible = (value) => dispatch(setVisible(value));
|
||||
@@ -248,4 +248,4 @@ function DataSheet() {
|
||||
);
|
||||
}
|
||||
|
||||
export default DataSheet;
|
||||
export default MapLayersControlPanel;
|
||||
@@ -8,7 +8,7 @@ import * as config from "../../config/config.js";
|
||||
import "leaflet.smooth_marker_bouncing";
|
||||
import OverlappingMarkerSpiderfier from "overlapping-marker-spiderfier-leaflet"; //sieht deaktiviert aber ist das nicht so und wird benötigt
|
||||
import "react-toastify/dist/ReactToastify.css";
|
||||
import DataSheet from "../DataSheet.js";
|
||||
import MapLayersControlPanel from "../MapLayersControlPanel.js";
|
||||
|
||||
import { InformationCircleIcon } from "@heroicons/react/20/solid";
|
||||
import PoiUpdateModal from "../pois/PoiUpdateModal.js";
|
||||
@@ -905,7 +905,7 @@ const MapComponent = ({ locations, onLocationUpdate, lineCoordinates }) => {
|
||||
)}
|
||||
</div>
|
||||
|
||||
{GisStationsStaticDistrict && GisStationsStaticDistrict.Points?.length > 0 && <DataSheet className="z-50" />}
|
||||
{GisStationsStaticDistrict && GisStationsStaticDistrict.Points?.length > 0 && <MapLayersControlPanel className="z-50" />}
|
||||
|
||||
<CoordinateInput onCoordinatesSubmit={handleCoordinatesSubmit} />
|
||||
<div id="map" ref={mapRef} className="z-0" style={{ height: "100vh", width: "100vw" }}></div>
|
||||
|
||||
Reference in New Issue
Block a user