Map error fix
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
/* eslint-disable react-hooks/exhaustive-deps */
|
||||
/* eslint-disable @typescript-eslint/no-explicit-any */
|
||||
import { useEffect, useRef, useState } from "react";
|
||||
import MapView from "@arcgis/core/views/MapView";
|
||||
@@ -60,6 +61,12 @@ const createMapView = (container: HTMLDivElement) => {
|
||||
container: container,
|
||||
center: [54.67, 24.33],
|
||||
zoom: 15,
|
||||
extent: {
|
||||
xmin: 54.65,
|
||||
ymin: 24.32,
|
||||
xmax: 54.685,
|
||||
ymax: 24.355,
|
||||
},
|
||||
});
|
||||
|
||||
view.when(disableZooming);
|
||||
@@ -69,14 +76,6 @@ const createMapView = (container: HTMLDivElement) => {
|
||||
maxZoom: 15,
|
||||
maxScale: 15,
|
||||
minScale: 15,
|
||||
|
||||
geometry: {
|
||||
type: "extent",
|
||||
xmin: 54.65,
|
||||
ymin: 24.32,
|
||||
xmax: 54.685,
|
||||
ymax: 24.355,
|
||||
},
|
||||
};
|
||||
|
||||
return view;
|
||||
@@ -124,12 +123,6 @@ export const MapViewComponent = (props: MapViewComponentProps) => {
|
||||
}
|
||||
}, [isLoading]);
|
||||
|
||||
// useEffect(() => {
|
||||
// if (isLoading && isMobile) {
|
||||
// setModal(<HouseList />);
|
||||
// }
|
||||
// }, [isMobile]);
|
||||
|
||||
useEffect(() => {
|
||||
if (!view) return;
|
||||
setIsLoading(true);
|
||||
|
||||
Reference in New Issue
Block a user