WIP. polylines visiblity
This commit is contained in:
@@ -24,4 +24,4 @@ NEXT_PUBLIC_USE_MOCKS=true
|
|||||||
# z.B. http://10.10.0.13/xyz/index.aspx -> basePath in config.json auf /xyz setzen
|
# z.B. http://10.10.0.13/xyz/index.aspx -> basePath in config.json auf /xyz setzen
|
||||||
# basePath wird jetzt in public/config.json gepflegt
|
# basePath wird jetzt in public/config.json gepflegt
|
||||||
# App-Versionsnummer
|
# App-Versionsnummer
|
||||||
NEXT_PUBLIC_APP_VERSION=1.1.332
|
NEXT_PUBLIC_APP_VERSION=1.1.333
|
||||||
|
|||||||
@@ -25,4 +25,4 @@ NEXT_PUBLIC_USE_MOCKS=false
|
|||||||
# basePath wird jetzt in public/config.json gepflegt
|
# basePath wird jetzt in public/config.json gepflegt
|
||||||
|
|
||||||
# App-Versionsnummer
|
# App-Versionsnummer
|
||||||
NEXT_PUBLIC_APP_VERSION=1.1.332
|
NEXT_PUBLIC_APP_VERSION=1.1.333
|
||||||
|
|||||||
@@ -374,6 +374,10 @@ const MapComponent = ({ locations, onLocationUpdate, lineCoordinates }) => {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Prüfe Sichtbarkeit aus localStorage und Redux
|
||||||
|
const localStoragePolylineVisible = localStorage.getItem("polylineVisible") === "true";
|
||||||
|
const reduxPolylineLayerVisible = poiLayerVisible; // redux: polylineLayerVisible.visible
|
||||||
|
|
||||||
// vorherige Marker & Polylinien vollständig bereinigen
|
// vorherige Marker & Polylinien vollständig bereinigen
|
||||||
(Array.isArray(markers) ? markers : []).forEach(marker => {
|
(Array.isArray(markers) ? markers : []).forEach(marker => {
|
||||||
marker.remove();
|
marker.remove();
|
||||||
@@ -382,7 +386,7 @@ const MapComponent = ({ locations, onLocationUpdate, lineCoordinates }) => {
|
|||||||
|
|
||||||
// Setze neue Marker und Polylinien mit den aktuellen Daten (asynchron!)
|
// Setze neue Marker und Polylinien mit den aktuellen Daten (asynchron!)
|
||||||
const updatePolylines = async () => {
|
const updatePolylines = async () => {
|
||||||
if (polylineVisible) {
|
if (localStoragePolylineVisible && reduxPolylineLayerVisible) {
|
||||||
const { markers: newMarkers, polylines: newPolylines } = await setupPolylines(
|
const { markers: newMarkers, polylines: newPolylines } = await setupPolylines(
|
||||||
map,
|
map,
|
||||||
linePositions,
|
linePositions,
|
||||||
@@ -456,6 +460,7 @@ const MapComponent = ({ locations, onLocationUpdate, lineCoordinates }) => {
|
|||||||
tempMarker,
|
tempMarker,
|
||||||
polylineVisible,
|
polylineVisible,
|
||||||
isTalasAllowed,
|
isTalasAllowed,
|
||||||
|
poiLayerVisible,
|
||||||
]);
|
]);
|
||||||
|
|
||||||
//--------------------------------------------
|
//--------------------------------------------
|
||||||
|
|||||||
BIN
nodemap-1.1.332.zip
Normal file
BIN
nodemap-1.1.332.zip
Normal file
Binary file not shown.
4
package-lock.json
generated
4
package-lock.json
generated
@@ -1,12 +1,12 @@
|
|||||||
{
|
{
|
||||||
"name": "nodemap",
|
"name": "nodemap",
|
||||||
"version": "1.1.332",
|
"version": "1.1.333",
|
||||||
"lockfileVersion": 3,
|
"lockfileVersion": 3,
|
||||||
"requires": true,
|
"requires": true,
|
||||||
"packages": {
|
"packages": {
|
||||||
"": {
|
"": {
|
||||||
"name": "nodemap",
|
"name": "nodemap",
|
||||||
"version": "1.1.332",
|
"version": "1.1.333",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@emotion/react": "^11.13.3",
|
"@emotion/react": "^11.13.3",
|
||||||
"@emotion/styled": "^11.13.0",
|
"@emotion/styled": "^11.13.0",
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "nodemap",
|
"name": "nodemap",
|
||||||
"version": "1.1.332",
|
"version": "1.1.333",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@emotion/react": "^11.13.3",
|
"@emotion/react": "^11.13.3",
|
||||||
"@emotion/styled": "^11.13.0",
|
"@emotion/styled": "^11.13.0",
|
||||||
|
|||||||
Reference in New Issue
Block a user