물재이용 지도 onOpenPopup 추가
This commit is contained in:
@@ -265,6 +265,10 @@ const Map = () => {
|
||||
}
|
||||
};
|
||||
|
||||
const onOpenPopup = (data:any) => {
|
||||
console.log(data)
|
||||
}
|
||||
|
||||
return (
|
||||
<div className="bg-container">
|
||||
<Gis
|
||||
@@ -299,6 +303,7 @@ const Map = () => {
|
||||
/>
|
||||
}
|
||||
waterDepth={undefined}
|
||||
onOpenPopup={onOpenPopup}
|
||||
/>
|
||||
</div>
|
||||
);
|
||||
|
||||
@@ -123,6 +123,7 @@ function Gis({
|
||||
orderedLayers = [],
|
||||
checkInterval = 3000,
|
||||
height: height = "h-[calc(100vh-10rem)]",
|
||||
onOpenPopup = () => {},
|
||||
}) {
|
||||
const mapRef = useRef();
|
||||
const [mapObject, setMapObject] = useState({});
|
||||
@@ -351,7 +352,9 @@ function Gis({
|
||||
const dummyFeature = {
|
||||
getProperties: () => ({}), // 최소 구조
|
||||
};
|
||||
onFeatureSelect(dummyFeature);
|
||||
console.log(layerNm)
|
||||
onOpenPopup(layerNm)
|
||||
// onFeatureSelect(dummyFeature);
|
||||
}}
|
||||
imageVisible={imgVisble}
|
||||
isPlaying={isPlaying}
|
||||
|
||||
@@ -453,8 +453,8 @@ import {
|
||||
src="/images/map/layericon/Layer_Select_BTN.png"
|
||||
onClick={() =>
|
||||
handleLayerImgClick(
|
||||
node.text,
|
||||
node.id
|
||||
node.data.lyrTyNm,
|
||||
node.id
|
||||
)
|
||||
}
|
||||
alt={node.text}
|
||||
|
||||
Reference in New Issue
Block a user